The Logica smpp API has the following problems:
1. Support for long messages. Add the setmediamessagedata method to the submitsm. Java class.
/*** Added by zcg 2012-01-18 * process long messages ** @ Param buffer * @ throws wronglengthofstringexception */Public void setinclumessagedata (bytebuffer buffer) throws wronglengthofstringexception {try {This. invalid Message. setdata (buffer);} catch (exception e) {If (E instanceof wronglengthofstringexception) {Throw (wronglengthofstringexception) e);} Throw new wronglengthofstringexception ();} setsmlength (short) This. invalid Message. getlength ());}
2. Support binding the specified port on the SME client and modifying the tcpipconnection. Java open method
// start, modified by zcg 2012-10-08 if(localAddress != null && localPort != 0){ SocketAddress bindPoint = new InetSocketAddress(localAddress, localPort); socket = new Socket(); socket.setReuseAddress(true); socket.bind(bindPoint); SocketAddress endPoint = new InetSocketAddress(address, port); socket.connect(endPoint, timeout); }else{ socket = new Socket(address, port); }// end, modified by zcg 2012-10-08