RecordUpdater
ptolemy.actor.lib.RecordUpdater

On each firing, read one token from each input port and assemble them into a RecordToken that contains the union of the original input record and each of the update ports. To use this class, instantiate it, and then add input ports (instances of TypedIOPort). This actor is polymorphic. The type constraint is that the output record contains all the labels in the input record plus the names of added input ports. The type of a field in the output is the same as the type of the added input port, if that field is updated by an added input port. If a field in the output is not updated by an input port, its type is the same as the corresponding field in the input record. For example, if the input record has type {item: string, value: int}, and this actor has two added input ports with name/type: value/double and id/int, then the output record will have type {item: string, value: double, id: int}

Author(s): Michael Shilman, Steve Neuendorffer
Version:$Id: RecordUpdater.java,v 1.40 2005/10/28 20:14:55 cxh Exp $
Pt.Proposed Rating:Red (yuhong)
Pt.Accepted Rating:Red (cxh)


output
The output port. Its type is constrained to be a RecordType.

input
The input port. Its type is constrained to be a RecordType.