你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
MetricsAdvisorKeyCredential Class
- java.
lang. Object - com.
azure. ai. metricsadvisor. models. MetricsAdvisorKeyCredential
- com.
public final class MetricsAdvisorKeyCredential
The MetricsAdvisorKeyCredential class.
Constructor Summary
Constructor | Description |
---|---|
MetricsAdvisorKeyCredential(String subscriptionKey, String apiKey) |
Creates a Metrics |
Method Summary
Modifier and Type | Method and Description |
---|---|
Metrics |
getKeys()
Retrieves the MetricsAdvisorKeys containing the subscription key and api key associated with this credential. |
Metrics |
updateKey(String subscriptionKey, String apiKey)
Update the subscription and api key associated to this credential. |
Methods inherited from java.lang.Object
Constructor Details
MetricsAdvisorKeyCredential
public MetricsAdvisorKeyCredential(String subscriptionKey, String apiKey)
Creates a MetricsAdvisorKeyCredential credential that authorizes request with the given keys.
Parameters:
Method Details
getKeys
public MetricsAdvisorKeys getKeys()
Retrieves the MetricsAdvisorKeys containing the subscription key and api key associated with this credential.
Returns:
updateKey
public MetricsAdvisorKeyCredential updateKey(String subscriptionKey, String apiKey)
Update the subscription and api key associated to this credential.
This is intended to be used when you've regenerated your subscription key and api key want to update long lived clients.
Parameters:
Returns:
MetricsAdvisorKeyCredential
object.