📄 msgbatchreplace.java
字号:
/**
*
*/
package com.aceway.vas.sjcraw.cbgp201.crm.rwm;
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;
/**
* @标题: 华为彩铃平台接口规范
* @说明:
* @版权: Copyright(c) 2007
* @公司: 北京汉铭信通科技有限公司
* @部门: 增值业务部
* @作者: 武达
* @Jun 5, 2007
*/
public class MsgBatchReplace extends Msg {
private static int operCode = MsgInfo.CRBT_BATCH_REPLACE;
private static int lenBody = MsgInfo.LEN_CRBT_BATCH_REPLACE;
/*
AccountID 21 String 用户手机号码
OldRingID 12 String 被替换的铃音ID,编码格式同RingID
NewRingID 12 String 要替换的铃音ID,编码格式同RingID
*/
private String accountId;
private String oldRingId;
private String newRingId;
public MsgBatchReplace(String seqNo, String linkId, String accountId, String oldRingId, String newRingId){
super.setCommandLength(lenBody);
super.setMsgHead(operCode, "0", seqNo, linkId);
this.accountId = DataFormat.makeString(accountId, 21);
this.oldRingId = DataFormat.makeString(oldRingId, 12);
this.newRingId = DataFormat.makeString(newRingId, 12);
ByteBuffer buff = ByteBuffer.allocate(lenBody);
buff.put(this.accountId.getBytes());
buff.put(this.oldRingId.getBytes());
buff.put(this.newRingId.getBytes());
buff.flip();
super.setMsgBody(buff.array());
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -