Class EventOutMFTimeWrapper
java.lang.Object
vrml.eai.field.BaseField
vrml.eai.field.EventOut
vrml.eai.field.EventOutMField
vrml.eai.field.EventOutMFTime
org.web3d.vrml.scripting.external.neteai.EventOutMFTimeWrapper
Client side implementation of EventOutMFTimeWrapper field.
EventOut fields which are used by the vrmlEventChanged
broadcast system report only their stored value.
EventOut fields produced by Node.getEventOut report only
the 'live' value of the field.
-
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionEventOutMFTimeWrapper(int fieldID, FieldAndNodeRequestProcessor requestProcessor) EventOutMFTimeWrapper(int fieldID, FieldAndNodeRequestProcessor requestProcessor, DataInputStream source) -
Method Summary
Modifier and TypeMethodDescriptionvoidAdd a listener for changes in this eventOut.booleanTwo fields are equal if they point to the same actual node and fielddoubleget1Value(int index) Get a particular time value in the given eventOut array.intThe underlying field IDintgetType()The type of the underlying field.Get the user data that is associated with this eventOutdouble[]getValue()Get the value of the array of times.voidgetValue(double[] values) Write the value of the event out to the given array.inthashCode()In order to make the event queueing system easier, and since an equals method is required by the specification, compute the hashcode based on the field number and underlying node hashcode.voidloadFieldValue(DataInputStream input) voidRemove a listener for changes in this eventOut.voidsetUserData(Object data) Associate user data with this event.intsize()Get the size of the underlying data array.voidwriteFieldValue(DataOutputStream output)
-
Constructor Details
-
EventOutMFTimeWrapper
- Parameters:
fieldID- The network field IDrequestProcessor- Handler for field services
-
EventOutMFTimeWrapper
public EventOutMFTimeWrapper(int fieldID, FieldAndNodeRequestProcessor requestProcessor, DataInputStream source) throws IOException - Parameters:
fieldID- The network field IDrequestProcessor- Handler for field servicessource- The stream to read field values from- Throws:
IOException
-
-
Method Details
-
equals
-
getFieldID
public int getFieldID()The underlying field ID- See Also:
-
getValue
public double[] getValue()Description copied from class:EventOutMFTimeGet the value of the array of times.- Specified by:
getValuein classEventOutMFTime- Returns:
- * @see vrml.eai.field.EventOutMFFloat#getValue()
-
getValue
public void getValue(double[] values) Description copied from class:EventOutMFTimeWrite the value of the event out to the given array.- Specified by:
getValuein classEventOutMFTime- Parameters:
values- * @see vrml.eai.field.EventOutMFFloat#getValue(float[])
-
get1Value
Description copied from class:EventOutMFTimeGet a particular time value in the given eventOut array.If the index is out of the bounds of the current array of data values an ArrayIndexOutOfBoundsException will be generated.
- Specified by:
get1Valuein classEventOutMFTime- Parameters:
index- The position to get the time value- Returns:
- * @see vrml.eai.field.EventOutMFFloat#get1Value(int)
- Throws:
ArrayIndexOutOfBoundsException- The index was outside of the bounds of the current array.
-
hashCode
-
size
public int size()Description copied from class:EventOutMFieldGet the size of the underlying data array.- Specified by:
sizein classEventOutMField- Returns:
- * @see vrml.eai.field.EventOutMField#size()
-
addVrmlEventListener
Description copied from class:EventOutAdd a listener for changes in this eventOut.- Specified by:
addVrmlEventListenerin classEventOut- Parameters:
l- The listener to add- See Also:
-
removeVrmlEventListener
Description copied from class:EventOutRemove a listener for changes in this eventOut.- Specified by:
removeVrmlEventListenerin classEventOut- Parameters:
l- The listener to remove- See Also:
-
setUserData
Description copied from class:EventOutAssociate user data with this event. Whenever an event is generated on this eventOut. this data will be available with the Event through its getData method.- Specified by:
setUserDatain classEventOut- Parameters:
data- The data to associate with this eventOut instance- See Also:
-
getUserData
Description copied from class:EventOutGet the user data that is associated with this eventOut- Specified by:
getUserDatain classEventOut- Returns:
- * @see vrml.eai.field.EventOut#getUserData()
-
loadFieldValue
- Throws:
IOException- * @see org.web3d.vrml.scripting.external.neteai.EventWrapper#loadFieldValue(java.io.DataInputStream)
-
writeFieldValue
- Throws:
IOException- * @see org.web3d.vrml.scripting.external.neteai.EventWrapper#writeFieldValue(java.io.DataOutputStream)
-
getType
int getType()The type of the underlying field. Method name chosen to coincide with vrml.eai.field.BaseField.- Returns:
- the type of the underlying field
-