Class EndpointKeysImpl
- java.lang.Object
-
- com.microsoft.azure.cognitiveservices.knowledge.qnamaker.implementation.EndpointKeysImpl
-
- All Implemented Interfaces:
EndpointKeys
public class EndpointKeysImpl extends Object implements EndpointKeys
An instance of this class provides access to all the operations defined in EndpointKeys.
-
-
Constructor Summary
Constructors Constructor Description EndpointKeysImpl(retrofit2.Retrofit retrofit, QnAMakerClientImpl client)
Initializes an instance of EndpointKeysImpl.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description EndpointKeysDTO
getKeys()
Gets endpoint keys for an endpoint.rx.Observable<EndpointKeysDTO>
getKeysAsync()
Gets endpoint keys for an endpoint.com.microsoft.rest.ServiceFuture<EndpointKeysDTO>
getKeysAsync(com.microsoft.rest.ServiceCallback<EndpointKeysDTO> serviceCallback)
Gets endpoint keys for an endpoint.rx.Observable<com.microsoft.rest.ServiceResponse<EndpointKeysDTO>>
getKeysWithServiceResponseAsync()
Gets endpoint keys for an endpoint.EndpointKeysDTO
refreshKeys(String keyType)
Re-generates an endpoint key.rx.Observable<EndpointKeysDTO>
refreshKeysAsync(String keyType)
Re-generates an endpoint key.com.microsoft.rest.ServiceFuture<EndpointKeysDTO>
refreshKeysAsync(String keyType, com.microsoft.rest.ServiceCallback<EndpointKeysDTO> serviceCallback)
Re-generates an endpoint key.rx.Observable<com.microsoft.rest.ServiceResponse<EndpointKeysDTO>>
refreshKeysWithServiceResponseAsync(String keyType)
Re-generates an endpoint key.
-
-
-
Constructor Detail
-
EndpointKeysImpl
public EndpointKeysImpl(retrofit2.Retrofit retrofit, QnAMakerClientImpl client)
Initializes an instance of EndpointKeysImpl.- Parameters:
retrofit
- the Retrofit instance built from a Retrofit Builder.client
- the instance of the service client containing this operation class.
-
-
Method Detail
-
getKeys
public EndpointKeysDTO getKeys()
Gets endpoint keys for an endpoint.- Specified by:
getKeys
in interfaceEndpointKeys
- Returns:
- the EndpointKeysDTO object if successful.
- Throws:
IllegalArgumentException
- thrown if parameters fail the validationErrorResponseException
- thrown if the request is rejected by serverRuntimeException
- all other wrapped checked exceptions if the request fails to be sent
-
getKeysAsync
public com.microsoft.rest.ServiceFuture<EndpointKeysDTO> getKeysAsync(com.microsoft.rest.ServiceCallback<EndpointKeysDTO> serviceCallback)
Gets endpoint keys for an endpoint.- Parameters:
serviceCallback
- the async ServiceCallback to handle successful and failed responses.- Returns:
- the
ServiceFuture
object - Throws:
IllegalArgumentException
- thrown if parameters fail the validation
-
getKeysAsync
public rx.Observable<EndpointKeysDTO> getKeysAsync()
Gets endpoint keys for an endpoint.- Specified by:
getKeysAsync
in interfaceEndpointKeys
- Returns:
- the observable to the EndpointKeysDTO object
- Throws:
IllegalArgumentException
- thrown if parameters fail the validation
-
getKeysWithServiceResponseAsync
public rx.Observable<com.microsoft.rest.ServiceResponse<EndpointKeysDTO>> getKeysWithServiceResponseAsync()
Gets endpoint keys for an endpoint.- Returns:
- the observable to the EndpointKeysDTO object
- Throws:
IllegalArgumentException
- thrown if parameters fail the validation
-
refreshKeys
public EndpointKeysDTO refreshKeys(String keyType)
Re-generates an endpoint key.- Specified by:
refreshKeys
in interfaceEndpointKeys
- Parameters:
keyType
- Type of Key- Returns:
- the EndpointKeysDTO object if successful.
- Throws:
IllegalArgumentException
- thrown if parameters fail the validationErrorResponseException
- thrown if the request is rejected by serverRuntimeException
- all other wrapped checked exceptions if the request fails to be sent
-
refreshKeysAsync
public com.microsoft.rest.ServiceFuture<EndpointKeysDTO> refreshKeysAsync(String keyType, com.microsoft.rest.ServiceCallback<EndpointKeysDTO> serviceCallback)
Re-generates an endpoint key.- Parameters:
keyType
- Type of KeyserviceCallback
- the async ServiceCallback to handle successful and failed responses.- Returns:
- the
ServiceFuture
object - Throws:
IllegalArgumentException
- thrown if parameters fail the validation
-
refreshKeysAsync
public rx.Observable<EndpointKeysDTO> refreshKeysAsync(String keyType)
Re-generates an endpoint key.- Specified by:
refreshKeysAsync
in interfaceEndpointKeys
- Parameters:
keyType
- Type of Key- Returns:
- the observable to the EndpointKeysDTO object
- Throws:
IllegalArgumentException
- thrown if parameters fail the validation
-
refreshKeysWithServiceResponseAsync
public rx.Observable<com.microsoft.rest.ServiceResponse<EndpointKeysDTO>> refreshKeysWithServiceResponseAsync(String keyType)
Re-generates an endpoint key.- Parameters:
keyType
- Type of Key- Returns:
- the observable to the EndpointKeysDTO object
- Throws:
IllegalArgumentException
- thrown if parameters fail the validation
-
-