public static class AwsIotClientOptions.Builder extends Object
AwsIotClientOptions
.Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
AwsIotClientOptions |
build()
Build option instance with values already set
|
static AwsIotClientOptions.Builder |
builder() |
AwsIotClientOptions.Builder |
clientID(String clientId) |
AwsIotClientOptions.Builder |
host(String host) |
AwsIotClientOptions.Builder |
keepAlive(int keepAlive) |
AwsIotClientOptions.Builder |
password(char[] password) |
AwsIotClientOptions.Builder |
port(int port) |
AwsIotClientOptions.Builder |
secure(SocketFactory context) |
AwsIotClientOptions.Builder |
thingName(String thingName) |
AwsIotClientOptions.Builder |
timeout(int timeout) |
AwsIotClientOptions.Builder |
username(String username) |
public AwsIotClientOptions build()
AwsIotClientOptions
public static AwsIotClientOptions.Builder builder()
public AwsIotClientOptions.Builder clientID(String clientId)
clientId
- the MQTT ID. you can use AwsIotClientOptions.generateClientId()
to get a random client ID.public AwsIotClientOptions.Builder host(String host)
host
- AWS Iot Server hostpublic AwsIotClientOptions.Builder keepAlive(int keepAlive)
keepAlive
- connection keep alive in seconds. It must be >= 0
. default is 60public AwsIotClientOptions.Builder password(char[] password)
password
- to use in MQTT CONNECTpublic AwsIotClientOptions.Builder port(int port)
port
- AWS Iot Server Port. default is 8883public AwsIotClientOptions.Builder secure(SocketFactory context)
context
- ssl contextpublic AwsIotClientOptions.Builder thingName(String thingName)
thingName
- AWS Iot Thing Namepublic AwsIotClientOptions.Builder timeout(int timeout)
timeout
- MQTT client timeout in seconds. It must be >
0. default is 30 secondspublic AwsIotClientOptions.Builder username(String username)
username
- to use in MQTT CONNECT