Class VectorAssembler

  • All Implemented Interfaces:
    java.lang.Cloneable, Actor, Executable, FiringsRecordable, Initializable, TypedActor, Changeable, Debuggable, DebugListener, Derivable, Instantiable, ModelErrorHandler, MoMLExportable, Moveable, Nameable

    public class VectorAssembler
    extends Transformer

    On each firing, read exactly one token from each channel of the input port and assemble the tokens into a DoubleMatrixToken with one column. The DoubleMatrixToken is sent to the output port. If there is no input token at any channel of the input port, then prefire() will return false. Note that the elements in the vector are not copied.

    For sequential domains like SDF, the combination of a Commutator and domains.sdf.lib.DoubleToMatrix is equivalent to this actor. However, that combination will not work in CT, so we need this actor.

    Since:
    Ptolemy II 2.0
    Version:
    $Id$
    Author:
    Jie Liu, Elaine Cheong
    See Also:
    VectorDisassembler
    Pt.AcceptedRating:
    Yellow (celaine)
    Pt.ProposedRating:
    Yellow (celaine)