Class TagSet

java.lang.Object
com.amazonaws.services.s3.model.TagSet
All Implemented Interfaces:
Serializable

public class TagSet extends Object implements Serializable
See Also:
  • Constructor Details

    • TagSet

      public TagSet()

      Creates a new empty TagSet.

      See Also:
    • TagSet

      public TagSet(Map<String,String> tags)

      Creates a new TagSet with the set of tags defined.

      Parameters:
      tags - A key/value mapping of tags to store in this TagSet
  • Method Details

    • getTag

      public String getTag(String key)

      Get the value of the tag with the given key.

      Parameters:
      key - The key of the tag to return
      Returns:
      The value of the given tag. Will return null if no tag by the given key exists.
    • setTag

      public void setTag(String key, String value)

      Sets the value of the tag for a given key. Will overwrite existing value.

      Parameters:
      key - The key for the tag
      value - The value for the tag
    • getAllTags

      public Map<String,String> getAllTags()

      Get all the tags for this TagSet

      Returns:
      A map of key/value for all tags
    • toString

      public String toString()
      Overrides:
      toString in class Object