Interface VersionedNetexEntityIndex<V extends org.rutebanken.netex.model.EntityStructure>

Type Parameters:
V -
All Known Implementing Classes:
VersionedNetexEntityIndexImpl

public interface VersionedNetexEntityIndex<V extends org.rutebanken.netex.model.EntityStructure>
An index of versioned NeTEx entities
  • Method Details

    • getLatestVersion

      V getLatestVersion(String id)
      Return the element with the latest version with the given id. Returns null if no element is found.
    • getVersion

      V getVersion(String id, String version)
      Return the element with the given id and version. Returns null if no element is found
      Parameters:
      id -
      version -
      Returns:
    • getLatestVersions

      Collection<V> getLatestVersions()
      Return the latest version of all entities
      Returns:
    • getAllVersions

      Collection<V> getAllVersions(String id)
      Lookup all versions of element with the given id.
      Returns:
      an empty collection if no elements are found.
    • getAllVersions

      Map<String,Collection<V>> getAllVersions()
      Get all versions of all entities
      Returns:
    • put

      void put(String id, Collection<V> entities)
      Put all versions of an entity into the index. If the entity already exists in the index, all versions will be replaced.
      Parameters:
      id -
      entities -
    • putAll

      void putAll(Collection<V> entities)
      Put all entities into the collection If an entity already exists in the index, all versions will be replaced.
      Parameters:
      entities -
    • remove

      void remove(String id)
      Remove all versions of an entity from the index given its id