Package org.goplanit.utils.id
Interface IdAble
-
- All Superinterfaces:
Comparable<IdAble>
- All Known Subinterfaces:
ACyclicSubGraph
,Bush
,Centroid
,CentroidVertex
,ConjugateACyclicSubGraph
,ConjugateConnectoidEdge
,ConjugateConnectoidNode
,ConjugateConnectoidSegment
,ConjugateDirectedEdge
,ConjugateDirectedSubGraph
,ConjugateDirectedVertex
,ConjugateEdge
,ConjugateEdgeSegment
,ConjugateLink
,ConjugateLinkSegment
,ConjugateMacroscopicNetworkLayer
,ConjugateNode
,ConjugateVertex
,Connectoid
,ConnectoidEdge
,ConnectoidSegment
,DemandsModificationEvent
,DirectedConnectoid
,DirectedEdge
,DirectedGraph<V,E,ES>
,DirectedGraphModificationEvent
,DirectedSubGraph<V,E>
,DirectedVertex
,Edge
,EdgeSegment
,Event
,ExternalIdAble
,Graph<V,E>
,GraphEntity
,GraphModificationEvent
,Link
,LinkSegment
,MacroscopicLink
,MacroscopicLinkSegment
,MacroscopicLinkSegmentType
,MacroscopicNetworkLayer
,ManagedDirectedPath
,ManagedId
,Mode
,NetworkLayer
,Node
,OdData<T>
,OdDemands
,OdHashed<T>
,OdMatrix<T,U>
,OdPaths
,OdZone
,PhysicalLayer
,PlanitComponentEvent
,PredefinedMode
,RemoveDirectedSubGraphListener
,RemoveSubGraphListener
,RoutedService
,RoutedServicesLayer
,RoutedServicesModificationEvent
,RoutedTrip
,RoutedTripDeparture
,RoutedTripFrequency
,RoutedTripSchedule
,ServiceLeg
,ServiceLegSegment
,ServiceNetworkLayer
,ServiceNode
,TimePeriod
,TopologicalLayer
,TransferZone
,TransferZoneGroup
,UndirectedConnectoid
,UntypedACyclicSubGraph<V,E>
,UntypedDirectedGraph<V,E,ES>
,UntypedDirectedGraphLayer<V,E,S>
,UntypedGraph<V,E>
,UntypedPhysicalLayer<N,L,LS>
,Vertex
,Zone
,ZoningModificationEvent
- All Known Implementing Classes:
AbstractPhysicalCost
,AbstractVirtualCost
,ACyclicSubGraphImpl
,AlgorithmB
,BicycleMode
,BprLinkTravelTimeCost
,BreakEdgeEvent
,BreakEdgeSegmentEvent
,BusMode
,CarHighOccupancyMode
,CarMode
,CarShareMode
,CentroidImpl
,CentroidVertexImpl
,ConjugateACyclicSubGraphImpl
,ConjugateConnectoidEdgeImpl
,ConjugateConnectoidNodeImpl
,ConjugateConnectoidSegmentImpl
,ConjugateDestinationBush
,ConjugateDirectedEdgeImpl
,ConjugateDirectedGraphImpl
,ConjugateDirectedVertexImpl
,ConjugateEdgeImpl
,ConjugateEdgeSegmentImpl
,ConjugateGraphImpl
,ConjugateLinkImpl
,ConjugateLinkSegmentImpl
,ConjugateMacroscopicNetworkLayerImpl
,ConjugateNodeImpl
,ConjugateVertexImpl
,ConnectoidEdgeImpl
,ConnectoidImpl
,ConnectoidSegmentImpl
,CumulativeEvent
,Demands
,DestinationBush
,DirectedConnectoidImpl
,DirectedEdgeImpl
,DirectedGraphImpl
,DirectedVertexImpl
,EdgeImpl
,EdgeSegmentImpl
,EventBasedLtm
,EventImpl
,ExternalIdAbleImpl
,FerryMode
,FixedConnectoidTravelTimeCost
,FixedInitialMacroscopicLinkSegmentCost
,FreeFlowLinkTravelTimeCost
,FundamentalDiagramComponent
,GapFunction
,GoodsMode
,GraphEntityImpl
,GraphImpl
,HeavyGoodsMode
,IdAbleImpl
,InitialMacroscopicLinkSegmentCost
,InitialPhysicalCost
,LargeHeavyGoodsMode
,LayeredNetwork
,LightRailMode
,LinkBasedRelativeDualityGapFunction
,LinkImpl
,LinkSegmentBase
,LogitChoiceModel
,LtmAssignment
,MacroscopicLinkImpl
,MacroscopicLinkSegmentImpl
,MacroscopicLinkSegmentTypeImpl
,MacroscopicNetwork
,MacroscopicNetworkLayerImpl
,ManagedDirectedPathImpl
,ModeImpl
,ModifiedRoutedServicesIdsEvent
,ModifiedRoutedServicesLayerEventImpl
,ModifiedRoutedTripIdsEvent
,ModifiedTripScheduleDepartureIdsEvent
,ModifiedZoneIdsEvent
,MotorBikeMode
,MSASmoothing
,MultinomialLogit
,Network
,NetworkLayerImpl
,NetworkLoading
,NewellFundamentalDiagramComponent
,NodeImpl
,NodeModelComponent
,NormBasedGapFunction
,OdDataImpl
,OdDemandMatrix
,OdHashedImpl
,OdMatrixImpl
,OdNonPrimitiveMatrix
,OdPathMatrix
,OdPathSets
,OdPathsHashed
,OdPrimitiveMatrix
,OdSkimMatrix
,OdZoneImpl
,OriginBush
,PathChoice
,PedestrianMode
,PlanitComponent
,PlanitOsmNetwork
,PopulateComponentEvent
,PopulateDemandsEvent
,PopulateFundamentalDiagramEvent
,PopulateGapFunctionEvent
,PopulateInitialLinkSegmentCostEvent
,PopulateNetworkEvent
,PopulatePhysicalCostEvent
,PopulateRoutedServicesEvent
,PopulateServiceNetworkEvent
,PopulateUntypedComponentEvent
,PopulateZoningEvent
,PredefinedModeImpl
,RecreatedDemandsEntitiesManagedIdsEvent
,RecreatedDirectedGraphEntitiesManagedIdsEvent
,RecreatedGraphEntitiesManagedIdsEvent
,RecreatedZoningEntitiesManagedIdsEvent
,ReleaseEvent
,ReleaseFlowEvent
,RemoveSubGraphEdgeEvent
,RemoveSubGraphEdgeSegmentEvent
,RemoveSubGraphEvent
,RemoveSubGraphListenerImpl
,RemoveSubGraphVertexEvent
,RootedBush
,RootedLabelledBush
,RoutedServiceImpl
,RoutedServices
,RoutedServicesLayerImpl
,RoutedTripDepartureImpl
,RoutedTripFrequencyImpl
,RoutedTripImpl
,RoutedTripScheduleImpl
,ServiceLegImpl
,ServiceLegSegmentImpl
,ServiceNetwork
,ServiceNetworkLayerImpl
,ServiceNodeImpl
,Smoothing
,SpeedConnectoidTravelTimeCost
,StaticLtm
,StaticTrafficAssignment
,SteadyStateTravelTimeCost
,StochasticPathChoice
,SubwayMode
,TampereNodeModelComponent
,TimePeriodImpl
,TopologicalLayerImpl
,TopologicalLayerNetwork
,TraditionalStaticAssignment
,TrafficAssignment
,TrainMode
,TramMode
,TransferZoneGroupImpl
,TransferZoneImpl
,TravellerType
,TriggerEvent
,TriggerFlowEvent
,UndirectedConnectoidImpl
,UntypedACyclicSubGraphImpl
,UntypedDirectedGraphImpl
,UntypedGraphImpl
,UntypedNetworkLayerImpl
,UntypedPhysicalLayerImpl
,UntypedPhysicalNetwork
,UserClass
,VertexImpl
,VirtualNetworkImpl
,ZoneImpl
,Zoning
public interface IdAble extends Comparable<IdAble>
A class implementing this interface signals that it is id-able- Author:
- markr
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default int
compareTo(IdAble o)
Compare based on idIdAble
deepClone()
An id entity should always support a deep copy, i.e., all "owned" members will be deep copied when a clone of this instance is created via this call.static long
generateId(Class<?> classIdentifier, IdGroupingToken idtoken)
Convenience method to generate an id using a unique class identifier and idToken which in turn delegates to theIdGenerator.generateId()
long
getId()
Collect id of the entitydefault boolean
idEquals(Object o)
equals based on iddefault int
idHashCode()
Generate hash code based on idIdAble
shallowClone()
Create a shallow copy of this entity
-
-
-
Method Detail
-
generateId
static long generateId(Class<?> classIdentifier, IdGroupingToken idtoken)
Convenience method to generate an id using a unique class identifier and idToken which in turn delegates to theIdGenerator.generateId()
- Parameters:
classIdentifier
- to useidtoken
- to use- Returns:
- generated id
-
getId
long getId()
Collect id of the entity- Returns:
- id found
-
shallowClone
IdAble shallowClone()
Create a shallow copy of this entity- Returns:
- shallow copy of entity
-
deepClone
IdAble deepClone()
An id entity should always support a deep copy, i.e., all "owned" members will be deep copied when a clone of this instance is created via this call. To be used with caution if not called by managed id container related code- Returns:
- deep copy of entity
-
idEquals
default boolean idEquals(Object o)
equals based on id- Parameters:
o
- object to compare id to- Returns:
- true when equal id, false otherwise
- See Also:
Comparable.compareTo(java.lang.Object)
-
idHashCode
default int idHashCode()
Generate hash code based on id- Returns:
- id based hash code
- See Also:
Comparable.compareTo(java.lang.Object)
-
compareTo
default int compareTo(IdAble o)
Compare based on id- Specified by:
compareTo
in interfaceComparable<IdAble>
- Parameters:
o
- object to compare id to- Returns:
- compare result identical to Long.compare
- See Also:
Comparable.compareTo(java.lang.Object)
-
-