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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? parameterlist.java

?? java Email you can use it to send email to others
?? JAVA
?? 第 1 頁(yè) / 共 2 頁(yè)
字號(hào):
/* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. * * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved. * * The contents of this file are subject to the terms of either the GNU * General Public License Version 2 only ("GPL") or the Common Development * and Distribution License("CDDL") (collectively, the "License").  You * may not use this file except in compliance with the License. You can obtain * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html * or glassfish/bootstrap/legal/LICENSE.txt.  See the License for the specific * language governing permissions and limitations under the License. * * When distributing the software, include this License Header Notice in each * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt. * Sun designates this particular file as subject to the "Classpath" exception * as provided by Sun in the GPL Version 2 section of the License file that * accompanied this code.  If applicable, add the following below the License * Header, with the fields enclosed by brackets [] replaced by your own * identifying information: "Portions Copyrighted [year] * [name of copyright owner]" * * Contributor(s): * * If you wish your version of this file to be governed by only the CDDL or * only the GPL Version 2, indicate your decision by adding "[Contributor] * elects to include this software in this distribution under the [CDDL or GPL * Version 2] license."  If you don't indicate a single choice of license, a * recipient has the option to distribute your version of this file under * either the CDDL, the GPL Version 2 or to extend the choice of license to * its licensees as provided above.  However, if you add GPL Version 2 code * and therefore, elected the GPL Version 2 license, then the option applies * only if the new code is made subject to such option by the copyright * holder. *//* * @(#)ParameterList.java	1.17 07/05/04 */package javax.mail.internet;import java.util.*;import java.io.*;/** * This class holds MIME parameters (attribute-value pairs). * The <code>mail.mime.encodeparameters</code> and * <code>mail.mime.decodeparameters</code> System properties * control whether encoded parameters, as specified by  * <a href="http://www.ietf.org/rfc/rfc2231.txt">RFC 2231</a>, * are supported.  By default, such encoded parameters are not * supported. <p> * * Also, in the current implementation, setting the System property * <code>mail.mime.decodeparameters.strict</code> to <code>"true"</code> * will cause a <code>ParseException</code> to be thrown for errors * detected while decoding encoded parameters.  By default, if any * decoding errors occur, the original (undecoded) string is used. * * @version 1.17, 07/05/04 * @author  John Mani * @author  Bill Shannon */public class ParameterList {    /**     * The map of name, value pairs.     * The value object is either a String, for unencoded     * values, or a Value object, for encoded values,     * or a MultiValue object, for multi-segment parameters.     *     * We use a LinkedHashMap so that parameters are (as much as     * possible) kept in the original order.  Note however that     * multi-segment parameters (see below) will appear in the     * position of the first seen segment and orphan segments     * will all move to the end.     */    private Map list = new LinkedHashMap();	// keep parameters in order    /**     * A set of names for multi-segment parameters that we     * haven't processed yet.  Normally such names are accumulated     * during the inital parse and processed at the end of the parse,     * but such names can also be set via the set method when the     * IMAP provider accumulates pre-parsed pieces of a parameter list.     * (A special call to the set method tells us when the IMAP provider     * is done setting parameters.)     *     * A multi-segment parameter is defined by RFC 2231.  For example,     * "title*0=part1; title*1=part2", which represents a parameter     * named "title" with value "part1part2".     *     * Note also that each segment of the value might or might not be     * encoded, indicated by a trailing "*" on the parameter name.     * If any segment is encoded, the first segment must be encoded.     * Only the first segment contains the charset and language     * information needed to decode any encoded segments.     *     * RFC 2231 introduces many possible failure modes, which we try     * to handle as gracefully as possible.  Generally, a failure to     * decode a parameter value causes the non-decoded parameter value     * to be used instead.  Missing segments cause all later segments     * to be appear as independent parameters with names that include     * the segment number.  For example, "title*0=part1; title*1=part2;     * title*3=part4" appears as two parameters named "title" and "title*3".     */    private Set multisegmentNames;    /**     * A map containing the segments for all not-yet-processed     * multi-segment parameters.  The map is indexed by "name*seg".     * The value object is either a String or a Value object.     * The Value object is not decoded during the initial parse     * because the segments may appear in any order and until the     * first segment appears we don't know what charset to use to     * decode any encoded segments.  The segments are decoded in     * order in the combineMultisegmentNames method.     */    private Map slist;    /**     * MWB 3BView: The name of the last parameter added to the map.     * Used for the AppleMail hack.     */    private String lastName = null;    private static boolean encodeParameters = false;    private static boolean decodeParameters = false;    private static boolean decodeParametersStrict = false;    private static boolean applehack = false;    static {	try {	    String s = System.getProperty("mail.mime.encodeparameters");	    // default to false	    encodeParameters = s != null && s.equalsIgnoreCase("true");	    s = System.getProperty("mail.mime.decodeparameters");	    // default to false	    decodeParameters = s != null && s.equalsIgnoreCase("true");	    s = System.getProperty("mail.mime.decodeparameters.strict");	    // default to false	    decodeParametersStrict = s != null && s.equalsIgnoreCase("true");	    s = System.getProperty("mail.mime.applefilenames");	    // default to false	    applehack = s != null && s.equalsIgnoreCase("true");	} catch (SecurityException sex) {	    // ignore it	}    }    /**     * A struct to hold an encoded value.     * A parsed encoded value is stored as both the     * decoded value and the original encoded value     * (so that toString will produce the same result).     * An encoded value that is set explicitly is stored     * as the original value and the encoded value, to     * ensure that get will return the same value that     * was set.     */    private static class Value {	String value;	String charset;	String encodedValue;    }    /**     * A struct for a multi-segment parameter.  Each entry in the     * List is either a String or a Value object.  When all the     * segments are present and combined in the combineMultisegmentNames     * method, the value field contains the combined and decoded value.     * Until then the value field contains an empty string as a placeholder.     */    private static class MultiValue extends ArrayList {	String value;    }    /**     * Map the LinkedHashMap's keySet iterator to an Enumeration.     */    private static class ParamEnum implements Enumeration {	private Iterator it;	ParamEnum(Iterator it) {	    this.it = it;	}	public boolean hasMoreElements() {	    return it.hasNext();	}	public Object nextElement() {	    return it.next();	}    }    /**     * No-arg Constructor.     */    public ParameterList() { 	// initialize other collections only if they'll be needed	if (decodeParameters) {	    multisegmentNames = new HashSet();	    slist = new HashMap();	}    }    /**     * Constructor that takes a parameter-list string. The String     * is parsed and the parameters are collected and stored internally.     * A ParseException is thrown if the parse fails.      * Note that an empty parameter-list string is valid and will be      * parsed into an empty ParameterList.     *     * @param	s	the parameter-list string.     * @exception	ParseException if the parse fails.     */    public ParameterList(String s) throws ParseException {	this();	HeaderTokenizer h = new HeaderTokenizer(s, HeaderTokenizer.MIME);	for (;;) {	    HeaderTokenizer.Token tk = h.next();	    int type = tk.getType();	    String name, value;	    if (type == HeaderTokenizer.Token.EOF) // done		break;	    if ((char)type == ';') {		// expect parameter name		tk = h.next();		// tolerate trailing semicolon, even though it violates the spec		if (tk.getType() == HeaderTokenizer.Token.EOF)		    break;		// parameter name must be a MIME Atom		if (tk.getType() != HeaderTokenizer.Token.ATOM)		    throw new ParseException("Expected parameter name, " +					    "got \"" + tk.getValue() + "\"");		name = tk.getValue().toLowerCase(Locale.ENGLISH);		// expect '='		tk = h.next();		if ((char)tk.getType() != '=')		    throw new ParseException("Expected '=', " +					    "got \"" + tk.getValue() + "\"");		// expect parameter value		tk = h.next();		type = tk.getType();		// parameter value must be a MIME Atom or Quoted String		if (type != HeaderTokenizer.Token.ATOM &&		    type != HeaderTokenizer.Token.QUOTEDSTRING)		    throw new ParseException("Expected parameter value, " +					    "got \"" + tk.getValue() + "\"");		value = tk.getValue();		lastName = name;		if (decodeParameters)		    putEncodedName(name, value);		else		    list.put(name, value);            } else {		// MWB 3BView new code to add in filenames generated by 		// AppleMail.		// Note - one space is assumed between name elements.		// This may not be correct but it shouldn't matter too much.		// Note: AppleMail encodes filenames with non-ascii characters 		// correctly, so we don't need to worry about the name* subkeys.		if (applehack && type == HeaderTokenizer.Token.ATOM &&			lastName != null &&			(lastName.equals("name") ||			 lastName.equals("filename"))) {		    // Add value to previous value		    String lastValue = (String)list.get(lastName);		    value = lastValue + " " + tk.getValue();		    list.put(lastName, value);                } else {		    throw new ParseException("Expected ';', " +					    "got \"" + tk.getValue() + "\"");		}	    }        }	if (decodeParameters) {	    /*	     * After parsing all the parameters, combine all the	     * multi-segment parameter values together.	     */	    combineMultisegmentNames(false);	}    }    /**     * If the name is an encoded or multi-segment name (or both)     * handle it appropriately, storing the appropriate String     * or Value object.  Multi-segment names are stored in the     * main parameter list as an emtpy string as a placeholder,     * replaced later in combineMultisegmentNames with a MultiValue     * object.  This causes all pieces of the multi-segment parameter     * to appear in the position of the first seen segment of the     * parameter.     */    private void putEncodedName(String name, String value)				throws ParseException {	int star = name.indexOf('*');	if (star < 0) {	    // single parameter, unencoded value	    list.put(name, value);	} else if (star == name.length() - 1) {	    // single parameter, encoded value	    name = name.substring(0, star);	    list.put(name, decodeValue(value));	} else {	    // multiple segments	    String rname = name.substring(0, star);	    multisegmentNames.add(rname);	    list.put(rname, "");	    Object v;	    if (name.endsWith("*")) {		// encoded value		v = new Value();		((Value)v).encodedValue = value;		((Value)v).value = value;	// default; decoded later		name = name.substring(0, name.length() - 1);	    } else {		// unencoded value		v = value;	    }	    slist.put(name, v);	}    }    /**     * Iterate through the saved set of names of multi-segment parameters,     * for each parameter find all segments stored in the slist map,     * decode each segment as needed, combine the segments together into     * a single decoded value, and save all segments in a MultiValue object     * in the main list indexed by the parameter name.     */    private void combineMultisegmentNames(boolean keepConsistentOnFailure)				throws ParseException {	boolean success = false;	try {	    Iterator it = multisegmentNames.iterator();	    while (it.hasNext()) {		String name = (String)it.next();		StringBuffer sb = new StringBuffer();		MultiValue mv = new MultiValue();		/*		 * Now find all the segments for this name and		 * decode each segment as needed.		 */		String charset = null;		int segment;		for (segment = 0; ; segment++) {		    String sname = name + "*" + segment;		    Object v = slist.get(sname);		    if (v == null)	// out of segments			break;		    mv.add(v);		    String value = null;		    if (v instanceof Value) {			try {			    Value vv = (Value)v;			    String evalue = vv.encodedValue;			    value = evalue;		// in case of exception			    if (segment == 0) {				// the first segment specified the charset				// for all other encoded segments				Value vnew = decodeValue(evalue);				charset = vv.charset = vnew.charset;				value = vv.value = vnew.value;			    } else {				if (charset == null) {				    // should never happen				    multisegmentNames.remove(name);

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲人123区| 亚洲精品v日韩精品| 成人丝袜视频网| 亚洲一区二区三区中文字幕| 欧美成人午夜电影| 成人精品亚洲人成在线| 男人的天堂亚洲一区| 中文字幕av一区二区三区高| 欧美日本一区二区三区| 成人av手机在线观看| 日本最新不卡在线| 亚洲国产日韩av| 亚洲天堂2016| 国产精品人妖ts系列视频| 欧美高清你懂得| 99re6这里只有精品视频在线观看| 国产精品538一区二区在线| 久久国产夜色精品鲁鲁99| 夜夜嗨av一区二区三区中文字幕| 国产欧美日产一区| 国产欧美一二三区| 精品久久久久久综合日本欧美| 欧美色窝79yyyycom| 日本道色综合久久| 欧美中文字幕一区| 91成人在线精品| 在线中文字幕一区| 欧美日韩在线一区二区| 欧美精品777| 日韩精品一区二区三区四区视频 | 成人av资源下载| 成人av在线资源网站| 国产高清精品久久久久| 国产一区亚洲一区| 夫妻av一区二区| 一本久道久久综合中文字幕| 欧美在线综合视频| 精品欧美一区二区在线观看| 精品国产亚洲在线| 国产日韩精品久久久| 国产欧美日韩三区| 亚洲精品高清在线观看| 污片在线观看一区二区| 国产原创一区二区三区| 国产高清成人在线| 色婷婷久久久综合中文字幕| 日韩美女视频在线| 日韩理论电影院| 久久精品国产精品青草| 国产99精品在线观看| 欧美亚洲愉拍一区二区| 久久亚洲私人国产精品va媚药| 国产精品三级电影| 美女视频一区二区三区| 欧美色偷偷大香| 亚洲色图欧美偷拍| www.久久久久久久久| ww久久中文字幕| 经典三级视频一区| 欧美精品一区二区精品网| 天天综合网天天综合色| 色av成人天堂桃色av| 亚洲欧美日韩电影| 色综合天天综合网天天狠天天| 国产精品美女www爽爽爽| 高清免费成人av| 国产精品你懂的在线| av午夜一区麻豆| 自拍偷拍国产精品| 色婷婷综合中文久久一本| 亚洲综合男人的天堂| 欧美久久久久久蜜桃| 久久99精品一区二区三区| 欧美va在线播放| 成人激情小说网站| 亚洲一区在线视频| 538在线一区二区精品国产| 激情综合网最新| 久久精品欧美日韩| 色视频欧美一区二区三区| 天堂va蜜桃一区二区三区漫画版| 欧美一级高清片| 成人毛片在线观看| 亚洲午夜久久久久久久久久久| 4438x亚洲最大成人网| 国产福利一区二区三区视频| 最新热久久免费视频| 正在播放一区二区| 不卡的av电影在线观看| 视频在线观看国产精品| 亚洲国产高清在线| 亚洲乱码中文字幕| 久久精品一二三| 欧美区一区二区三区| 成人免费毛片aaaaa**| 看电视剧不卡顿的网站| 一区二区三区四区激情| 久久久久九九视频| 欧美精品免费视频| 一本久道中文字幕精品亚洲嫩| 国产一区二区看久久| 视频在线在亚洲| 一区二区三区 在线观看视频| 久久久91精品国产一区二区精品| 欧洲色大大久久| 99久久久免费精品国产一区二区| 激情五月婷婷综合| 亚洲国产另类av| 亚洲第一在线综合网站| 一区二区三区成人在线视频| 久久奇米777| 亚洲一卡二卡三卡四卡| ...xxx性欧美| 伊人一区二区三区| 一区二区三区四区在线| 伊人色综合久久天天人手人婷| 国产精品区一区二区三| 国产精品区一区二区三区| 久久亚洲一区二区三区明星换脸| 欧美va日韩va| 国产精品美女久久久久aⅴ| 亚洲欧洲日韩av| 一区二区成人在线| 青青青伊人色综合久久| 亚洲一区二区美女| 国产精品看片你懂得 | 欧美亚州韩日在线看免费版国语版| 国产精品香蕉一区二区三区| 久久99国产精品久久| 美女国产一区二区三区| 老司机免费视频一区二区三区| 日韩电影在线免费| 波多野结衣精品在线| gogo大胆日本视频一区| 91最新地址在线播放| 色域天天综合网| 777xxx欧美| 日韩女优制服丝袜电影| 欧美激情在线观看视频免费| 中文字幕av在线一区二区三区| 中文字幕日韩精品一区| 亚洲精品视频自拍| 奇米在线7777在线精品| 国产精品一级片| 欧美主播一区二区三区美女| 欧美丰满高潮xxxx喷水动漫| 久久久久国产精品人| 中文字幕第一页久久| 午夜激情久久久| 丰满白嫩尤物一区二区| 欧美性大战xxxxx久久久| 久久天堂av综合合色蜜桃网| 亚洲天堂a在线| 麻豆精品国产传媒mv男同| 成人av先锋影音| 在线观看亚洲精品| 3d成人动漫网站| 一区二区三区国产| 成人黄色在线看| 日韩三级中文字幕| 中文一区一区三区高中清不卡| 亚洲一区视频在线| 成人手机电影网| 欧美三级日韩三级| 一区二区在线观看免费| 国产高清成人在线| 91精品国产aⅴ一区二区| 最新不卡av在线| 国v精品久久久网| 久久综合网色—综合色88| 免费观看91视频大全| 在线看日本不卡| 亚洲另类一区二区| 91免费精品国自产拍在线不卡| 日韩视频不卡中文| 日韩av电影免费观看高清完整版在线观看| 91婷婷韩国欧美一区二区| 日韩一区二区免费视频| 首页国产丝袜综合| 欧美一区二区三区白人| 日韩vs国产vs欧美| 欧美一区二区三区电影| 精品一区二区三区免费| 精品国偷自产国产一区| 美女一区二区三区在线观看| 欧美日本乱大交xxxxx| 奇米影视一区二区三区小说| 欧美精品18+| 美女精品自拍一二三四| 欧美国产成人精品| 国产乱码精品一区二区三区忘忧草| 国产三级精品视频| 99riav久久精品riav| 一区二区激情小说| 精品免费国产二区三区| 大陆成人av片| 亚洲成人激情自拍| 日韩视频在线永久播放| 风间由美一区二区三区在线观看| 一区二区三区四区中文字幕|