@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class Tag extends Object implements Serializable, Cloneable, StructuredPojo
A tag is a label that you can define and associate with Amazon Web Services resources, including certain types of Amazon Security Lake resources. Tags can help you identify, categorize, and manage resources in different ways, such as by owner, environment, or other criteria. You can associate tags with the following types of Security Lake resources: subscribers, and the data lake configuration for your Amazon Web Services account in individual Amazon Web Services Regions.
A resource can have up to 50 tags. Each tag consists of a required tag key and an associated tag value. A tag key is a general label that acts as a category for a more specific tag value. Each tag key must be unique and it can have only one tag value. A tag value acts as a descriptor for a tag key. Tag keys and values are case sensitive. They can contain letters, numbers, spaces, or the following symbols: _ . : / = + @ -
For more information, see Tagging Amazon Security Lake resources in the Amazon Security Lake User Guide.
Constructor and Description |
---|
Tag() |
Modifier and Type | Method and Description |
---|---|
Tag |
clone() |
boolean |
equals(Object obj) |
String |
getKey()
The name of the tag.
|
String |
getValue()
The value that’s associated with the specified tag key (
key ). |
int |
hashCode() |
void |
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . |
void |
setKey(String key)
The name of the tag.
|
void |
setValue(String value)
The value that’s associated with the specified tag key (
key ). |
String |
toString()
Returns a string representation of this object.
|
Tag |
withKey(String key)
The name of the tag.
|
Tag |
withValue(String value)
The value that’s associated with the specified tag key (
key ). |
public void setKey(String key)
The name of the tag. This is a general label that acts as a category for a more specific tag value (
value
).
key
- The name of the tag. This is a general label that acts as a category for a more specific tag value (
value
).public String getKey()
The name of the tag. This is a general label that acts as a category for a more specific tag value (
value
).
value
).public Tag withKey(String key)
The name of the tag. This is a general label that acts as a category for a more specific tag value (
value
).
key
- The name of the tag. This is a general label that acts as a category for a more specific tag value (
value
).public void setValue(String value)
The value that’s associated with the specified tag key (key
). This value acts as a descriptor for
the tag key. A tag value cannot be null, but it can be an empty string.
value
- The value that’s associated with the specified tag key (key
). This value acts as a descriptor
for the tag key. A tag value cannot be null, but it can be an empty string.public String getValue()
The value that’s associated with the specified tag key (key
). This value acts as a descriptor for
the tag key. A tag value cannot be null, but it can be an empty string.
key
). This value acts as a
descriptor for the tag key. A tag value cannot be null, but it can be an empty string.public Tag withValue(String value)
The value that’s associated with the specified tag key (key
). This value acts as a descriptor for
the tag key. A tag value cannot be null, but it can be an empty string.
value
- The value that’s associated with the specified tag key (key
). This value acts as a descriptor
for the tag key. A tag value cannot be null, but it can be an empty string.public String toString()
toString
in class Object
Object.toString()
public void marshall(ProtocolMarshaller protocolMarshaller)
StructuredPojo
ProtocolMarshaller
.marshall
in interface StructuredPojo
protocolMarshaller
- Implementation of ProtocolMarshaller
used to marshall this object's data.