Class TokenCertificate
java.lang.Object
com.azure.resourcemanager.containerregistry.models.TokenCertificate
- All Implemented Interfaces:
com.azure.json.JsonSerializable<TokenCertificate>
public final class TokenCertificate
extends Object
implements com.azure.json.JsonSerializable<TokenCertificate>
The properties of a certificate used for authenticating a token.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the encodedPemCertificate property: Base 64 encoded string of the public certificate1 in PEM format that will be used for authenticating the token.expiry()Get the expiry property: The expiry datetime of the certificate.static TokenCertificatefromJson(com.azure.json.JsonReader jsonReader) Reads an instance of TokenCertificate from the JsonReader.name()Get the name property: The name property.Get the thumbprint property: The thumbprint of the certificate.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) voidvalidate()Validates the instance.withEncodedPemCertificate(String encodedPemCertificate) Set the encodedPemCertificate property: Base 64 encoded string of the public certificate1 in PEM format that will be used for authenticating the token.withExpiry(OffsetDateTime expiry) Set the expiry property: The expiry datetime of the certificate.withName(TokenCertificateName name) Set the name property: The name property.withThumbprint(String thumbprint) Set the thumbprint property: The thumbprint of the certificate.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
TokenCertificate
public TokenCertificate()Creates an instance of TokenCertificate class.
-
-
Method Details
-
name
Get the name property: The name property.- Returns:
- the name value.
-
withName
Set the name property: The name property.- Parameters:
name- the name value to set.- Returns:
- the TokenCertificate object itself.
-
expiry
Get the expiry property: The expiry datetime of the certificate.- Returns:
- the expiry value.
-
withExpiry
Set the expiry property: The expiry datetime of the certificate.- Parameters:
expiry- the expiry value to set.- Returns:
- the TokenCertificate object itself.
-
thumbprint
Get the thumbprint property: The thumbprint of the certificate.- Returns:
- the thumbprint value.
-
withThumbprint
Set the thumbprint property: The thumbprint of the certificate.- Parameters:
thumbprint- the thumbprint value to set.- Returns:
- the TokenCertificate object itself.
-
encodedPemCertificate
Get the encodedPemCertificate property: Base 64 encoded string of the public certificate1 in PEM format that will be used for authenticating the token.- Returns:
- the encodedPemCertificate value.
-
withEncodedPemCertificate
Set the encodedPemCertificate property: Base 64 encoded string of the public certificate1 in PEM format that will be used for authenticating the token.- Parameters:
encodedPemCertificate- the encodedPemCertificate value to set.- Returns:
- the TokenCertificate object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<TokenCertificate>- Throws:
IOException
-
fromJson
Reads an instance of TokenCertificate from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of TokenCertificate if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IOException- If an error occurs while reading the TokenCertificate.
-