public class ProxyValueListener extends java.lang.Object implements ValueListener
Red (pdf) |
Red (pdf) |
Constructor and Description |
---|
ProxyValueListener(TokenPublisher tokenPublisher)
Initialize the instance with the given token publisher
and enable its listener.
|
Modifier and Type | Method and Description |
---|---|
TokenPublisher |
getTokenPublisher()
Return TokenPublisher that would be used to publish
AttributeChange tokens produced by this actor on value change.
|
boolean |
isEnabled()
Return the enabled flag of the listener.
|
void |
setEnabled(boolean enabled)
Set enabled flag of the listener.
|
void |
valueChanged(Settable settable)
Capture value changes of the settable and send them via the publisher to the remote model.
|
public ProxyValueListener(TokenPublisher tokenPublisher)
tokenPublisher
- the tokenPublisher used for sending value change events.public void valueChanged(Settable settable)
valueChanged
in interface ValueListener
settable
- The settable whose value changed.ValueListener.valueChanged(ptolemy.kernel.util.Settable)
public TokenPublisher getTokenPublisher()
public void setEnabled(boolean enabled)
enabled
- the enabled flag.isEnabled()
public boolean isEnabled()
setEnabled(boolean)