Package-level declarations

Types

Link copied to clipboard
interface AvailabilityIfc

Indicates whether an object is currently available to participate in supply-chain activity, e.g., a demand filler accepting new demands or a carrier accepting new shipments.

Link copied to clipboard

Read-only view of a demand backlog: total units waiting and the number of waiting demands.

Link copied to clipboard

Read-only view of statistics for a backlog queue: per-replication weighted statistics and across-replication summary statistics for number-in-queue, time-in-queue, and amount-backlogged.

Link copied to clipboard

Transports demands from a shipper (origin) to a receiver (destination). Implementations range from the trivial NoDelayDemandCarrier (immediate ship+deliver) to the network- aware NetworkDemandCarrierByTime (per-edge transport-time sampling with statistics).

Link copied to clipboard
abstract class DemandFillerAbstract @JvmOverloads constructor(parent: ModelElement, initialAvailability: Boolean = true, name: String? = null) : ModelElement, DemandFillerIfc

Base class for objects that implement DemandFillerIfc. Provides availability state, carrier/preparer plumbing, and per-replication initialization. Subclasses must implement the demand-handling abstract methods.

Link copied to clipboard

Default DemandFillerFinderIfc implementation backed by a customer-to-supplier map. Each DemandSenderIfc (customer) maps to at most one DemandFillerIfc (supplier); a supplier may serve many customers.

Link copied to clipboard
fun interface DemandFillerFinderIfc

Strategy for locating a DemandFillerIfc that can fill a given demand, used by OrderFillerAbstract when assigning fillers to the demands on an incoming order.

Link copied to clipboard

Objects that can fill demands. A successful receive moves the demand from SupplyChainModel.sent into SupplyChainModel.received; fillDemand then completes the fill.

Link copied to clipboard
data class DemandMessage @JvmOverloads constructor(val demandFiller: DemandFillerIfc, val timeStamp: Double, val canFillItemType: Boolean = false, val requestStatus: DemandStatusCode = DemandStatusCode.NoStatus, val requestFillAmount: Int = 0, val inventory: InventoryIfc? = null, val mayPartiallyFillDemands: Boolean = false, val mayBackLogDemands: Boolean = false) : DemandMessageIfc

Default implementation of DemandMessageIfc. Returned by DemandFillerIfc implementations from their negotiate path.

Link copied to clipboard

Information returned by a DemandFillerIfc in response to a negotiation request for a single demand. A filler that cannot negotiate returns null; otherwise it returns a DemandMessageIfc describing what would happen if the demand were sent at the current time.

Link copied to clipboard
fun interface DemandPreparerIfc

Strategy hook for any pre-shipment preparation a DemandFillerIfc needs to perform on a demand before handing it to a carrier.

Link copied to clipboard

Default rejection-handling listener that dispatches on the demand's SupplyChainModel.Demand.status when the demand reaches the rejected state. Each dispatch method has a default IllegalStateException-throwing body that subclasses can override.

Link copied to clipboard

Objects that send demand requests to a DemandFillerIfc.

Link copied to clipboard

Notified when a demand transitions between SupplyChainModel.DemandStates.

Link copied to clipboard
sealed class DemandStateId(val displayName: String)

Type-safe identifier for the lifecycle states of a SupplyChainModel.Demand. Each state in the demand state machine has exactly one DemandStateId singleton; the sealed-class hierarchy lets listener bodies use exhaustive when and referential identity (===) checks instead of stringly-typed comparison on displayName.

Link copied to clipboard

Status codes attached to a demand when it is rejected, negotiated, or otherwise routed through the demand-handling pipeline.

Link copied to clipboard

A DemandSenderIfc that represents external (outside-the-modeled- network) demand consumption. Network-level carriers (e.g. NetworkDemandCarrierByTime) may permit zero-delay delivery to implementers when no explicit transport time has been configured for the (filler, this) pair.

Link copied to clipboard

A DemandFillerIfc that represents an external (outside-the- modeled-network) source of supply with infinite stock and a lead time. Network-level carriers may permit zero-delay shipping from implementers when no explicit transport time has been configured for the (this, customer) pair.

Link copied to clipboard
interface InventoryIfc

Read-only view of an inventory's current quantities and backlog.

Link copied to clipboard

Read-only view of per-inventory statistics, exposing both within-replication weighted statistics and across-replication statistics for each tracked quantity.

Link copied to clipboard
class ItemType @JvmOverloads constructor(parent: ModelElement, name: String? = null, weight: Double = 1.0, cube: Double = 1.0, leadTime: RVariableIfc? = null) : ModelElement

Models a stock-keeping unit (SKU) within an inventory system. An ItemType is associated with a unit cost, a weight, a cube (length × width × height), and optionally a leadTime distribution used when this item type is stocked at a location with non-zero replenishment lead time.

Link copied to clipboard
class NoDemandFillerFoundException(message: String = "NoDemandFillerFoundException", cause: Throwable? = null) : RuntimeException

Thrown when no DemandFillerIfc is available to fill a given demand.

Link copied to clipboard
interface OrderCarrierIfc

Transports orders from a shipper (origin) to a receiver (destination). Mirrors DemandCarrierIfc for orders; same two-method shape and the same separation of what and whether.

Link copied to clipboard
fun interface OrderCreatorIfc

Strategy for creating orders from scratch. Used by OrderGenerator at each event firing. Implementations decide what item types and quantities go on the order.

Link copied to clipboard
abstract class OrderFillerAbstract @JvmOverloads constructor(parent: ModelElement, initialAvailability: Boolean = true, name: String? = null) : ModelElement, OrderFillerIfc

Base class for objects that implement OrderFillerIfc. Provides the order-receipt orchestration (availability gating → per-demand filler assignment → status determination → batched receipt) and leaves fill / canFillItemType / negotiate to subclasses.

Link copied to clipboard
fun interface OrderFillerFinderIfc

Strategy for locating an OrderFillerIfc that can fill a given order, used by OrderGenerator when sending generated orders.

Link copied to clipboard

Objects that can fill orders.

Link copied to clipboard
class OrderMessage(val orderFiller: OrderFillerIfc, val timeStamp: Double) : OrderMessageIfc

Default implementation of OrderMessageIfc. Built up by an OrderFillerIfc one demand at a time via add.

Link copied to clipboard
interface OrderMessageIfc

The order-level counterpart to DemandMessageIfc. Aggregates one DemandMessageIfc per demand on the negotiated order plus order-level metadata.

Link copied to clipboard

Objects that send orders to an OrderFillerIfc.

Link copied to clipboard

Notified when an order transitions between SupplyChainModel.OrderStates.

Link copied to clipboard
sealed class OrderStateId(val displayName: String)

Type-safe identifier for the lifecycle states of a SupplyChainModel.Order. Each state in the order state machine has exactly one OrderStateId singleton; sealed-class hierarchy lets listener bodies use exhaustive when and referential identity (===) checks instead of stringly-typed comparison on displayName.

Link copied to clipboard

Status codes attached to an order during negotiation and routing.

Link copied to clipboard

A DemandFillerIfc that drives received demands through its own internal flow and does not need an external caller (the storage-facility clone router, for example) to invoke DemandFillerIfc.fillDemand on demands sent to it.

Link copied to clipboard
open class SupplyChainModel(parent: ModelElement, name: String? = null) : ProcessModel

A model element that hosts a supply-chain submodel. Acts as the umbrella within which Demands and Orders live, mirroring how ProcessModel hosts Entity. Multiple SupplyChainModel instances can coexist within a single KSL ksl.simulation.Model.