demos.atomicblocks
Class DEConst
java.lang.Object
modhelxs.abstractsemantics.NamedEntity
modhelxs.abstractsemantics.ObservableEntity
modhelxs.abstractsemantics.Block
modhelxs.state_management.ManagedBlock
modhelxs.state_management.TimedManagedBlock<java.lang.Double>
demos.atomicblocks.DEConst
- All Implemented Interfaces:
- Block, NamedEntity, ObservableEntity
public class DEConst
- extends TimedManagedBlock<java.lang.Double>
A DEConst is a Block for the Discrete Events MoC, which produces the same value on all
its Pins at each update. The produced value is set by the "value" property (default 0).
If the "period" property (default 0.0) is not null, the DEConst produces its value
periodically, starting at the time given by the "inittime" property (default 0.0).
If the "period" property is null, the value is produced only once at the time given
by the "inittime" property.
- Author:
- boulange
|
Field Summary |
private Parameter<java.lang.Double> |
period_
The period with which the value is produced. |
private Attribute<java.lang.Double> |
value_
The value produced by this DEConst. |
|
Constructor Summary |
DEConst(java.lang.String name,
java.lang.Object... properties)
|
|
Method Summary |
void |
doEndOfSnapshot()
The endOfSnapshot behavior of the block. |
void |
doSetup()
The setup behavior of the block. |
void |
doUpdate()
The update behavior of the block. |
| Methods inherited from class modhelxs.state_management.TimedManagedBlock |
doPreSetup, doReset, doStartOfSnapshot, emitObservationRequests, getNextObservationTime, getTimeOfRequest, hasObservationRequest, initNextObservationTime, nextObsTimeAttribute, observationClock, setNextObservationTime, tagDifference, tagProduct, tagQuotient, tagSum |
| Methods inherited from class modhelxs.state_management.ManagedBlock |
endOfSnapshot, endOfUpdate, initFromProperties, prep, reset, setup, startOfSnapshot, startOfUpdate, update, validate, wasUpdated, wrapup |
| Methods inherited from class modhelxs.abstractsemantics.Block |
connect, connectFromInterfaceBlock, connectFromModel, connectFromRegularBlock, getEngine, getInputPins, getMoC, getOutputPins, getParent, getSolver, sanityCheck, setParent |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
value_
private Attribute<java.lang.Double> value_
- The value produced by this DEConst.
period_
private Parameter<java.lang.Double> period_
- The period with which the value is produced.
DEConst
public DEConst(java.lang.String name,
java.lang.Object... properties)
doSetup
public void doSetup()
- Description copied from class:
ManagedBlock
- The setup behavior of the block.
- Specified by:
doSetup in class ManagedBlock
doUpdate
public void doUpdate()
- Description copied from class:
ManagedBlock
- The update behavior of the block.
- Specified by:
doUpdate in class ManagedBlock
doEndOfSnapshot
public void doEndOfSnapshot()
- Description copied from class:
ManagedBlock
- The endOfSnapshot behavior of the block.
- Specified by:
doEndOfSnapshot in class ManagedBlock