Interface ProtocolManager<O extends OutgoingMessage,E extends LiveScoutEntityBase>
-
- All Known Implementing Classes:
LiveFeedProtocolManager
public interface ProtocolManager<O extends OutgoingMessage,E extends LiveScoutEntityBase>
Represents a class used to manage access to the underlyingProtocol
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
close()
Closes the underlyingProtocol
and components associated with it.void
open()
Opens the underlyingProtocol
and components associated with itvoid
reconnect()
Reconnects the underlying feedvoid
sendMessage(String data)
Forwards the passed data as-is to the underlying protocol which sends it to the server.void
setListener(ProtocolManagerListener<E> listener)
Sets theProtocolManagerListener
instance used to observe the currentProtocolManager
-
-
-
Method Detail
-
close
void close()
Closes the underlyingProtocol
and components associated with it.
-
open
void open()
Opens the underlyingProtocol
and components associated with it
-
reconnect
void reconnect()
Reconnects the underlying feed
-
sendMessage
void sendMessage(String data)
Forwards the passed data as-is to the underlying protocol which sends it to the server. There is no rate-limiting.- Parameters:
data
- - outgoing data
-
setListener
void setListener(ProtocolManagerListener<E> listener)
Sets theProtocolManagerListener
instance used to observe the currentProtocolManager
- Parameters:
listener
- theProtocolManagerListener
instance used to observe the currentProtocolManager
-
-