我发现很难通过jSMPP发送WAP推送。
我需要知道如何为jSMPP指定UDH值,以及如何指定我正在发送二进制消息。
有没有人有一些示例代码摘录?我已经尝试了很长一段时间都没有成功,我也找不到任何使用谷歌的例子……
发布于 2011-06-03 10:18:27
要使用sms发送wap,需要将esmclass设置为64,并将datacoding设置为245。您可以尝试使用下面的示例。
String messageId = session.submitShortMessage("CMT", TypeOfNumber.INTERNATIONAL, NumberingPlanIndicator.UNKNOWN, "55662", TypeOfNumber.ALPHANUMERIC, NumberingPlanIndicator.UNKNOWN, "your_phone_number", new ESMClass(64), (byte)0, (byte)1, timeFormatter.format(new Date()), null, new RegisteredDelivery(SMSCDeliveryReceipt.DEFAULT), (byte)0, new GeneralDataCoding(245), (byte)0, HexUtil.convertHexStringToBytes("0605040B8423F025060803AE81EAAF82B48401056A0045C 60D036578616D706C652E636F6D0007010377656C636F6D6520746F207761702073697465000101") ); https://stackoverflow.com/questions/5138885
复制相似问题