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

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

?? bodypart.java

?? 手機郵箱撒的方式方式方式的
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
/*MujMail - Simple mail client for J2MECopyright (C) 2008 David Hauzar <david.hauzar.mujmail@gmail.com>Copyright (C) 2006 Nguyen Son Tung <n.sontung@gmail.com>Copyright (C) 2006 Martin Stefan <martin.stefan@centrum.cz>This program is free software; you can redistribute it and/or modifyit under the terms of the GNU General Public License as published bythe Free Software Foundation; either version 2 of the License, or(at your option) any later version.This program is distributed in the hope that it will be useful,but WITHOUT ANY WARRANTY; without even the implied warranty ofMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See theGNU General Public License for more details.You should have received a copy of the GNU General Public Licensealong with this program; if not, write to the Free SoftwareFoundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */package mujmail;import mujmail.util.Functions;import java.io.DataInputStream;import java.io.DataOutputStream;import javax.microedition.lcdui.StringItem;/** * Represents an email part - email body or email attachment. Contains * information about the body part such as it's name, encoding etc. * Does not store the content of the body part but contains object * of type {@link ContentStorage} that stores the content. *  * This object is stored persistently in RMS database. It's loading * and saving does object of instance {@link MessageHeader} that * contains this body part. *  */public class BodyPart {        public static final String SOURCE_FILE = "BodyPart";        //body state constants    public static final byte BS_COMPLETE = 0;    public static final byte BS_PARTIAL = 1;    public static final byte BS_EMPTY = 2;        //types of MIME body part, separated only to these types    //for more detailed information of the type use bodyPart.getBpExtension	    public static final byte TYPE_TEXT = 2;    public static final byte TYPE_HTML = 4;    public static final byte TYPE_MULTIMEDIA = 8; //image audio video    public static final byte TYPE_APPLICATION = 16;//pdf, postscrips...	    public static final byte TYPE_OTHER = 32;//model, xworld,... - will never be supported by mujmail        // bodypart transfer encodings    public static final byte ENC_NORMAL = 0; //7bit    public static final byte ENC_BASE64 = 1;    public static final byte ENC_QUOTEDPRINTABLE = 2;    public static final byte ENC_8BIT = 4;	//8bit 		    //bodypart text charset    public static final byte CH_NORMAL = 0; //ASCII and whatever    public static final byte CH_ISO88591 = 1;    public static final byte CH_ISO88592 = 2;    public static final byte CH_WIN1250 = 3;    public static final byte CH_UTF8 = 4;    public static final byte CH_USASCII = 5;        private boolean convertedContentMode = false;    public MessageHeader getMessageHeader() {        return messageHeader;    }    public void setOrder(    byte order) {        this.order = order;    }    public byte getOrder() {        return order;    }        /**     * Manages displaying body part in the sendmail form.     */    public class SendMailDisplayer {        public SendMailDisplayer() {};                /** The number of items of attachment info in sendmail form.         * Used when removing attachments from the form. */        public static final int numberOfItemsInForm = 2;                /** The string item in which is displayed the size of the file in Sendmail form */        private final StringItem siSize = new StringItem(Lang.get(Lang.SM_FILE_SIZE), "");                /**         * Displays this body part in the sendmail form.         * @param sendmail the form to which add information about this body part         */        public void addAttachmentToForm(SendMail sendmail) {            // the name of the attachment            StringItem siFileNameAttached = new                     StringItem(Lang.get(Lang.SM_ATTACHMENT), getHeader().getName() + "\n");            sendmail.append(siFileNameAttached);            // the size of the attachment            sendmail.append(siSize);            updateSize();        }                        /**         * Updates size of the body part in the SendMail form.         */        public void updateSize() {            System.out.println("Updating size");            siSize.setText(Functions.formatNumberByteorKByte(getSize()) + "\n");        }    }        /**     * Returns true if the body state is at least partial - this means complete     * or partial.     * @return true if the body state is at least partial - this means complete     * or partial     */    public boolean atLeastPartial() {        return (bodyState == BS_COMPLETE || bodyState == BS_PARTIAL) ? true : false;    }        /**     * Contains information about the storage of this body part.     */    private ContentStorage contentStorage;        /**     * Contains information about the storage of this body part.     */    private ContentStorage convertedContentStorage;            /** Contains information about body part header */    private Header bodyPartHeader;            private byte order = 0; //the order of the bodypart in a mail body    /** Manages displaying this bodypart in sendmail form */    private SendMailDisplayer sendMailDisplayer = new SendMailDisplayer();        /**     * The message header of message to which this body part belongs.     */    private MessageHeader messageHeader;        /**     * Gets the box in which this body part is.     * @return     */    public PersistentBox getBox() {return getMessageHeader().getBox();}        /**     * Gets the object which manages displaying this bodypart on the SendMail form.     * @return the object which manages displaying this bodypart on the SendMail      *  form.     */    public SendMailDisplayer getSendMailDisplayer() { return sendMailDisplayer; }        /**         * Indicates whether body part is partially downloaded or decoded.         * BS_COMPLETE         * BS_PARTIAL         * BS_EMPTY         */        private byte bodyState = BS_COMPLETE;                public byte getBodyState() { return bodyState; }        public void setBodyState(byte bodyState) { this.bodyState = bodyState; }    /**     * Creates new instance of body part belonging to header header with the     * order and body part header the same as body part copy and with the     * same storage type as body part copy.     * Note that it just creates the storage of the same type as BodyPart copy     * but does not copy it's content!!     * @param header     * @param copy     * @param copyMode copy mode of the content of the body part     */    public BodyPart(MessageHeader header, BodyPart copy, ContentStorage.CopyingModes copyMode) {        this.messageHeader = header;        contentStorage =             copy.getStorage().copy(this, copyMode);                bodyPartHeader = new Header(copy.bodyPartHeader);                        order = copy.order;    //don't copy bodyState. because InProtocol may be downloading the old incomplete bodyPart,     //and by marking this new bodyPart also incomplete bodyPart by default would confuse InProtocol    //and make it unable to replace the old one with the new one    }        /**     * Creates new body part which belongs to the message with header header.     * The storage type will be determined according to mujMail settings.     * @param header the header of the message to which this body part belongs     */    public BodyPart(MessageHeader header) {        // TODO: determine the storage type according to mujMail settings        this.messageHeader = header;        bodyPartHeader = new Header();        contentStorage = new RMSStorage(this);    }    //#ifdef MUJMAIL_FS    /**     * Creates new instance of body part with content stored in FSStorage.     * @param messageHeader     * @param fileURL     * @param fileName     * @param name     * @param size     */    public BodyPart(MessageHeader messageHeader, String fileURL, String fileName, String name, long size) {        this.messageHeader = messageHeader;        contentStorage = new FSStorage(this, size, fileURL);                bodyPartHeader = new Header();        bodyPartHeader.setName(name);    }    //#endif    //create this when sending a mail    public BodyPart(MessageHeader messageHeader, String name) {        this.messageHeader = messageHeader;                // TODO: create storage according to global settings of mujMail        contentStorage = new RMSStorage(this);        bodyPartHeader = new Header();        bodyPartHeader.setName(name);    }    //we can call this constructor after a complete parsing and storing a content    public BodyPart(MessageHeader messageHeader, String nm, byte encoding, byte type, byte charset) {        this.messageHeader = messageHeader;        // TODO: create storage according to global settings of mujMail        contentStorage = new RMSStorage(this);                bodyPartHeader = new Header(nm, type, charset, encoding);    }        public BodyPart(MessageHeader messageHeader, Header bodyPartHeader) {        this.messageHeader = messageHeader;        // TODO: create storage according to global settings of mujMail        contentStorage = ContentStorage.createStorageInstance(this, ContentStorage.StorageTypes.RMS_STORAGE.getStorageTypeNumber());        this.bodyPartHeader = bodyPartHeader;    }        /**     * Gets viewing mode of this bodypart determined from the content and header     * of the bodypart.     * @return the viewing mode of this bodypart determined from it's content and header     */    public MailForm.BPViewingModes.ViewingModesWithActions getAutoViewingMode() {        if ( getHeader().getBodyPartContentType() == BodyPart.TYPE_HTML ) {         	return MailForm.BPViewingModes.HTML;        } else if ( getHeader().getBodyPartContentType() == BodyPart.TYPE_TEXT) {            return MailForm.BPViewingModes.PLAIN_TEXT;        }        if (getHeader().getBodyPartContentType() == BodyPart.TYPE_MULTIMEDIA &&                (getHeader().getName().toLowerCase().endsWith("jpg") ||                 getHeader().getName().toLowerCase().endsWith("jpeg") ||                 getHeader().getName().toLowerCase().endsWith("gif") || 

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久精品欧美一区二区三区麻豆| 99re成人在线| 欧美xxxx老人做受| 久久99最新地址| 久久精品日韩一区二区三区| 成人免费毛片app| 亚洲精品国产一区二区三区四区在线 | 欧美日韩一区在线| 丝袜美腿亚洲色图| 欧美成人一区二区| 成人三级伦理片| 亚洲综合图片区| 日韩一区二区精品葵司在线| 国产一区二区三区在线看麻豆| 国产精品全国免费观看高清 | 国产欧美视频在线观看| kk眼镜猥琐国模调教系列一区二区| 亚洲欧美二区三区| 91精品国产综合久久福利| 国产精品一二三四区| 亚洲视频综合在线| 日韩丝袜情趣美女图片| 国产成人综合网| 亚洲成人在线网站| 久久麻豆一区二区| 欧美色图一区二区三区| 国产毛片精品一区| 亚洲成人免费电影| 国产精品天干天干在线综合| 91麻豆精品国产91久久久久 | 国内精品不卡在线| 亚洲综合图片区| 国产精品色哟哟| 欧美日韩国产精品自在自线| 国内精品免费在线观看| 亚洲一区二区欧美| 国产女人18毛片水真多成人如厕 | 日韩avvvv在线播放| 中文字幕在线免费不卡| 精品乱人伦小说| 欧美日免费三级在线| 国产成人免费xxxxxxxx| 肉丝袜脚交视频一区二区| 中文字幕不卡在线播放| 欧美一区二区三区四区在线观看| 成人精品免费视频| 国产美女一区二区三区| 日韩不卡在线观看日韩不卡视频| 亚洲欧洲精品成人久久奇米网| 欧美va在线播放| 欧美日韩一本到| av电影天堂一区二区在线观看| 理论片日本一区| 天天影视涩香欲综合网| 一二三区精品福利视频| 一区二区中文视频| 中文成人综合网| 久久男人中文字幕资源站| 日韩一区二区在线观看视频播放| 91日韩精品一区| 9色porny自拍视频一区二区| 国产精品一区二区三区99| 玖玖九九国产精品| 老色鬼精品视频在线观看播放| 性欧美大战久久久久久久久| 亚洲国产精品自拍| 亚洲最新视频在线观看| 亚洲欧美激情插| 一区二区欧美视频| 一区二区三区在线视频观看58| 国产精品免费看片| 国产精品久久毛片a| 久久精品综合网| 久久影视一区二区| 久久精品亚洲精品国产欧美kt∨| 精品国产人成亚洲区| 精品粉嫩超白一线天av| 久久久久一区二区三区四区| 欧美成人vps| 国产欧美日韩视频在线观看| 国产欧美日本一区二区三区| 中文字幕欧美日韩一区| 欧美国产日韩亚洲一区| 亚洲欧美综合在线精品| 亚洲天堂免费看| 亚洲激情网站免费观看| 亚洲成人自拍一区| 日本成人超碰在线观看| 激情小说欧美图片| 成人av在线影院| 欧美写真视频网站| 欧美精品v日韩精品v韩国精品v| 欧美日韩大陆一区二区| 日韩一区二区在线看| www国产亚洲精品久久麻豆| 欧美激情一区在线| 亚洲综合区在线| 日韩av中文字幕一区二区三区| 久久99精品国产.久久久久| 成人久久视频在线观看| 欧美亚洲综合在线| 这里只有精品电影| 国产欧美日韩另类一区| 亚洲综合成人网| 麻豆视频一区二区| 成人激情小说网站| 欧美日韩日日摸| 精品国产乱子伦一区| 亚洲欧美日韩在线| 免费在线观看成人| 99re成人精品视频| 91麻豆精品国产自产在线观看一区| 久久亚洲二区三区| 亚洲自拍都市欧美小说| 精品夜夜嗨av一区二区三区| 成人中文字幕在线| 欧美四级电影网| 国产女人18毛片水真多成人如厕| 亚洲综合无码一区二区| 国产一区二区网址| 精品污污网站免费看| 国产亚洲成年网址在线观看| 一区二区三区波多野结衣在线观看| 强制捆绑调教一区二区| av成人老司机| 精品区一区二区| 亚洲制服欧美中文字幕中文字幕| 经典三级视频一区| 欧美日韩精品三区| 国产精品情趣视频| 蜜芽一区二区三区| 欧美在线播放高清精品| 欧美国产国产综合| 久久国产生活片100| 欧美视频你懂的| 综合色天天鬼久久鬼色| 国产精品亚洲午夜一区二区三区 | 激情成人午夜视频| 91国内精品野花午夜精品| 精品99一区二区| 日本欧美肥老太交大片| 在线中文字幕一区| 国产精品乱码一区二区三区软件| 蜜臀久久久99精品久久久久久| 色婷婷亚洲一区二区三区| 国产欧美日韩中文久久| 久久国产人妖系列| 678五月天丁香亚洲综合网| 亚洲女同一区二区| 成人精品一区二区三区四区| 久久亚洲综合色一区二区三区| 丝袜美腿亚洲一区二区图片| 欧美影院午夜播放| 亚洲激情欧美激情| 99视频在线精品| 亚洲欧美一区二区在线观看| 国产精品1024| 国产欧美日韩麻豆91| 国产高清视频一区| 久久久久久夜精品精品免费| 国产在线视频一区二区三区| 日韩精品在线网站| 麻豆极品一区二区三区| 欧美一区二区三区白人| 舔着乳尖日韩一区| 欧美一区二区三区影视| 七七婷婷婷婷精品国产| 日韩一区二区精品葵司在线| 麻豆91精品视频| 精品少妇一区二区| 极品少妇一区二区三区精品视频 | 欧美哺乳videos| 久久99国产精品麻豆| 精品国产乱码久久久久久闺蜜| 久久国产精品99久久久久久老狼| 91精品婷婷国产综合久久性色 | 国产a区久久久| 亚洲欧洲三级电影| 色婷婷av久久久久久久| 亚洲sss视频在线视频| 欧美一区二区福利在线| 精品一区二区三区在线播放视频| 精品91自产拍在线观看一区| 高清国产一区二区| 亚洲人亚洲人成电影网站色| 在线观看视频欧美| 日韩精品三区四区| 久久久久久亚洲综合影院红桃| 国产成人综合在线观看| 国产精品美女视频| 91成人国产精品| 青青草成人在线观看| 久久精品综合网| 色综合天天综合| 奇米888四色在线精品| 中文字幕不卡在线| 欧美日韩国产高清一区二区| 国内偷窥港台综合视频在线播放| 亚洲欧洲国产日本综合| 制服丝袜在线91|