📄 phsdeliverrep.java
字号:
package sms.PHS;/** * <p>Title: </p> * <p>Description: </p> * <p>Copyright: Copyright (c) 2004</p> * <p>Company: </p> * @author not attributable * @version 1.0 */public class PHSDeliverRep extends PHSResponse{ private static final int COMMAND_ID = 0x80000003; private static final int lenMessageBody = 14; private static final int lenMsgId = 10; private static final int lenResult = 4; private String msgId; private int result; public PHSDeliverRep(String Msg_Id, int Result) throws PHSException{ super(0x80000003); result = 0; setMsgId(Msg_Id); setResult(Result); } public PHSDeliverRep(int SequenceId, String Msg_Id, int Result) throws PHSException{ super(0x80000003, SequenceId); result = 0; setMsgId(Msg_Id); setResult(Result); } public void encodePacket(PHSIO cmppio) throws PHSException{ insertInteger(result); insertString(msgId); if(getLength() != 14){ throw new PHSException("encodePacket : invalid packet length !"); } else{ super.encodePacket(cmppio); return; } } public String getMsgId(){ return msgId; } public int getResult(){ return result; } public void setMsgId(String msgId){ this.msgId = msgId; } public void setResult(int result){ this.result = result; }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -