vcProductCreator

vcProductCreator acts as a feeder and creates one or more types of products for use in a Process Modeling.

Inherits: vcFlow

How it Works

The product creator is a behaviour that creates product instances (vcProduct) to a container during simulation according to specified configuration. Different Rules of what and when to create can be configured independently using the feed modes, but only one feed mode can be active at a time. The feed mode to use is defined by the FeedMode property.

Note: The product creation can be blocked or delayed if the connected container doesn’t have free capacity.

Inherits from vcBehaviour, vcFlow

Type constant: VC_PRODUCTCREATOR

Properties

Name Type Access Description
ApplyProductTypeOrigin Boolean RW

Defines whether origin offset defined in the Product Type is taking into account or not. See vcProductType.OriginFrame

BatchFeed vcProductCreatorBatchMode R Gets the configuration for batch feed mode.
DistributionFeed vcProductCreatorDistributionMode R Gets the configuration for distribution feed mode.
FeedMode Enumeration RW Defines the mode for feeding products. That is, when and what type of product to create during a simulation.

See Feed Mode Constants for more information.

PartPooling

Boolean

RW

Turns on/off the reuse of components made by the creator, thereby improving simulation performance.

If True, dynamic components removed during simulation are recirculated to make new components, thereby reducing memory allocation.

Note: Be careful when recirculating components that were modified during simulation, for example a change in node material.

SingleFeed

vcProductCreatorSingleMode

R Gets the configuration for single feed mode.

 

TableFeed vcProductCreatorTableMode R Gets the configuration for table feed mode.

Events

Name Parameters Description
OnProductCreated vcProduct product

Triggered when a new product instance has been created by this creator.

Examples

Example. Create products variants

from vcScript import *
  
#creating product properties that not supported in UI
# 1. create a distribution property to a product type
# 2. during simulation, take a sample of the distribution
# 3. use that sample value to a Real type property in the Product instance.