Class ListExtensionsRegistry

  • All Implemented Interfaces:
    ExtensionsRegistry

    public class ListExtensionsRegistry
    extends java.lang.Object
    implements ExtensionsRegistry
    An extension registry that contains several lists of extensions.
    Author:
    Lucian Chirita (lucianc@users.sourceforge.net)
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      <T> ListExtensionsRegistry add​(java.lang.Class<T> type, T extension)
      Adds an extension.
      <T> java.util.List<T> getExtensions​(java.lang.Class<T> extensionType)
      Returns a list of extension objects for a specific extension type.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ListExtensionsRegistry

        public ListExtensionsRegistry()
    • Method Detail

      • add

        public <T> ListExtensionsRegistry add​(java.lang.Class<T> type,
                                              T extension)
        Adds an extension.
        Parameters:
        type - the extension type
        extension - the extension object
        Returns:
        this object
      • getExtensions

        public <T> java.util.List<T> getExtensions​(java.lang.Class<T> extensionType)
        Description copied from interface: ExtensionsRegistry
        Returns a list of extension objects for a specific extension type.
        Specified by:
        getExtensions in interface ExtensionsRegistry
        Type Parameters:
        T - generic extension type
        Parameters:
        extensionType - the extension type
        Returns:
        a list of extension objects