@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class CreateKeyRequest extends AmazonWebServiceRequest implements Serializable, Cloneable
NOOP
Constructor and Description |
---|
CreateKeyRequest() |
Modifier and Type | Method and Description |
---|---|
CreateKeyRequest |
addTagsEntry(String key,
String value)
Add a single Tags entry
|
CreateKeyRequest |
clearTagsEntries()
Removes all the entries added into Tags.
|
CreateKeyRequest |
clone()
Creates a shallow clone of this object for all fields except the handler context.
|
boolean |
equals(Object obj) |
String |
getDescription()
An optional description for the API key resource.
|
Date |
getExpireTime()
The optional timestamp for when the API key resource will expire in ISO 8601 format:
YYYY-MM-DDThh:mm:ss.sssZ . |
String |
getKeyName()
A custom name for the API key resource.
|
Boolean |
getNoExpiry()
Optionally set to
true to set no expiration time for the API key. |
ApiKeyRestrictions |
getRestrictions()
The API key restrictions for the API key resource.
|
Map<String,String> |
getTags()
Applies one or more tags to the map resource.
|
int |
hashCode() |
Boolean |
isNoExpiry()
Optionally set to
true to set no expiration time for the API key. |
void |
setDescription(String description)
An optional description for the API key resource.
|
void |
setExpireTime(Date expireTime)
The optional timestamp for when the API key resource will expire in ISO 8601 format:
YYYY-MM-DDThh:mm:ss.sssZ . |
void |
setKeyName(String keyName)
A custom name for the API key resource.
|
void |
setNoExpiry(Boolean noExpiry)
Optionally set to
true to set no expiration time for the API key. |
void |
setRestrictions(ApiKeyRestrictions restrictions)
The API key restrictions for the API key resource.
|
void |
setTags(Map<String,String> tags)
Applies one or more tags to the map resource.
|
String |
toString()
Returns a string representation of this object.
|
CreateKeyRequest |
withDescription(String description)
An optional description for the API key resource.
|
CreateKeyRequest |
withExpireTime(Date expireTime)
The optional timestamp for when the API key resource will expire in ISO 8601 format:
YYYY-MM-DDThh:mm:ss.sssZ . |
CreateKeyRequest |
withKeyName(String keyName)
A custom name for the API key resource.
|
CreateKeyRequest |
withNoExpiry(Boolean noExpiry)
Optionally set to
true to set no expiration time for the API key. |
CreateKeyRequest |
withRestrictions(ApiKeyRestrictions restrictions)
The API key restrictions for the API key resource.
|
CreateKeyRequest |
withTags(Map<String,String> tags)
Applies one or more tags to the map resource.
|
addHandlerContext, getCloneRoot, getCloneSource, getCustomQueryParameters, getCustomRequestHeaders, getGeneralProgressListener, getHandlerContext, getReadLimit, getRequestClientOptions, getRequestCredentials, getRequestCredentialsProvider, getRequestMetricCollector, getSdkClientExecutionTimeout, getSdkRequestTimeout, putCustomQueryParameter, putCustomRequestHeader, setGeneralProgressListener, setRequestCredentials, setRequestCredentialsProvider, setRequestMetricCollector, setSdkClientExecutionTimeout, setSdkRequestTimeout, withGeneralProgressListener, withRequestCredentialsProvider, withRequestMetricCollector, withSdkClientExecutionTimeout, withSdkRequestTimeout
public void setKeyName(String keyName)
A custom name for the API key resource.
Requirements:
Contain only alphanumeric characters (A–Z, a–z, 0–9), hyphens (-), periods (.), and underscores (_).
Must be a unique API key name.
No spaces allowed. For example, ExampleAPIKey
.
keyName
- A custom name for the API key resource.
Requirements:
Contain only alphanumeric characters (A–Z, a–z, 0–9), hyphens (-), periods (.), and underscores (_).
Must be a unique API key name.
No spaces allowed. For example, ExampleAPIKey
.
public String getKeyName()
A custom name for the API key resource.
Requirements:
Contain only alphanumeric characters (A–Z, a–z, 0–9), hyphens (-), periods (.), and underscores (_).
Must be a unique API key name.
No spaces allowed. For example, ExampleAPIKey
.
Requirements:
Contain only alphanumeric characters (A–Z, a–z, 0–9), hyphens (-), periods (.), and underscores (_).
Must be a unique API key name.
No spaces allowed. For example, ExampleAPIKey
.
public CreateKeyRequest withKeyName(String keyName)
A custom name for the API key resource.
Requirements:
Contain only alphanumeric characters (A–Z, a–z, 0–9), hyphens (-), periods (.), and underscores (_).
Must be a unique API key name.
No spaces allowed. For example, ExampleAPIKey
.
keyName
- A custom name for the API key resource.
Requirements:
Contain only alphanumeric characters (A–Z, a–z, 0–9), hyphens (-), periods (.), and underscores (_).
Must be a unique API key name.
No spaces allowed. For example, ExampleAPIKey
.
public void setRestrictions(ApiKeyRestrictions restrictions)
The API key restrictions for the API key resource.
restrictions
- The API key restrictions for the API key resource.public ApiKeyRestrictions getRestrictions()
The API key restrictions for the API key resource.
public CreateKeyRequest withRestrictions(ApiKeyRestrictions restrictions)
The API key restrictions for the API key resource.
restrictions
- The API key restrictions for the API key resource.public void setDescription(String description)
An optional description for the API key resource.
description
- An optional description for the API key resource.public String getDescription()
An optional description for the API key resource.
public CreateKeyRequest withDescription(String description)
An optional description for the API key resource.
description
- An optional description for the API key resource.public void setExpireTime(Date expireTime)
The optional timestamp for when the API key resource will expire in ISO 8601 format:
YYYY-MM-DDThh:mm:ss.sssZ
. One of NoExpiry
or ExpireTime
must be set.
expireTime
- The optional timestamp for when the API key resource will expire in ISO 8601 format:
YYYY-MM-DDThh:mm:ss.sssZ
. One of NoExpiry
or ExpireTime
must be
set.public Date getExpireTime()
The optional timestamp for when the API key resource will expire in ISO 8601 format:
YYYY-MM-DDThh:mm:ss.sssZ
. One of NoExpiry
or ExpireTime
must be set.
YYYY-MM-DDThh:mm:ss.sssZ
. One of NoExpiry
or ExpireTime
must be
set.public CreateKeyRequest withExpireTime(Date expireTime)
The optional timestamp for when the API key resource will expire in ISO 8601 format:
YYYY-MM-DDThh:mm:ss.sssZ
. One of NoExpiry
or ExpireTime
must be set.
expireTime
- The optional timestamp for when the API key resource will expire in ISO 8601 format:
YYYY-MM-DDThh:mm:ss.sssZ
. One of NoExpiry
or ExpireTime
must be
set.public void setNoExpiry(Boolean noExpiry)
Optionally set to true
to set no expiration time for the API key. One of NoExpiry
or
ExpireTime
must be set.
noExpiry
- Optionally set to true
to set no expiration time for the API key. One of
NoExpiry
or ExpireTime
must be set.public Boolean getNoExpiry()
Optionally set to true
to set no expiration time for the API key. One of NoExpiry
or
ExpireTime
must be set.
true
to set no expiration time for the API key. One of
NoExpiry
or ExpireTime
must be set.public CreateKeyRequest withNoExpiry(Boolean noExpiry)
Optionally set to true
to set no expiration time for the API key. One of NoExpiry
or
ExpireTime
must be set.
noExpiry
- Optionally set to true
to set no expiration time for the API key. One of
NoExpiry
or ExpireTime
must be set.public Boolean isNoExpiry()
Optionally set to true
to set no expiration time for the API key. One of NoExpiry
or
ExpireTime
must be set.
true
to set no expiration time for the API key. One of
NoExpiry
or ExpireTime
must be set.public Map<String,String> getTags()
Applies one or more tags to the map resource. A tag is a key-value pair that helps manage, identify, search, and filter your resources by labelling them.
Format: "key" : "value"
Restrictions:
Maximum 50 tags per resource
Each resource tag must be unique with a maximum of one value.
Maximum key length: 128 Unicode characters in UTF-8
Maximum value length: 256 Unicode characters in UTF-8
Can use alphanumeric characters (A–Z, a–z, 0–9), and the following characters: + - = . _ : / @.
Cannot use "aws:" as a prefix for a key.
Format: "key" : "value"
Restrictions:
Maximum 50 tags per resource
Each resource tag must be unique with a maximum of one value.
Maximum key length: 128 Unicode characters in UTF-8
Maximum value length: 256 Unicode characters in UTF-8
Can use alphanumeric characters (A–Z, a–z, 0–9), and the following characters: + - = . _ : / @.
Cannot use "aws:" as a prefix for a key.
public void setTags(Map<String,String> tags)
Applies one or more tags to the map resource. A tag is a key-value pair that helps manage, identify, search, and filter your resources by labelling them.
Format: "key" : "value"
Restrictions:
Maximum 50 tags per resource
Each resource tag must be unique with a maximum of one value.
Maximum key length: 128 Unicode characters in UTF-8
Maximum value length: 256 Unicode characters in UTF-8
Can use alphanumeric characters (A–Z, a–z, 0–9), and the following characters: + - = . _ : / @.
Cannot use "aws:" as a prefix for a key.
tags
- Applies one or more tags to the map resource. A tag is a key-value pair that helps manage, identify,
search, and filter your resources by labelling them.
Format: "key" : "value"
Restrictions:
Maximum 50 tags per resource
Each resource tag must be unique with a maximum of one value.
Maximum key length: 128 Unicode characters in UTF-8
Maximum value length: 256 Unicode characters in UTF-8
Can use alphanumeric characters (A–Z, a–z, 0–9), and the following characters: + - = . _ : / @.
Cannot use "aws:" as a prefix for a key.
public CreateKeyRequest withTags(Map<String,String> tags)
Applies one or more tags to the map resource. A tag is a key-value pair that helps manage, identify, search, and filter your resources by labelling them.
Format: "key" : "value"
Restrictions:
Maximum 50 tags per resource
Each resource tag must be unique with a maximum of one value.
Maximum key length: 128 Unicode characters in UTF-8
Maximum value length: 256 Unicode characters in UTF-8
Can use alphanumeric characters (A–Z, a–z, 0–9), and the following characters: + - = . _ : / @.
Cannot use "aws:" as a prefix for a key.
tags
- Applies one or more tags to the map resource. A tag is a key-value pair that helps manage, identify,
search, and filter your resources by labelling them.
Format: "key" : "value"
Restrictions:
Maximum 50 tags per resource
Each resource tag must be unique with a maximum of one value.
Maximum key length: 128 Unicode characters in UTF-8
Maximum value length: 256 Unicode characters in UTF-8
Can use alphanumeric characters (A–Z, a–z, 0–9), and the following characters: + - = . _ : / @.
Cannot use "aws:" as a prefix for a key.
public CreateKeyRequest addTagsEntry(String key, String value)
public CreateKeyRequest clearTagsEntries()
public String toString()
toString
in class Object
Object.toString()
public CreateKeyRequest clone()
AmazonWebServiceRequest
clone
in class AmazonWebServiceRequest
Object.clone()