Replies: 1 comment
-
In Java, the lifetime is forever; Event objects passed to the callback are not reused (new objects are created for every event) and can be retained/used indefinitely by the callback function. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In Java, when a listener is called is there any limit on how long the data contained in and referred to by
NetworkTableEvent
is valid? For example, if my listener just saves a reference to akValueRemote
event on adouble[]
topic, shouldevent.valueData.value.getDoubleArray()
continue to return the value associated with that event even after all of the topic publishers/subscribers are closed and the listener is removed? Or does the listener need to copy the data it cares about before returning?Beta Was this translation helpful? Give feedback.
All reactions