Package org.planit.cost.virtual
Class VirtualCost
- java.lang.Object
-
- org.djutils.event.EventProducer
-
- org.planit.trafficassignment.TrafficAssignmentComponent<VirtualCost>
-
- org.planit.cost.virtual.VirtualCost
-
- All Implemented Interfaces:
Serializable
,org.djutils.event.EventProducerInterface
,Cost<ConnectoidSegment>
- Direct Known Subclasses:
FixedConnectoidTravelTimeCost
,SpeedConnectoidTravelTimeCost
public abstract class VirtualCost extends TrafficAssignmentComponent<VirtualCost> implements Cost<ConnectoidSegment>
Object to handle the travel time cost of a virtual link- Author:
- markr
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
FIXED
short hand for configuring fixed virtual cost instancestatic String
SPEED
short hand for configuring speed based virtual cost instance-
Fields inherited from class org.planit.trafficassignment.TrafficAssignmentComponent
groupId, id, trafficComponentType
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
VirtualCost(IdGroupingToken groupId)
Constructor
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract void
initialiseBeforeSimulation(VirtualNetwork virtualNetwork)
Initialize the virtual cost component-
Methods inherited from class org.planit.trafficassignment.TrafficAssignmentComponent
getId, getIdGroupingtoken, getSourceId, getTrafficComponentType
-
Methods inherited from class org.djutils.event.EventProducer
addListener, addListener, addListener, addListener, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, getEventTypesWithListeners, hasListeners, numberOfListeners, removeAllListeners, removeAllListeners, removeListener
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.planit.cost.Cost
getSegmentCost
-
-
-
-
Constructor Detail
-
VirtualCost
protected VirtualCost(IdGroupingToken groupId)
Constructor- Parameters:
groupId
- , contiguous id generation within this group for instances of this class
-
-
Method Detail
-
initialiseBeforeSimulation
public abstract void initialiseBeforeSimulation(VirtualNetwork virtualNetwork) throws PlanItException
Initialize the virtual cost component- Parameters:
virtualNetwork
- the virtual network- Throws:
PlanItException
- thrown if a link/mode combination exists for which no cost parameters have been set
-
-