Package com.millistream.www
Interface Callback
public interface Callback
This interface provides the call back function used in
Mdf.consume().- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumDefines the various connection states -
Method Summary
Modifier and TypeMethodDescriptionvoidconsumeData(Mdf mdf) This function is automatically called by theconsume()function ofMdfclass if thesetConsumeDataCallback()method have been used to register a consumeData callback.voidstatusChange(Callback.StatusCode status, String host, String ip) This function is automatically called by theconsume()function ofMdfclass when the current connection status changes and if thesetStatusChangeCallback()method have been used to register a statusChange callback.
-
Method Details
-
consumeData
This function is automatically called by theconsume()function ofMdfclass if thesetConsumeDataCallback()method have been used to register a consumeData callback.- Parameters:
mdf-Mdfobject that receives data from the mdf server
-
statusChange
This function is automatically called by theconsume()function ofMdfclass when the current connection status changes and if thesetStatusChangeCallback()method have been used to register a statusChange callback.- Parameters:
status- the new connection statushost- the server host name we are connecting / trying to connect to. ForRCV_HB_RESthe string contains the nanoseconds epoch timestamp of when the API received the heartbeat.ip- the ip address of the host if available (can be null if not translated yet). ForRCV_HB_RESthe string contains the nanoseconds epoch timestamp of when the server sent the heartbeat.
-