Class MetadataIndexStore<T>

  • Type Parameters:
    T - the type of data being indexed

    public class MetadataIndexStore<T>
    extends Object
    Component which stores indexed instances of a particular type of data, for example EntityDescriptor, under one or more instances of MetadataIndexKey.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private Map<org.opensaml.saml.metadata.resolver.index.MetadataIndexKey,​Set<T>> index
      The indexed storage of data.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void add​(org.opensaml.saml.metadata.resolver.index.MetadataIndexKey key, T item)
      Add the supplied data item to the index under the supplied MetadataIndexKey.
      void clear()
      Clear all indexed data items from the store.
      void clear​(org.opensaml.saml.metadata.resolver.index.MetadataIndexKey key)
      Clear all data items indexed under the supplied MetadataIndexKey.
      Set<org.opensaml.saml.metadata.resolver.index.MetadataIndexKey> getKeys()
      Get the set of all MetadataIndexKey instances currently indexed.
      Set<T> lookup​(org.opensaml.saml.metadata.resolver.index.MetadataIndexKey key)
      Lookup the instances of data indexed under the supplied MetadataIndexKey.
      void remove​(org.opensaml.saml.metadata.resolver.index.MetadataIndexKey key, T item)
      Remove the supplied data item from the index under the supplied MetadataIndexKey.
    • Field Detail

      • index

        @Nonnull
        private Map<org.opensaml.saml.metadata.resolver.index.MetadataIndexKey,​Set<T>> index
        The indexed storage of data.
    • Constructor Detail

      • MetadataIndexStore

        public MetadataIndexStore()
        Constructor.
    • Method Detail

      • getKeys

        @Nonnull
        @NonnullElements
        @Unmodifiable
        @NotLive
        public Set<org.opensaml.saml.metadata.resolver.index.MetadataIndexKey> getKeys()
        Get the set of all MetadataIndexKey instances currently indexed.
        Returns:
        the set of all currently indexed keys
      • lookup

        @Nonnull
        @NonnullElements
        @Unmodifiable
        @NotLive
        public Set<T> lookup​(@Nonnull
                             org.opensaml.saml.metadata.resolver.index.MetadataIndexKey key)
        Lookup the instances of data indexed under the supplied MetadataIndexKey.
        Parameters:
        key - the index key to lookup
        Returns:
        the set of data items indexed under that key
      • add

        public void add​(org.opensaml.saml.metadata.resolver.index.MetadataIndexKey key,
                        T item)
        Add the supplied data item to the index under the supplied MetadataIndexKey.
        Parameters:
        key - the index key
        item - the data item to index
      • remove

        public void remove​(org.opensaml.saml.metadata.resolver.index.MetadataIndexKey key,
                           T item)
        Remove the supplied data item from the index under the supplied MetadataIndexKey.
        Parameters:
        key - the index key
        item - the data item to index
      • clear

        public void clear​(org.opensaml.saml.metadata.resolver.index.MetadataIndexKey key)
        Clear all data items indexed under the supplied MetadataIndexKey.
        Parameters:
        key - the index key
      • clear

        public void clear()
        Clear all indexed data items from the store.