Package org.medcare.igtl.network
Class GenericServerResponseHandler
java.lang.Object
org.medcare.igtl.network.MessageHandler
org.medcare.igtl.network.GenericServerResponseHandler
-
Field Summary
Fields inherited from class org.medcare.igtl.network.MessageHandler
capabilityList, serverThread
-
Constructor Summary
ConstructorDescriptionGenericServerResponseHandler
(Header header, byte[] body, ServerThread serverThread, IOpenIgtPacketListener server) -
Method Summary
Modifier and TypeMethodDescriptionvoid
manageError
(String message, Exception exception, int errorCode) manage error this method must be adapted for each useboolean
Perform the request job this method must be adapted for each useMethods inherited from class org.medcare.igtl.network.MessageHandler
getBody, getCapability, getHeader, performRequest, setBody, setHeader
-
Field Details
-
openIGTMessage
-
-
Constructor Details
-
GenericServerResponseHandler
public GenericServerResponseHandler(Header header, byte[] body, ServerThread serverThread, IOpenIgtPacketListener server)
-
-
Method Details
-
perform
Description copied from class:MessageHandler
Perform the request job this method must be adapted for each use- Specified by:
perform
in classMessageHandler
- Parameters:
messageType
- The messageType- Returns:
- True if response job performed successfully
- Throws:
Exception
- CrcException will be thrown at crc check during message unpacking Other exceptions can be thrown
-
manageError
Description copied from class:MessageHandler
manage error this method must be adapted for each use- Specified by:
manageError
in classMessageHandler
- Parameters:
message
- The message for error datailexception
- The exception for errorerrorCode
- The error Code
-