Class Tag
- java.lang.Object
-
- com.amazonaws.services.inspector.model.Tag
-
- All Implemented Interfaces:
Serializable,Cloneable
public class Tag extends Object implements Serializable, Cloneable
A key and value pair. This data type is used as a request parameter in the SetTagsForResource action and a response element in the ListTagsForResource action.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Tag()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Tagclone()booleanequals(Object obj)StringgetKey()A tag key.StringgetValue()A value assigned to a tag key.inthashCode()voidsetKey(String key)A tag key.voidsetValue(String value)A value assigned to a tag key.StringtoString()Returns a string representation of this object; useful for testing and debugging.TagwithKey(String key)A tag key.TagwithValue(String value)A value assigned to a tag key.
-
-
-
Method Detail
-
setKey
public void setKey(String key)
A tag key.
- Parameters:
key- A tag key.
-
getKey
public String getKey()
A tag key.
- Returns:
- A tag key.
-
withKey
public Tag withKey(String key)
A tag key.
- Parameters:
key- A tag key.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setValue
public void setValue(String value)
A value assigned to a tag key.
- Parameters:
value- A value assigned to a tag key.
-
getValue
public String getValue()
A value assigned to a tag key.
- Returns:
- A value assigned to a tag key.
-
withValue
public Tag withValue(String value)
A value assigned to a tag key.
- Parameters:
value- A value assigned to a tag key.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
toString
public String toString()
Returns a string representation of this object; useful for testing and debugging.- Overrides:
toStringin classObject- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
-