⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 moinfo.java

📁 采用JAVA开发
💻 JAVA
字号:
package com.gctech.sms.msg;

import java.io.*;

/**
 * <p>Title: SMS</p>
 * <p>Description: </p>
 * <p>Copyright: Copyright (c) 2002</p>
 * <p>Company: gctech</p>
 * @author 王红宝
 * @version 1.0
 */

/** 存储用户上行信息的数据结构. */
public class MOInfo implements Serializable {

	public int status = 0;

	/** 网关 */
	public int gateway = 0;
	/** 服务代码 */
	public String serviceNo = null;
	/** 发送终端 */
	public String srcPhoneNo = null;
	/** 接收终端 去掉服务代码 */
	public String destTermId = null;
	/**业务类型*/
	public String ServiceID = null;
	/** 短信内容 */
	public String content = null;
	/**信息标识*/
	public String strMsgID = "";

	public int MsgLevel = 1;
	/**信息格式*/
	public int MsgFormat = 15;
	/**是否为状态报告*/
	public int IsReply = 0;
	/**信息长度*/
	public int MsgLen = 0;
	/**地区*/
	public String strZone = "";
	//状态报告对应MT的MSGID2
	public String linkMtMsgId = "";
	//add start ,by liyi ,to fit cmpp3.0
	public String linkID = "";
	public int srcTerminalType = 0;
	//add end
	public MOInfo() {

	}

	/**
	 * 构造函数
	 * @param gateway 网关
	 * @param serviceNo 服务代码
	 * @param srcPhoneNo 源代码
	 * @param content 短信内容
	 */
	public MOInfo(
		int gateway,
		String serviceNo,
		String srcPhoneNo,
		String content,
		int MsgLevel,
		int MsgFormat,
		int IsReply,
		String strLinkID) {
		this.gateway = gateway;
		this.serviceNo = serviceNo;
		this.srcPhoneNo = srcPhoneNo;
		this.content = content;
		this.MsgLevel = MsgLevel;
		this.MsgFormat = MsgFormat;
		this.IsReply = IsReply;
	}
	/**
	 * 构造函数针对CMPP3.0
	 * @param gateway 网关
	 * @param serviceNo 服务代码
	 * @param srcPhoneNo 源代码
	 * @param content 短信内容
	 */
	public MOInfo(
		int gateway,
		String serviceNo,
		String srcPhoneNo,
		String content,
		int MsgLevel,
		int MsgFormat,
		int IsReply,
		String strLinkID,
		int srcTerminalType,
		String linkID) {
		this.gateway = gateway;
		this.serviceNo = serviceNo;
		this.srcPhoneNo = srcPhoneNo;
		this.content = content;
		this.MsgLevel = MsgLevel;
		this.MsgFormat = MsgFormat;
		this.IsReply = IsReply;
		this.srcTerminalType = srcTerminalType;
		this.linkID = linkID;
	}

	public void setGateway(int gateway) {
		this.gateway = gateway;
	}

	public int getGateway() {
		return this.gateway;
	}

	public void setServiceNo(String serviceNo) {
		this.serviceNo = serviceNo;
	}

	public String getServiceNo() {
		return this.serviceNo;
	}

	public void setPhoneNo(String srcPhoneNo) {
		this.srcPhoneNo = srcPhoneNo;
	}

	public String getPhoneNo() {
		return this.srcPhoneNo;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public String getContent() {
		return this.content;
	}

	public int getMsgLen() {

		return this.MsgLen;

	}

	public void setMsgLen(int MsgLen) {
		this.MsgLen = MsgLen;
	}

	public int getMsgLevel() {

		return MsgLevel;

	}

	public void setMsgLevel(int MsgLevel) {
		this.MsgLevel = MsgLevel;
	}

	public String getZone() {
		return strZone;
	}

	public void setZone(String strZone) {
		this.strZone = strZone;
	}

	public int getIsReply() {
		return this.IsReply;
	}

	public void setIsReply(int IsReply) {
		this.IsReply = IsReply;
	}

	public int getMsgFormat() {
		return this.MsgFormat;
	}

	public void setMsgFormat(int MsgFormat) {
		this.MsgFormat = MsgFormat;
	}

	public String getMsgID() {
		return strMsgID;
	}

	public void setMsgID(int MsgFormat) {
		this.MsgFormat = MsgFormat;
	}

	private void writeObject(ObjectOutputStream oos) throws IOException {
		oos.defaultWriteObject();
	}
	private void readObject(ObjectInputStream ois) throws ClassNotFoundException, IOException {
		ois.defaultReadObject();
	}
	public String toString() {
		return "MsgID["
			+ this.strMsgID
			+ "] MsgLevel["
			+ this.MsgLevel
			+ "] Gateway["
			+ this.gateway
			+ "] ServiceNo["
			+ this.serviceNo
			+ "] MsgFormat["
			+ this.MsgFormat
			+ "] MsgContent["
			+ this.content
			+ "] SrcTermID["
			+ this.srcPhoneNo
			+ "] DestTermID["
			+ this.destTermId
			+ "]";
	}
	/**
	 * @return
	 */
	public String getLinkID() {
		return linkID;
	}

	/**
	 * @return
	 */
	public int getSrcTerminalType() {
		return srcTerminalType;
	}

	/**
	 * @param string
	 */
	public void setLinkID(String string) {
		linkID = string;
	}

	/**
	 * @param i
	 */
	public void setSrcTerminalType(int i) {
		srcTerminalType = i;
	}

}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -