cmppcancelmessage.java
来自「华为CNGP.CMPP.SGIP.CMPP源代码。」· Java 代码 · 共 33 行
JAVA
33 行
package com.huawei.insa2.comm.cmpp.message;
import com.huawei.insa2.comm.cmpp.CMPPConstant;
import com.huawei.insa2.util.TypeConvert;
public class CMPPCancelMessage extends CMPPMessage {
public CMPPCancelMessage(byte msg_Id[]) throws IllegalArgumentException {
if (msg_Id.length > 8) {
throw new IllegalArgumentException(CMPPConstant.CONNECT_INPUT_ERROR
+ ":msg_Id" + CMPPConstant.STRING_LENGTH_GREAT + "8");
} else {
int len = 20;
super.buf = new byte[len];
TypeConvert.int2byte(len, super.buf, 0);
TypeConvert.int2byte(7, super.buf, 4);
System.arraycopy(msg_Id, 0, super.buf, 12, msg_Id.length);
return;
}
}
public String toString() {
String tmpStr = "CMPP_Cancel: ";
tmpStr = tmpStr + "Sequence_Id=" + getSequenceId();
return tmpStr;
}
public int getCommandId() {
return CMPPConstant.Cancel_Command_Id;
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?