DemandLoad

A bundle of demands all destined for the same DemandSenderIfc. Used by transportlayer load-builders and load carriers. Created only via SupplyChainModel.createDemandLoad.

See sc.transportlayer.DemandLoad

Properties

Link copied to clipboard
Link copied to clipboard

Read-only view of the demands on this load, in insertion order.

Link copied to clipboard

The shared destination (the sender of the demands), or null if empty.

Link copied to clipboard

True iff no demands have been added.

Link copied to clipboard
val size: Int

Number of demands on this load.

Link copied to clipboard

Functions

Link copied to clipboard

Add demand to this load. The demand must have a non-null SupplyChainModel.Demand.demandSender; all demands on the same load must share the same sender.

Link copied to clipboard
fun deliver()

Transitions every demand on the load to DELIVERED.

Link copied to clipboard
fun ship()

Transitions every demand on the load to SHIPPED.