Class CreateKeyRequest.Builder
- java.lang.Object
-
- com.microsoft.azure.keyvault.requests.CreateKeyRequest.Builder
-
- Enclosing class:
- CreateKeyRequest
public static class CreateKeyRequest.Builder extends Object
TheCreateKeyRequest
builder.
-
-
Constructor Summary
Constructors Constructor Description Builder(String vaultBaseUrl, String keyName, JsonWebKeyType keyType)
The builder for constructingCreateKeyRequest
object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CreateKeyRequest
build()
builds theCreateKeyRequest
object.CreateKeyRequest.Builder
withAttributes(Attributes attributes)
Set the key attributes value.CreateKeyRequest.Builder
withCurve(JsonWebKeyCurveName curve)
Set the curve value.CreateKeyRequest.Builder
withKeyOperations(List<JsonWebKeyOperation> keyOperations)
Set the key operations value.CreateKeyRequest.Builder
withKeySize(Integer size)
Set the key size value.CreateKeyRequest.Builder
withTags(Map<String,String> tags)
Set the tags value.
-
-
-
Constructor Detail
-
Builder
public Builder(String vaultBaseUrl, String keyName, JsonWebKeyType keyType)
The builder for constructingCreateKeyRequest
object.- Parameters:
vaultBaseUrl
- The vault name, e.g. https://myvault.vault.azure.netkeyName
- The name of the key in the given vaultkeyType
- The type of key to create. Valid key types, see JsonWebKeyType. Supported JsonWebKey key types (kty) for Elliptic Curve, RSA, HSM, Octet. Possible values include: 'EC', 'RSA', 'RSA-HSM', 'oct'
-
-
Method Detail
-
withKeySize
public CreateKeyRequest.Builder withKeySize(Integer size)
Set the key size value.- Parameters:
size
- the size of the key.- Returns:
- the Builder object itself.
-
withKeyOperations
public CreateKeyRequest.Builder withKeyOperations(List<JsonWebKeyOperation> keyOperations)
Set the key operations value.- Parameters:
keyOperations
- the key operation list.- Returns:
- the Builder object itself.
-
withAttributes
public CreateKeyRequest.Builder withAttributes(Attributes attributes)
Set the key attributes value.- Parameters:
attributes
- the key management attributes value to set.- Returns:
- the Builder object itself.
-
withTags
public CreateKeyRequest.Builder withTags(Map<String,String> tags)
Set the tags value.- Parameters:
tags
- Application-specific metadata in the form of key-value pairs.- Returns:
- the Builder object itself.
-
withCurve
public CreateKeyRequest.Builder withCurve(JsonWebKeyCurveName curve)
Set the curve value.- Parameters:
curve
- Defines values for JsonWebKeyCurveName;- Returns:
- the Builder object itself.
-
build
public CreateKeyRequest build()
builds theCreateKeyRequest
object.- Returns:
- the
CreateKeyRequest
object.
-
-