Class QueryMetadataImpl

java.lang.Object
septogeddon.pluginquery.QueryMetadataImpl
All Implemented Interfaces:
QueryMetadata

public class QueryMetadataImpl extends Object implements QueryMetadata
  • Constructor Details

    • QueryMetadataImpl

      public QueryMetadataImpl()
  • Method Details

    • getData

      public <T> T getData(QueryMetadataKey<T> key)
      Description copied from interface: QueryMetadata
      Get data from this storage and parent storage
      Specified by:
      getData in interface QueryMetadata
      Type Parameters:
      T -
      Parameters:
      key -
      Returns:
    • setData

      public <T> void setData(QueryMetadataKey<T> key, T value)
      Description copied from interface: QueryMetadata
      Set data to current storage, will remove if its null, does not affect the parent metadata
      Specified by:
      setData in interface QueryMetadata
      Type Parameters:
      T -
      Parameters:
      key -
      value -
    • getData

      public <T> T getData(QueryMetadataKey<T> key, T defaultValue)
      Description copied from interface: QueryMetadata
      Get data from this storage and parent storage, will use defaultValue if its null
      Specified by:
      getData in interface QueryMetadata
      Type Parameters:
      T -
      Parameters:
      key -
      defaultValue -
      Returns:
    • addParent

      public void addParent(QueryMetadata metadata)
      Description copied from interface: QueryMetadata
      Add parent for further lookup
      Specified by:
      addParent in interface QueryMetadata
      Parameters:
      metadata -
    • removeParent

      public void removeParent(QueryMetadata metadata)
      Description copied from interface: QueryMetadata
      Remove parent
      Specified by:
      removeParent in interface QueryMetadata
      Parameters:
      metadata -
    • containsData

      public <T> boolean containsData(QueryMetadataKey<T> key)
      Description copied from interface: QueryMetadata
      Check if this storage contains wanted data, does not check the parent
      Specified by:
      containsData in interface QueryMetadata
      Parameters:
      key -
      Returns: