public class ValueChangedEvent
extends java.util.EventObject
Modifier and Type | Field and Description |
---|---|
ValueObjectInterface |
theValue
The value that is being passed by this event.
|
Constructor and Description |
---|
ValueChangedEvent(DataSource source)
This is the default constructor.
|
ValueChangedEvent(java.lang.Object source,
ValueObjectInterface newValue)
This constructor takes an Object as the source (which should be
a DataSource object in most cases) and a new value.
|
ValueChangedEvent(java.lang.Object source,
ValueObjectInterface newValue,
ValueUpdateResponseListener valueUpdateResponseListener)
This constructor takes an Object as the source (which should be
a DataSource object in most cases) and a new value.
|
Modifier and Type | Method and Description |
---|---|
byte[] |
getBinaryValue()
This will return the current value of the ValueObject as a byte array.
|
boolean |
getBoolValue()
This will return the current value as a boolean.
|
byte |
getByteValue()
This will return the current value as a byte.
|
java.awt.Color |
getColor()
This will return the current color for the data.
|
java.util.Date |
getDate()
This will return the date that the value was created.
|
double |
getDoubleValue()
This will return the current value as a double.
|
float |
getFloatValue()
This will return the current value as a float.
|
int |
getIntValue()
This will return the current value as a int.
|
Connector |
getLastConnector() |
long |
getLongValue()
This will return the current value as a long.
|
double |
getNumericValue()
This will return the current value as a double.
|
java.lang.Object |
getObjectValue()
This will return the current value.
|
int |
getQuality()
This will return the quality of the reading.
|
short |
getShortValue()
This will return the current value as a short.
|
java.lang.String |
getStringValue()
This will return the current value as a String.
|
long |
getTimeMillis()
This will return the number of milliseconds since Jan 1st 1970.
|
char |
getType()
This will return the type of data that the current value was last set by.
|
ValueObjectInterface |
getValueObject()
This will return the current value.
|
ValueUpdateResponseListener |
getValueUpdateResponseListener()
Returns the update response listener.
|
void |
setLastConnector(Connector lastConnector) |
void |
setValueUpdateResponseListener(ValueUpdateResponseListener valueUpdateResponseListener)
Sets the update response listener.
|
java.lang.String |
toString()
Returns a String representation of this ValueChangedEvent.
|
public ValueObjectInterface theValue
public ValueChangedEvent(DataSource source)
source
- the data source that triggered the eventpublic ValueChangedEvent(java.lang.Object source, ValueObjectInterface newValue)
source
- the source that triggered the eventnewValue
- the new valuepublic ValueChangedEvent(java.lang.Object source, ValueObjectInterface newValue, ValueUpdateResponseListener valueUpdateResponseListener)
source
- the source that triggered the eventnewValue
- the new valuevalueUpdateResponseListener
- if non-null, this should be called after the value is updated.public byte[] getBinaryValue()
public boolean getBoolValue()
public byte getByteValue()
public java.awt.Color getColor()
ValueObject.getColor()
public java.util.Date getDate()
public double getDoubleValue()
public float getFloatValue()
public int getIntValue()
public Connector getLastConnector()
public long getLongValue()
public double getNumericValue() throws java.lang.NumberFormatException
java.lang.NumberFormatException
public java.lang.Object getObjectValue()
public int getQuality()
#setQuality
public short getShortValue()
public java.lang.String getStringValue()
public long getTimeMillis()
public char getType()
ValueObject.getType()
public ValueObjectInterface getValueObject()
public ValueUpdateResponseListener getValueUpdateResponseListener()
public void setLastConnector(Connector lastConnector)
lastConnector
- The lastConnector to set.public void setValueUpdateResponseListener(ValueUpdateResponseListener valueUpdateResponseListener)
valueUpdateResponseListener
- the update response listenerpublic java.lang.String toString()
toString
in class java.util.EventObject
Copyright © 1999-2025 ErgoTech Systems, Inc. All Rights Reserved.