Interface DataChannelMetaData

  • All Known Implementing Classes:
    DefaultDataChannelMetaData, NoopDataChannelMetaData

    public interface DataChannelMetaData

    Storage for all kind of meta data that is not required for runtime.

    Currently used by Modeler and cli tools (e.g. Maven, Ant and Gradle) to store project extra data.

    Usage:

          // attach custom information to data map
          metaData.add(dataMap, myObject);
    
          // read data
          MyObject obj = metaData.get(dataMap, MyObject.class);
     

    Since:
    4.1
    • Method Detail

      • add

        void add​(ConfigurationNode key,
                 Object value)
        Store data for object.
        Parameters:
        key - object for which we want to store data
        value - data to store
      • get

        <T> T get​(ConfigurationNode key,
                  Class<T> type)
        Get meta data for object
        Type Parameters:
        T - meta data type
        Parameters:
        key - object for wich we want meta data
        type - meta data type class
        Returns:
        value or null if no data available
      • remove

        <T> T remove​(ConfigurationNode key,
                     Class<T> type)
        Type Parameters:
        T - meta data type
        Parameters:
        key - object for wich we want meta data
        type - meta data type class
        Returns:
        value or null if no can't remove
        Since:
        4.1