亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? outboundmessage.java

?? 發送短信 接收短信 多種接口com/net/modem 開發庫
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
// SMSLib for Java v3
// A Java API library for sending and receiving SMS via a GSM modem
// or other supported gateways.
// Web Site: http://www.smslib.org
//
// Copyright (C) 2002-2009, Thanasis Delenikas, Athens/GREECE.
// SMSLib is distributed under the terms of the Apache License version 2.0
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package org.smslib;

import java.util.*;
import org.ajwcc.pduUtils.gsm3040.*;
import org.ajwcc.pduUtils.gsm3040.ie.*;

/**
 * Class representing an outbound sms message.
 */
public class OutboundMessage extends Message
{
	private static final long serialVersionUID = 6449191177648891554L;

	/**
	 * Enumeration representing the failure reasons of a failed outbound
	 * message.
	 */
	public enum FailureCauses
	{
		/**
		 * No error, everything OK.
		 */
		NO_ERROR,
		/**
		 * Bad destination number - fatal error.
		 */
		BAD_NUMBER,
		/**
		 * Bad message format - fatal error.
		 */
		BAD_FORMAT,
		/**
		 * Generic gateway failure - transient error, retry later.
		 */
		GATEWAY_FAILURE,
		/**
		 * No credit left - fatal error.
		 */
		NO_CREDIT,
		/**
		 * Authentication problem (pin, passwords, etc) - fatal error.
		 */
		GATEWAY_AUTH,
		/**
		 * Unable to route message - transient error.
		 */
		NO_ROUTE,
		/**
		 * Unknown generic problems encountered.
		 */
		UNKNOWN
	}

	/**
	 * Class representing the status of an outbound message.
	 */
	public enum MessageStatuses
	{
		/**
		 * A not-yet-sent outbound message.
		 */
		UNSENT,
		/**
		 * An already-sent outbound message.
		 */
		SENT,
		/**
		 * A sent-but-failed outbound message.
		 */
		FAILED
	}

	protected String recipient;

	private Date dispatchDate;

	private int validityPeriod;

	private boolean statusReport;

	private String from;

	private MessageStatuses messageStatus;

	private FailureCauses failureCause;

	private int retryCount;

	private int priority;

	private String refNo;

	/**
	 * Outbound message constructor. This parameterless constructor creates an
	 * empty outbound message.
	 * 
	 * @see #OutboundMessage(String, String)
	 */
	public OutboundMessage()
	{
		super(MessageTypes.OUTBOUND, null, null);
		setRecipient("");
		setValidityPeriod(-1);
		setStatusReport(false);
		setDCSMessageClass(MessageClasses.MSGCLASS_NONE);
		setFrom("");
		setDispatchDate(null);
		setDate(new Date());
		setEncoding(MessageEncodings.ENC7BIT);
		setMessageStatus(MessageStatuses.UNSENT);
		setFailureCause(FailureCauses.NO_ERROR);
		setPriority(0);
		setRefNo("");
		setGatewayId("*");
		setRetryCount(0);
	}

	/**
	 * Outbound message constructor.
	 * 
	 * @param myRecipient
	 *            The recipient of the message.
	 * @param text
	 *            The text of the message.
	 */
	public OutboundMessage(String myRecipient, String text)
	{
		super(MessageTypes.OUTBOUND, new Date(), text);
		setRecipient(myRecipient);
		setValidityPeriod(-1);
		setStatusReport(false);
		setDCSMessageClass(MessageClasses.MSGCLASS_NONE);
		setFrom("");
		setDispatchDate(null);
		setDate(new Date());
		setEncoding(MessageEncodings.ENC7BIT);
		setMessageStatus(MessageStatuses.UNSENT);
		setFailureCause(FailureCauses.NO_ERROR);
		setPriority(0);
		setRefNo("");
		setGatewayId("*");
		setRetryCount(0);
	}

	/**
	 * Returns the recipient of this outbound message.
	 * 
	 * @return The recipient of the message.
	 * @see #setRecipient(String)
	 */
	public String getRecipient()
	{
		return this.recipient;
	}

	/**
	 * Set the recipient of the message.
	 * 
	 * @param myRecipient
	 *            The recipient of the message.
	 * @see #getRecipient()
	 */
	public void setRecipient(String myRecipient)
	{
		this.recipient = myRecipient;
	}

	/**
	 * Returns the dispatch date of this message. If the message has not been
	 * sent yet, the dispatch date is null.
	 * 
	 * @return The message dispatch date.
	 */
	public Date getDispatchDate()
	{
		if (this.dispatchDate != null) return new java.util.Date(this.dispatchDate.getTime());
		return null;
	}

	public void setDispatchDate(Date myDispatchDate)
	{
		this.dispatchDate = myDispatchDate;
	}

	/**
	 * Returns true if this message is to be sent out as a flash SMS. Otherwise,
	 * it returns false.
	 * 
	 * @return True for a Flash message.
	 * @see #setFlashSms(boolean)
	 */
	public boolean getFlashSms()
	{
		if (getDCSMessageClass() == MessageClasses.MSGCLASS_FLASH) return true;
		return false;
	}

	/**
	 * Set the flash message indication. Set this to true for this message to be
	 * sent as a flash message. Flash messages appear directly on the handset,
	 * so use this feature with care, because it may be a bit annoying.
	 * Furthermore, keep in mind that flash messaging is not supported on all
	 * phones.
	 * <p>
	 * The default is non-flash (false).
	 * 
	 * @param flashSms
	 *            True for a flash sms.
	 */
	public void setFlashSms(boolean flashSms)
	{
		if (flashSms) setDCSMessageClass(MessageClasses.MSGCLASS_FLASH);
		else setDCSMessageClass(MessageClasses.MSGCLASS_NONE);
	}

	/**
	 * Returns true if a status/delivery report will be asked for this message.
	 * 
	 * @return True if a status report will be generated.
	 */
	public boolean getStatusReport()
	{
		return this.statusReport;
	}

	/**
	 * Sets the status report request. If you set it to true, a status report
	 * message will be generated, otherwise no status report message will be
	 * generated.
	 * <p>
	 * The default is (false).
	 * 
	 * @param myStatusReport
	 *            The status report request status.
	 */
	public void setStatusReport(boolean myStatusReport)
	{
		this.statusReport = myStatusReport;
	}

	/**
	 * Returns the message validity period (in hours).
	 * 
	 * @return The message validity period.
	 * @see #setValidityPeriod(int)
	 */
	public int getValidityPeriod()
	{
		return this.validityPeriod;
	}

	/**
	 * Sets the message validity period.
	 * 
	 * @param myValidityPeriod
	 *            The message validity period in hours.
	 * @see #getValidityPeriod()
	 */
	public void setValidityPeriod(int myValidityPeriod)
	{
		this.validityPeriod = myValidityPeriod;
	}

	/**
	 * Receives the custom originator string. Set it to empty string to leave
	 * the default behavior.
	 * 
	 * @return The custom originator string.
	 * @see #setFrom(String)
	 */
	public String getFrom()
	{
		return this.from;
	}

	/**
	 * Sets the custom originator string. Some gateways allow you to define a
	 * custom string as the originator. When the message arrives at the
	 * recipient, the latter will not see your number but this string.
	 * <p>
	 * Note that this functionality is not supported on GSM modems / phones. It
	 * is supported on most bulk sms operators.
	 * 
	 * @param myFrom
	 *            The custom originator string.
	 * @see #getFrom()
	 */
	public void setFrom(String myFrom)
	{
		this.from = myFrom;
	}

	/**
	 * Returns the message status.
	 * 
	 * @return The message status.
	 * @see MessageStatuses
	 */
	public MessageStatuses getMessageStatus()
	{
		return this.messageStatus;
	}

	public void setMessageStatus(MessageStatuses myMessageStatus)
	{

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久久久久麻豆| 婷婷开心久久网| 国产成人免费视频精品含羞草妖精| 欧美日韩高清一区二区不卡| 三级在线观看一区二区| 欧美一区二区成人6969| 久久99精品国产麻豆婷婷洗澡| 久久在线观看免费| 成人激情图片网| 中文字幕欧美一区| 精品视频一区二区三区免费| 日韩精品电影一区亚洲| 久久先锋影音av鲁色资源| 成人免费毛片app| 亚洲国产精品自拍| 精品国产一区二区三区久久影院 | 青娱乐精品视频| 日韩免费高清av| 波波电影院一区二区三区| 亚洲综合在线视频| 精品久久人人做人人爰| a亚洲天堂av| 亚洲一区二区五区| 精品剧情v国产在线观看在线| 国产**成人网毛片九色 | 日韩欧美电影一区| 成人国产在线观看| 日韩福利视频导航| 国产精品免费网站在线观看| 欧美三级电影一区| 国产高清亚洲一区| 亚洲成av人片一区二区三区| 国产色91在线| 欧美日韩国产综合久久| 成人aaaa免费全部观看| 日韩国产精品大片| 日韩理论在线观看| 日韩精品影音先锋| 欧美性生活一区| 国产精品一二一区| 日本少妇一区二区| 亚洲欧美区自拍先锋| 久久看人人爽人人| 欧美美女喷水视频| 色综合天天做天天爱| 久久成人免费网站| 亚洲黄色片在线观看| 国产婷婷色一区二区三区在线| 欧美色视频一区| www.色精品| 国产在线国偷精品免费看| 亚洲成人av电影在线| 国产精品久久影院| 久久久久久久av麻豆果冻| 777久久久精品| 91国产免费看| 99国产精品久久久| 国产成a人无v码亚洲福利| 日韩不卡一区二区| 亚洲综合区在线| 亚洲人午夜精品天堂一二香蕉| 国产精品国产成人国产三级| 成人午夜在线播放| 久久女同性恋中文字幕| 99久久国产综合精品女不卡| 国产精品综合二区| 激情国产一区二区| 免费视频最近日韩| 蜜臀国产一区二区三区在线播放| 午夜精品在线看| 亚洲一区免费在线观看| 亚洲一卡二卡三卡四卡| 亚洲三级小视频| 亚洲精品视频一区| 亚洲天堂av老司机| 国产精品国产自产拍在线| 国产午夜精品一区二区三区视频| 欧美zozozo| 久久欧美一区二区| 久久久99精品免费观看| 欧美国产激情二区三区| 国产精品午夜免费| 亚洲欧洲另类国产综合| 国产精品国产馆在线真实露脸 | 午夜视频一区二区| 亚洲国产一区二区视频| 午夜精品久久久久久不卡8050| 亚洲国产精品久久久久婷婷884| 亚洲综合男人的天堂| 一区二区三区丝袜| 香蕉乱码成人久久天堂爱免费| 丝袜美腿一区二区三区| 久久精品72免费观看| 国内精品久久久久影院一蜜桃| 国产成人午夜精品影院观看视频| 国产91精品一区二区麻豆网站| fc2成人免费人成在线观看播放| bt欧美亚洲午夜电影天堂| 91电影在线观看| 欧美人伦禁忌dvd放荡欲情| 日韩精品最新网址| 欧美激情综合五月色丁香小说| 国产精品久久三| 亚洲成av人片| 久久国产精品99久久久久久老狼 | 久久亚洲综合色| 国产精品不卡一区二区三区| 亚洲第一主播视频| 国内外成人在线| 91色综合久久久久婷婷| 这里是久久伊人| 久久精品欧美日韩精品| 亚洲精品久久久蜜桃| 日本欧美肥老太交大片| 福利91精品一区二区三区| 91国偷自产一区二区三区观看 | 成人av网址在线观看| 91国产视频在线观看| 精品sm在线观看| 亚洲欧美激情一区二区| 久久精品久久99精品久久| va亚洲va日韩不卡在线观看| 在线播放视频一区| 国产精品国产三级国产aⅴ中文| 天天射综合影视| 不卡免费追剧大全电视剧网站| 欧美肥妇bbw| 中文字幕一区二区三| 麻豆精品一区二区| 在线看国产一区| 国产欧美日韩精品a在线观看| 午夜一区二区三区视频| 成人午夜又粗又硬又大| 欧美一区二区三区四区久久| 1024成人网色www| 国内成+人亚洲+欧美+综合在线 | 4438x亚洲最大成人网| 国产精品视频免费看| 久久国产精品免费| 欧美日韩国产三级| 一区二区三区四区高清精品免费观看| 国产麻豆日韩欧美久久| 欧美一区二区三区四区在线观看| 亚洲人成精品久久久久| 国产成人精品影视| 日韩久久久精品| 日本午夜精品视频在线观看| 在线观看中文字幕不卡| 国产精品久久久久久久久免费桃花 | 成人小视频免费在线观看| 日韩一级二级三级| 午夜精品久久久久久| 欧美在线影院一区二区| 亚洲人成在线观看一区二区| 成人中文字幕电影| 国产日韩三级在线| 精品亚洲成a人| 欧美xxx久久| 久久99精品国产.久久久久久| 在线不卡免费av| 五月天激情小说综合| 欧美无砖专区一中文字| 一区二区三区av电影| 色狠狠综合天天综合综合| 国产精品色在线观看| 成+人+亚洲+综合天堂| 中文字幕乱码久久午夜不卡| 国产一区二区成人久久免费影院| 久久久欧美精品sm网站 | 成人在线综合网| 国产精品三级在线观看| 成人午夜碰碰视频| 国产精品麻豆一区二区| eeuss鲁片一区二区三区在线观看| 国产午夜精品一区二区三区视频| 高清免费成人av| 国产精品久久久久久久久果冻传媒 | 欧美日韩专区在线| 亚洲国产成人av好男人在线观看| 欧美日韩免费不卡视频一区二区三区| 亚洲成人精品影院| 欧美一级二级三级乱码| 经典一区二区三区| 欧美经典三级视频一区二区三区| 成人精品在线视频观看| 亚洲精品视频免费看| 欧美区视频在线观看| 久久国产精品99精品国产| 中文字幕成人在线观看| 91丝袜高跟美女视频| 亚洲成人一区二区| 欧美精品一区二区三区很污很色的| 国产一区二区不卡在线| 国产精品久久福利| 欧美高清性hdvideosex| 国内不卡的二区三区中文字幕| 中文在线免费一区三区高中清不卡| 91丨九色丨蝌蚪富婆spa| 丝袜亚洲精品中文字幕一区| 久久久国产精品麻豆|