@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class Tag extends Object implements Serializable, Cloneable, StructuredPojo
One tag that you want to add to the specified resource. A tag consists of a Key
(a name for the tag) and
a Value
.
Constructor and Description |
---|
Tag() |
Modifier and Type | Method and Description |
---|---|
Tag |
clone() |
boolean |
equals(Object obj) |
String |
getKey()
The name for the tag.
|
String |
getValue()
The value for the tag.
|
int |
hashCode() |
void |
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . |
void |
setKey(String key)
The name for the tag.
|
void |
setValue(String value)
The value for the tag.
|
String |
toString()
Returns a string representation of this object.
|
Tag |
withKey(String key)
The name for the tag.
|
Tag |
withValue(String value)
The value for the tag.
|
public void setKey(String key)
The name for the tag. For example, if you want to associate Resolver resources with the account IDs of your
customers for billing purposes, the value of Key
might be account-id
.
key
- The name for the tag. For example, if you want to associate Resolver resources with the account IDs of
your customers for billing purposes, the value of Key
might be account-id
.public String getKey()
The name for the tag. For example, if you want to associate Resolver resources with the account IDs of your
customers for billing purposes, the value of Key
might be account-id
.
Key
might be account-id
.public Tag withKey(String key)
The name for the tag. For example, if you want to associate Resolver resources with the account IDs of your
customers for billing purposes, the value of Key
might be account-id
.
key
- The name for the tag. For example, if you want to associate Resolver resources with the account IDs of
your customers for billing purposes, the value of Key
might be account-id
.public void setValue(String value)
The value for the tag. For example, if Key
is account-id
, then Value
might
be the ID of the customer account that you're creating the resource for.
value
- The value for the tag. For example, if Key
is account-id
, then
Value
might be the ID of the customer account that you're creating the resource for.public String getValue()
The value for the tag. For example, if Key
is account-id
, then Value
might
be the ID of the customer account that you're creating the resource for.
Key
is account-id
, then
Value
might be the ID of the customer account that you're creating the resource for.public Tag withValue(String value)
The value for the tag. For example, if Key
is account-id
, then Value
might
be the ID of the customer account that you're creating the resource for.
value
- The value for the tag. For example, if Key
is account-id
, then
Value
might be the ID of the customer account that you're creating the resource for.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.