📄 msgconfirm.java
字号:
/**
*
*/
package com.aceway.vas.sjcraw.cbgp201.cum;
import java.nio.ByteBuffer;
import com.aceway.vas.sjcraw.cbgp201.Msg;
import com.aceway.vas.sjcraw.cbgp201.common.DataFormat;
import com.aceway.vas.sjcraw.cbgp201.common.MsgInfo;
/**
* @标题: 华为彩铃平台接口规范
* @说明: 6.2.9.3 处理结果确认操作
* @版权: Copyright(c) 2007
* @公司: 北京汉铭信通科技有限公司
* @部门: 增值业务部
* @作者: 武达
* @Jun 5, 2007
*/
public class MsgConfirm extends Msg {
/*
command_status 4 String 此域表示一个命令的成功与失败,如失败,指示引起失败的错误类型等信息
Description 40 String 处理结果的简单描述
*/
private static int operCode = MsgInfo.CRBT_COMFIRM;
private static int lenBody = MsgInfo.LEN_CRBT_CONFIRM;
private String commandStatus;
private String description;
public MsgConfirm(String seqNo, String linkId, String commandStatus, String description){
super.setCommandLength(lenBody);
super.setMsgHead(operCode, "0", seqNo, linkId);
this.commandStatus = DataFormat.makeString(commandStatus, 4);
this.description = DataFormat.makeString(description, 40);
ByteBuffer buff = ByteBuffer.allocate(lenBody);
buff.put(this.commandStatus.getBytes());
buff.put(this.description.getBytes());
buff.flip();
super.setMsgBody(buff.array());
}
public String getCommandStatus() {
return this.commandStatus.trim();
}
public String getDescription() {
return this.description.trim();
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -