Class CreateRsaKeyOptions
- java.lang.Object
-
- com.azure.security.keyvault.keys.models.CreateKeyOptions
-
- com.azure.security.keyvault.keys.models.CreateRsaKeyOptions
-
public class CreateRsaKeyOptions extends CreateKeyOptions
Represents the configurable options to create an RSA key.
-
-
Constructor Summary
Constructors Constructor Description CreateRsaKeyOptions(String name)Creates aCreateRsaKeyOptionswithnameas name of the RSA key.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IntegergetKeySize()Get the key size in bits.IntegergetPublicExponent()Get the public exponent for the key.BooleanisHardwareProtected()Get the HSM value of the key being created.CreateRsaKeyOptionssetEnabled(Boolean enabled)Set a value that indicates if the key is enabled.CreateRsaKeyOptionssetExpiresOn(OffsetDateTime expiresOn)Set theexpiresUTC time.CreateRsaKeyOptionssetHardwareProtected(Boolean hardwareProtected)Set whether the key being created is of HSM type or not.CreateRsaKeyOptionssetKeyOperations(KeyOperation... keyOperations)Set the key operations.CreateRsaKeyOptionssetKeySize(Integer keySize)Set the key size in bits.CreateRsaKeyOptionssetNotBefore(OffsetDateTime notBefore)Set thenotBeforeUTC time.CreateRsaKeyOptionssetPublicExponent(Integer publicExponent)Set the public exponent for the key.CreateRsaKeyOptionssetTags(Map<String,String> tags)Set the tags to be associated with the key.-
Methods inherited from class com.azure.security.keyvault.keys.models.CreateKeyOptions
getExpiresOn, getKeyOperations, getKeyType, getName, getNotBefore, getTags, isEnabled
-
-
-
-
Constructor Detail
-
CreateRsaKeyOptions
public CreateRsaKeyOptions(String name)
Creates aCreateRsaKeyOptionswithnameas name of the RSA key.- Parameters:
name- The name of the key.
-
-
Method Detail
-
getKeySize
public Integer getKeySize()
Get the key size in bits.- Returns:
- The key size in bits.
-
setKeySize
public CreateRsaKeyOptions setKeySize(Integer keySize)
Set the key size in bits.- Parameters:
keySize- The key size in bits to set.- Returns:
- The updated
CreateRsaKeyOptionsobject.
-
isHardwareProtected
public Boolean isHardwareProtected()
Get the HSM value of the key being created.- Returns:
- The HSM value.
-
setHardwareProtected
public CreateRsaKeyOptions setHardwareProtected(Boolean hardwareProtected)
Set whether the key being created is of HSM type or not.- Parameters:
hardwareProtected- The HSM value to set.- Returns:
- The updated
CreateRsaKeyOptionsobject.
-
getPublicExponent
public Integer getPublicExponent()
Get the public exponent for the key.- Returns:
- The public exponent.
-
setPublicExponent
public CreateRsaKeyOptions setPublicExponent(Integer publicExponent)
Set the public exponent for the key.- Parameters:
publicExponent- The public exponent to set.- Returns:
- The updated
CreateRsaKeyOptionsobject.
-
setKeyOperations
public CreateRsaKeyOptions setKeyOperations(KeyOperation... keyOperations)
Set the key operations.- Overrides:
setKeyOperationsin classCreateKeyOptions- Parameters:
keyOperations- The key operations to set.- Returns:
- The updated
CreateRsaKeyOptionsobject.
-
setNotBefore
public CreateRsaKeyOptions setNotBefore(OffsetDateTime notBefore)
Set thenotBeforeUTC time.- Overrides:
setNotBeforein classCreateKeyOptions- Parameters:
notBefore- The notBefore UTC time to set.- Returns:
- The updated
CreateRsaKeyOptionsobject.
-
setExpiresOn
public CreateRsaKeyOptions setExpiresOn(OffsetDateTime expiresOn)
Set theexpiresUTC time.- Overrides:
setExpiresOnin classCreateKeyOptions- Parameters:
expiresOn- The expiry time to set for the key.- Returns:
- The updated
CreateRsaKeyOptionsobject.
-
setTags
public CreateRsaKeyOptions setTags(Map<String,String> tags)
Set the tags to be associated with the key.- Overrides:
setTagsin classCreateKeyOptions- Parameters:
tags- The tags to set.- Returns:
- The updated
CreateRsaKeyOptionsobject.
-
setEnabled
public CreateRsaKeyOptions setEnabled(Boolean enabled)
Set a value that indicates if the key is enabled.- Overrides:
setEnabledin classCreateKeyOptions- Parameters:
enabled- The enabled value to set.- Returns:
- The updated
CreateRsaKeyOptionsobject.
-
-