public class Signal extends Object implements Collectible, ModelInstanceAware, EntityWithId
Constructor and Description |
---|
Signal(long id,
ModelInstance modelInstance,
Value value,
String sourceDescription)
Creates new instance.
|
Signal(ModelInstance modelInstance,
Value value,
String sourceDescription)
Creates new instance.
|
Modifier and Type | Method and Description |
---|---|
void |
collect()
Removes itself from the process.
|
Signal |
createCopy(ModelInstance targetModelInstance)
Returns deep copy.
|
void |
finishCopy(com.whitestein.lsps.engine.state.xml.Copiable source,
CopyHelper helper)
Copy references.
|
long |
getId()
Returns the id.
|
ModelInstance |
getModelInstance()
Returns the model instance.
|
Collection<Collectible> |
getReferences()
Returns collection of all referenced collectible objects.
|
String |
getSourceDescription()
Gets the description of the signals source.
|
Value |
getValue()
Returns the value.
|
boolean |
isConsumed()
Returns true if consumed.
|
boolean |
isInserted()
Returns true if inserted.
|
boolean |
isPersistent()
Returns true if this object cannot be collected.
|
void |
rebind(ModelInstance modelInstance)
Re-bind to the provided model instance.
|
void |
setConsumed(boolean consumed)
Sets consumed.
|
void |
setInserted(boolean inserted)
Sets inserted.
|
void |
setSourceDescription(String description) |
SSignal |
toSerializable(SModelInstance smi,
MarshallerConfig config)
Creates a serializable object.
|
String |
toString() |
public Signal(ModelInstance modelInstance, Value value, String sourceDescription)
modelInstance
- value
- sourceDescription
- the description of the signals sourceNullPointerException
- if modelInstance
or value
is nullpublic Signal(long id, ModelInstance modelInstance, Value value, String sourceDescription)
id
- modelInstance
- value
- sourceDescription
- the description of the signals sourceNullPointerException
- if modelInstance
or value
is nullpublic SSignal toSerializable(SModelInstance smi, MarshallerConfig config)
smi
- config
- public long getId()
EntityWithId
getId
in interface EntityWithId
public Value getValue()
public ModelInstance getModelInstance()
ModelInstanceAware
getModelInstance
in interface ModelInstanceAware
public void rebind(ModelInstance modelInstance)
ModelInstanceAware
rebind
in interface ModelInstanceAware
public boolean isConsumed()
public void setConsumed(boolean consumed)
consumed
- public boolean isInserted()
public void setInserted(boolean inserted)
inserted
- public String getSourceDescription()
public void setSourceDescription(String description)
description
- the description of the sourcegetSourceDescription()
public boolean isPersistent()
Collectible
isPersistent
in interface Collectible
public Collection<Collectible> getReferences()
Collectible
getReferences
in interface Collectible
public void collect()
Collectible
collect
in interface Collectible
public Signal createCopy(ModelInstance targetModelInstance)
targetModelInstance
- public void finishCopy(com.whitestein.lsps.engine.state.xml.Copiable source, CopyHelper helper)
Copyright © 2007-2020 Whitestein Technologies. All Rights Reserved.