Update of /cvsroot/ebxmlms/ebxmlms/src/hk/hku/cecid/phoenix/message/handler
In directory sc8-pr-cvs1:/tmp/cvs-serv15054/src/hk/hku/cecid/phoenix/message/handler
Modified Files:
Constants.java DiagTool.java MessageServer.java
MessageServiceHandler.java Request.java
SignalMessageGenerator.java
Log Message:
Add two constructor on EbxmlMessage which can load
the message from file and InputStream. The logic is re-use the one
from MessageServer.
The logic on MessageServer is changed to allow support on DataSource
as input to load the message.
Change AttachmentDataSource to support DataSource as input.
Change class to reduce warning on making JavaDoc
Reduce the import * and unused import for some of the classes.
format some of the codes.
Index: Constants.java
===================================================================
RCS file: /cvsroot/ebxmlms/ebxmlms/src/hk/hku/cecid/phoenix/message/handler/Constants.java,v
retrieving revision 1.33
retrieving revision 1.34
diff -C2 -d -r1.33 -r1.34
*** Constants.java 21 Nov 2003 02:00:04 -0000 1.33
--- Constants.java 9 Dec 2003 08:59:04 -0000 1.34
***************
*** 290,296 ****
"MSH/Persistent/Database/MaximumIdle";
-
- // Settings for SSL
-
/**
* Service name reserved for services described in ebXML Message Service
--- 290,293 ----
***************
*** 331,334 ****
--- 328,332 ----
public static final String ACTION_STATUS_RESPONSE = "StatusResponse";
+ // Settings for SSL
/**
Path to access the classname of customized Hostname verifier for
***************
*** 1053,1057 ****
* object in <code>MessageServiceHandler</code>.
*/
! static final String SERIALIZABLE_OBJECT =
"application/octet-stream";
--- 1051,1055 ----
* object in <code>MessageServiceHandler</code>.
*/
! public static final String SERIALIZABLE_OBJECT =
"application/octet-stream";
Index: DiagTool.java
===================================================================
RCS file: /cvsroot/ebxmlms/ebxmlms/src/hk/hku/cecid/phoenix/message/handler/DiagTool.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** DiagTool.java 9 Apr 2003 07:47:40 -0000 1.13
--- DiagTool.java 9 Dec 2003 08:59:06 -0000 1.14
***************
*** 600,604 ****
* Show a warning message.
*
! * @param errorMessage Message to be displayed.
*/
public static void showWarning(String warnMessage) {
--- 600,604 ----
* Show a warning message.
*
! * @param warnMessage Message to be displayed.
*/
public static void showWarning(String warnMessage) {
Index: MessageServer.java
===================================================================
RCS file: /cvsroot/ebxmlms/ebxmlms/src/hk/hku/cecid/phoenix/message/handler/MessageServer.java,v
retrieving revision 1.141
retrieving revision 1.142
diff -C2 -d -r1.141 -r1.142
*** MessageServer.java 31 Jul 2003 06:57:48 -0000 1.141
--- MessageServer.java 9 Dec 2003 08:59:07 -0000 1.142
***************
*** 1,81 ****
/*
! * Copyright(c) 2002 Center for E-Commerce Infrastructure Development, The
! * University of Hong Kong (HKU). All Rights Reserved.
*
! * This software is licensed under the Academic Free License Version 1.0
*
! * Academic Free License
! * Version 1.0
*
! * This Academic Free License applies to any software and associated
[...7097 lines suppressed...]
+ * Gets the finalState attribute of the MessageServer class
+ *
+ * @param state Description of the Parameter
+ * @return The finalState value
+ */
public static boolean isFinalState(int state) {
return state == STATE_ACKNOWLEDGED || state == STATE_SENT_FAILED ||
! state == STATE_DELETED || state == STATE_SENT ||
! state == STATE_SENT_RECEIVED ||
! state == STATE_RECEIVED_ACKNOWLEDGED || state == STATE_RECEIVED;
}
+ /**
+ * Gets the delivered attribute of the MessageServer class
+ *
+ * @param sequenceNumber Description of the Parameter
+ * @return The delivered value
+ */
public static boolean isDelivered(int sequenceNumber) {
return sequenceNumber <= FIRST_MESSAGE_DELIVERED;
Index: MessageServiceHandler.java
===================================================================
RCS file: /cvsroot/ebxmlms/ebxmlms/src/hk/hku/cecid/phoenix/message/handler/MessageServiceHandler.java,v
retrieving revision 1.178
retrieving revision 1.179
diff -C2 -d -r1.178 -r1.179
*** MessageServiceHandler.java 21 Nov 2003 02:00:05 -0000 1.178
--- MessageServiceHandler.java 9 Dec 2003 08:59:07 -0000 1.179
***************
*** 959,963 ****
* </ul>
*
! * @exception MessageServiceHandlerException
*/
public MessageServiceHandler() throws MessageServiceHandlerException {
--- 959,963 ----
* </ul>
*
! * @throws MessageServiceHandlerException
*/
public MessageServiceHandler() throws MessageServiceHandlerException {
***************
*** 1262,1267 ****
* of this servlet is written.
*
! * @exception ServletException
! * @exception IOException
*/
public void doGet(HttpServletRequest request, HttpServletResponse response)
--- 1262,1267 ----
* of this servlet is written.
*
! * @throws ServletException
! * @throws IOException
*/
public void doGet(HttpServletRequest request, HttpServletResponse response)
***************
*** 1286,1291 ****
* @param response HTTP servlet response object to which the response
* of this servlet is written.
! * @exception ServletException
! * @exception IOException
*/
public void doPost(HttpServletRequest request,
--- 1286,1291 ----
* @param response HTTP servlet response object to which the response
* of this servlet is written.
! * @throws ServletException
! * @throws IOException
*/
public void doPost(HttpServletRequest request,
***************
*** 1495,1499 ****
* @return Connection to the message service handler.
*
! * @exception MessageServiceHandlerException
*/
public MessageServiceHandlerConnection
--- 1495,1499 ----
* @return Connection to the message service handler.
*
! * @throws MessageServiceHandlerException
*/
public MessageServiceHandlerConnection
***************
*** 1621,1625 ****
* @return true if unregistration succeeded, false otherwise
*
! * @exception MessageServiceHandlerException
*/
public boolean unregister(MessageServiceHandlerConfig mshConfig)
--- 1621,1625 ----
* @return true if unregistration succeeded, false otherwise
*
! * @throws MessageServiceHandlerException
*/
public boolean unregister(MessageServiceHandlerConfig mshConfig)
***************
*** 2316,2320 ****
* otherwise.
*
! * @exception MessageServiceHandlerException
*/
private boolean verify(EbxmlMessage ebxmlMessage)
--- 2316,2320 ----
* otherwise.
*
! * @throws MessageServiceHandlerException
*/
private boolean verify(EbxmlMessage ebxmlMessage)
***************
*** 2472,2476 ****
* @return Acknowledgement message.
*
! * @exception MessageServiceHandlerException
*/
private EbxmlMessage generateAcknowledgment(EbxmlMessage
--- 2472,2476 ----
* @return Acknowledgement message.
*
! * @throws MessageServiceHandlerException
*/
private EbxmlMessage generateAcknowledgment(EbxmlMessage
***************
*** 2530,2534 ****
* @return Status response message.
*
! * @exception MessageServiceHandlerException
*/
private EbxmlMessage generateStatusResponseMessage
--- 2530,2534 ----
* @return Status response message.
*
! * @throws MessageServiceHandlerException
*/
private EbxmlMessage generateStatusResponseMessage
***************
*** 2579,2583 ****
* @return ebXML message containing error code.
*
! * @exception MessageServiceHandlerException
*/
private EbxmlMessage generateErrorMessage(EbxmlMessage ebxmlMessage,
--- 2579,2583 ----
* @return ebXML message containing error code.
*
! * @throws MessageServiceHandlerException
*/
private EbxmlMessage generateErrorMessage(EbxmlMessage ebxmlMessage,
***************
*** 2601,2605 ****
* @return ebXML message containing error code.
*
! * @exception MessageServiceHandlerException
*/
private EbxmlMessage generateErrorMessage(EbxmlMessage ebxmlMessage,
--- 2601,2605 ----
* @return ebXML message containing error code.
*
! * @throws MessageServiceHandlerException
*/
private EbxmlMessage generateErrorMessage(EbxmlMessage ebxmlMessage,
***************
*** 2637,2641 ****
* @return Pong message in response of the incoming ping message.
*
! * @exception MessageServiceHandlerException
*/
private EbxmlMessage generatePongMessage(EbxmlMessage pingMessage)
--- 2637,2641 ----
* @return Pong message in response of the incoming ping message.
*
! * @throws MessageServiceHandlerException
*/
private EbxmlMessage generatePongMessage(EbxmlMessage pingMessage)
***************
*** 2675,2679 ****
* store; false otherwise.
*
! * @exception MessageServiceHandlerException
* @throws MessageServerException
*/
--- 2675,2679 ----
* store; false otherwise.
*
! * @throws MessageServiceHandlerException
* @throws MessageServerException
*/
Index: Request.java
===================================================================
RCS file: /cvsroot/ebxmlms/ebxmlms/src/hk/hku/cecid/phoenix/message/handler/Request.java,v
retrieving revision 1.74
retrieving revision 1.75
diff -C2 -d -r1.74 -r1.75
*** Request.java 31 Jul 2003 06:57:48 -0000 1.74
--- Request.java 9 Dec 2003 08:59:08 -0000 1.75
***************
*** 1,81 ****
/*
! * Copyright(c) 2002 Center for E-Commerce Infrastructure Development, The
! * University of Hong Kong (HKU). All Rights Reserved.
*
! * This software is licensed under the Academic Free License Version 1.0
*
! * Academic Free License
! * Version 1.0
*
! * This Academic Free License applies to any software and associated
[...4098 lines suppressed...]
try {
***************
*** 2146,2153 ****
transformer.transform(source, result);
return writer.toString();
! }
! catch (Exception e) {
throw new RequestException(e.getMessage());
}
}
}
--- 2379,2386 ----
transformer.transform(source, result);
return writer.toString();
! } catch (Exception e) {
throw new RequestException(e.getMessage());
}
}
}
+
Index: SignalMessageGenerator.java
===================================================================
RCS file: /cvsroot/ebxmlms/ebxmlms/src/hk/hku/cecid/phoenix/message/handler/SignalMessageGenerator.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** SignalMessageGenerator.java 21 Nov 2003 02:00:05 -0000 1.1
--- SignalMessageGenerator.java 9 Dec 2003 08:59:09 -0000 1.2
***************
*** 104,108 ****
* above.
*
! * @exception SOAPException
*/
private static EbxmlMessage generateResponseMessage(
--- 104,108 ----
* above.
*
! * @throws SOAPException
*/
private static EbxmlMessage generateResponseMessage(
***************
*** 141,145 ****
* @return Acknowledgement message.
*
! * @exception SOAPException
*/
public static EbxmlMessage generateAcknowledgment(
--- 141,145 ----
* @return Acknowledgement message.
*
! * @throws SOAPException
*/
public static EbxmlMessage generateAcknowledgment(
***************
*** 190,199 ****
*
* @param ackRequestedMessage Acknowledgement request message.
- * @param refToMessageId MessageId of the message to which the
- * acknowledgement response should be referred.
*
* @return Acknowledgement message.
*
! * @exception SOAPException
*/
public static EbxmlMessage generateAcknowledgment(
--- 190,197 ----
*
* @param ackRequestedMessage Acknowledgement request message.
*
* @return Acknowledgement message.
*
! * @throws SOAPException
*/
public static EbxmlMessage generateAcknowledgment(
***************
*** 213,217 ****
* @return Status response message.
*
! * @exception SOAPException
*/
public static EbxmlMessage generateStatusResponseMessage(
--- 211,215 ----
* @return Status response message.
*
! * @throws SOAPException
*/
public static EbxmlMessage generateStatusResponseMessage(
***************
*** 251,255 ****
* @return ebXML message containing error code.
*
! * @exception SOAPException
*/
public static EbxmlMessage generateErrorMessage(EbxmlMessage ebxmlMessage,
--- 249,253 ----
* @return ebXML message containing error code.
*
! * @throws SOAPException
*/
public static EbxmlMessage generateErrorMessage(EbxmlMessage ebxmlMessage,
***************
*** 273,277 ****
* @return Pong message in response of the incoming ping message.
*
! * @exception SOAPException
*/
public static EbxmlMessage generatePongMessage(EbxmlMessage pingMessage)
--- 271,275 ----
* @return Pong message in response of the incoming ping message.
*
! * @throws SOAPException
*/
public static EbxmlMessage generatePongMessage(EbxmlMessage pingMessage)
|