Class MetaDataStateChainingListener

java.lang.Object
org.xwiki.rendering.listener.chaining.AbstractChainingListener
org.xwiki.rendering.listener.chaining.MetaDataStateChainingListener
All Implemented Interfaces:
ChainingListener, ImageListener, LinkListener, Listener

public class MetaDataStateChainingListener extends AbstractChainingListener
Provides the accumulated MetaData for all the previous blocks.
Since:
3.0M2
Version:
$Id: 926934d95736c60c1eb105e6736338c599d53952 $
  • Constructor Details

  • Method Details

    • getAllMetaData

      public <T> List<T> getAllMetaData(String key)
      Type Parameters:
      T - the type of the value for the passed key
      Parameters:
      key - the key for which to find the value
      Returns:
      the accumulated MetaData during all the previous begin/endMetaData events
    • getMetaData

      public <T> T getMetaData(String key)
      Type Parameters:
      T - the type of the value for the passed key
      Parameters:
      key - the key for which to find the value
      Returns:
      the accumulated MetaData during all the previous begin/endMetaData events, for the passed key
    • beginDocument

      public void beginDocument(MetaData metaData)
      Description copied from interface: Listener
      Start of the document.
      Specified by:
      beginDocument in interface Listener
      Overrides:
      beginDocument in class AbstractChainingListener
      Parameters:
      metaData - the meta data to associate to the following events, see MetaData
    • endDocument

      public void endDocument(MetaData metaData)
      Description copied from interface: Listener
      End of the document.
      Specified by:
      endDocument in interface Listener
      Overrides:
      endDocument in class AbstractChainingListener
      Parameters:
      metaData - the meta data associated with the previous events, see MetaData
    • beginMetaData

      public void beginMetaData(MetaData metaData)
      Description copied from interface: Listener
      Start of MetaData (eg saving source from where the content is coming from).
      Specified by:
      beginMetaData in interface Listener
      Overrides:
      beginMetaData in class AbstractChainingListener
      Parameters:
      metaData - the metadata
    • endMetaData

      public void endMetaData(MetaData metaData)
      Description copied from interface: Listener
      End of MetaData.
      Specified by:
      endMetaData in interface Listener
      Overrides:
      endMetaData in class AbstractChainingListener
      Parameters:
      metaData - the metadata