Interface OdHashed<T>

  • All Superinterfaces:
    Cloneable, Comparable<IdAble>, IdAble, Iterable<T>, OdData<T>
    All Known Implementing Classes:
    OdHashedImpl, OdPathsHashed

    public interface OdHashed<T>
    extends OdData<T>
    This interface represents a hashed based implementation for handling origin-demand matrices of a certain type where the data is modelled by a single hash key generated from the OD zone information
    Author:
    markr
    • Method Detail

      • generateHashKey

        static int generateHashKey​(long originZoneId,
                                   long destinationZoneId)
        generate a hash based on origin and destination zone id
        Parameters:
        originZoneId - to use
        destinationZoneId - to use
        Returns:
        generated combined hash key
      • iterator

        OdHashedIterator<T> iterator()
        Returns an iterator which can iterate through all the origin-destination entries
        Specified by:
        iterator in interface Iterable<T>
        Specified by:
        iterator in interface OdData<T>
        Returns:
        iterator through all available non-empty origin-destination entries