DeviceClientConfig 类

定义

Configuration settings for an IoT Hub client. Validates all user-defined settings.

public class DeviceClientConfig
继承
java.lang.Object
DeviceClientConfig

构造函数

DeviceClientConfig()
DeviceClientConfig(IotHubAuthenticationProvider authenticationProvider)
DeviceClientConfig(IotHubConnectionString iotHubConnectionString)

Constructor

DeviceClientConfig(IotHubConnectionString iotHubConnectionString, ClientOptions clientOptions)
DeviceClientConfig(IotHubConnectionString iotHubConnectionString, SSLContext sslContext)
DeviceClientConfig(IotHubConnectionString iotHubConnectionString, String publicKeyCertificate, boolean isPathForPublic, String privateKey, boolean isPathForPrivate)

Constructor for device configs that use x509 authentication

DeviceClientConfig(String hostName, SasTokenProvider sasTokenProvider, ClientOptions clientOptions, String deviceId, String moduleId)

字段

DEFAULT_AMQP_OPEN_AUTHENTICATION_SESSION_TIMEOUT_IN_SECONDS

方法

getAuthenticationProvider()
getAuthenticationType()

Getter for AuthenticationType

getDeviceId()

Getter for the device ID.

getDeviceMethodsMessageCallback()

Getter for the device twin message callback.

getDeviceMethodsMessageContext()

Getter for the context to be passed in to the device twin message callback.

getDeviceTelemetryMessageCallback(String inputName)

Getter for the message callback.

getDeviceTelemetryMessageContext(String inputName)

Getter for the context to be passed in to the message callback.

getDeviceTwinMessageCallback()

Getter for the device twin message callback.

getDeviceTwinMessageContext()

Getter for the context to be passed in to the device twin message callback.

getGatewayHostname()

Getter for the Gateway host name.

getIotHubHostname()

Getter for the IoT Hub hostname.

getIotHubName()

Getter for the IoT Hub name.

getMessageLockTimeoutSecs()

Getter for the timeout, in seconds, for the lock that the client has on a received message.

getModuleId()
getOperationTimeout()

Getter for the device operation timeout

getProductInfo()
getProtocol()
getProxySettings()
getRetryPolicy()

Getter for RetryPolicy

getSasTokenAuthentication()

Getter for SasTokenAuthentication

isUseWebsocket()

Getter for Websocket

setDeviceMethodsMessageCallback(MessageCallback callback, Object context)

Setter for the device method message callback.

setDeviceTwinMessageCallback(MessageCallback callback, Object context)

Setter for the device twin message callback.

setMessageCallback(MessageCallback callback, Object context)

Setter for the message callback. Can benull 

</code> . </p>

setMessageCallback(String inputName, MessageCallback callback, Object context)
setProxy(ProxySettings proxySettings)
setRetryPolicy(RetryPolicy retryPolicy)

Setter for RetryPolicy

setUseWebsocket(boolean useWebsocket)

Setter for Websocket

适用于