Class SimpleMapFactory

    • Constructor Detail

      • SimpleMapFactory

        public SimpleMapFactory()
    • Method Detail

      • initialise

        public void initialise​(Schema schema,
                               MapStoreProperties properties)
        Description copied from interface: MapFactory
        Initialise the map with the specified schema and properties.
        Specified by:
        initialise in interface MapFactory
        Parameters:
        schema - the schema to apply
        properties - the store properties to apply
      • getMap

        public <K,​V> Map<K,​V> getMap​(String mapName,
                                                 Class<K> keyClass,
                                                 Class<V> valueClass)
        Description copied from interface: MapFactory
        Retrieve a named Map. If the requested map does not exist, a new map is created and cached.
        Specified by:
        getMap in interface MapFactory
        Type Parameters:
        K - the type of the map keys
        V - the type of the map values
        Parameters:
        mapName - the name of the map to retrieve
        keyClass - the class type to use for the map keys
        valueClass - the class type to use for the map values
        Returns:
        the requested Map object
      • getMultiMap

        public <K,​V> MultiMap<K,​V> getMultiMap​(String mapName,
                                                           Class<K> keyClass,
                                                           Class<V> valueClass)
        Description copied from interface: MapFactory
        Retrieve a named MultiMap. If the requested map does not exist, a new multi map is created and cached.
        Specified by:
        getMultiMap in interface MapFactory
        Type Parameters:
        K - the type of the map keys
        V - the type of the map values
        Parameters:
        mapName - the name of the multi map to retrieve
        keyClass - the class type to use for the map keys
        valueClass - the class type to use for the map values
        Returns:
        the requested MultiMap object
      • clear

        public void clear()
        Description copied from interface: MapFactory
        Clear any currently configured Maps.
        Specified by:
        clear in interface MapFactory
      • cloneElement

        public Element cloneElement​(Element element,
                                    Schema schema)
        Description copied from interface: MapFactory
        Clone an element.
        Specified by:
        cloneElement in interface MapFactory
        Parameters:
        element - the element to clone
        schema - the relevant schema
        Returns:
        the cloned element