public final class IotHubServiceSasToken extends Object
| Modifier and Type | Field and Description |
|---|---|
protected long |
expiryTimeSeconds |
protected String |
keyName |
protected String |
keyValue |
protected String |
resourceUri |
protected String |
token |
static String |
TOKEN_FORMAT
The SAS token format.
|
protected long |
tokenLifespanSeconds |
| Constructor and Description |
|---|
IotHubServiceSasToken(IotHubConnectionString iotHubConnectionString)
Constructor.
|
IotHubServiceSasToken(IotHubConnectionString iotHubConnectionString,
long tokenLifespanSeconds)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
long |
getExpiryTimeMillis() |
long |
getTokenLifespanSeconds() |
String |
toString()
Returns the string representation of the SAS token.
|
public static final String TOKEN_FORMAT
SharedAccessSignature sr=IOTHUBURI&sig=SIGNATURE&se=EXPIRY&skn=SHAREDACCESSKEYNAMEprotected final String resourceUri
protected final String keyValue
protected final long expiryTimeSeconds
protected final String keyName
protected final String token
protected final long tokenLifespanSeconds
public IotHubServiceSasToken(IotHubConnectionString iotHubConnectionString)
iotHubConnectionString - Connection string object containing the connection parameterspublic IotHubServiceSasToken(IotHubConnectionString iotHubConnectionString, long tokenLifespanSeconds)
iotHubConnectionString - Connection string object containing the connection parameters.tokenLifespanSeconds - The number of seconds that the created SAS token will be valid for.public final long getExpiryTimeMillis()
public long getTokenLifespanSeconds()
Copyright © 2022. All rights reserved.