Class CreateKeyRequest.Builder
- java.lang.Object
-
- com.microsoft.azure.keyvault.requests.CreateKeyRequest.Builder
-
- Enclosing class:
- CreateKeyRequest
public static class CreateKeyRequest.Builder extends Object
TheCreateKeyRequestbuilder.
-
-
Constructor Summary
Constructors Constructor Description Builder(String vaultBaseUrl, String keyName, JsonWebKeyType keyType)The builder for constructingCreateKeyRequestobject.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CreateKeyRequestbuild()builds theCreateKeyRequestobject.CreateKeyRequest.BuilderwithAttributes(Attributes attributes)Set the key attributes value.CreateKeyRequest.BuilderwithCurve(JsonWebKeyCurveName curve)Set the curve value.CreateKeyRequest.BuilderwithKeyOperations(List<JsonWebKeyOperation> keyOperations)Set the key operations value.CreateKeyRequest.BuilderwithKeySize(Integer size)Set the key size value.CreateKeyRequest.BuilderwithTags(Map<String,String> tags)Set the tags value.
-
-
-
Constructor Detail
-
Builder
public Builder(String vaultBaseUrl, String keyName, JsonWebKeyType keyType)
The builder for constructingCreateKeyRequestobject.- 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 theCreateKeyRequestobject.- Returns:
- the
CreateKeyRequestobject.
-
-