Package com.sshtools.synergy.ssh
Interface Service
- All Known Implementing Classes:
ConnectionProtocol
public interface Service
A service is a protocol that operates on top of the
TransportProtocol.-
Method Summary
Modifier and TypeMethodDescriptionInformation for logging purposes when an ignore message is sent during idle.intHow long does the service allow idle for?getName()The service namebooleanidle()The service has reached idle timeout secondsbooleanprocessMessage(byte[] msg) Process a transport message.voidstart()Start the service.voidstop()Stop the service
-
Method Details
-
processMessage
Process a transport message. When a message is received by theTransportProtocolthat is not a transport level message the message is passed onto the active service using this method. The service processes the message and returns a value to indicate whether the message was used.- Parameters:
msg-- Returns:
- true if the message was processed, otherwise false
- Throws:
IOExceptionSshException
-
start
Start the service.- Throws:
SshException
-
stop
void stop()Stop the service -
getIdleTimeoutSeconds
int getIdleTimeoutSeconds()How long does the service allow idle for?- Returns:
-
getName
String getName()The service name- Returns:
-
idle
boolean idle()The service has reached idle timeout seconds- Returns:
-
getIdleLog
String getIdleLog()Information for logging purposes when an ignore message is sent during idle.- Returns:
-