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

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

?? cookie.java

?? 圖書管理系統(tǒng),用JSP實(shí)現(xiàn),圖書的查詢,添加等功能
?? JAVA
?? 第 1 頁 / 共 2 頁
字號(hào):
/*
 * The Apache Software License, Version 1.1
 *
 * Copyright (c) 1999 The Apache Software Foundation.  All rights 
 * reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions
 * are met:
 *
 * 1. Redistributions of source code must retain the above copyright
 *    notice, this list of conditions and the following disclaimer. 
 *
 * 2. Redistributions in binary form must reproduce the above copyright
 *    notice, this list of conditions and the following disclaimer in
 *    the documentation and/or other materials provided with the
 *    distribution.
 *
 * 3. The end-user documentation included with the redistribution, if
 *    any, must include the following acknowlegement:  
 *       "This product includes software developed by the 
 *        Apache Software Foundation (http://www.apache.org/)."
 *    Alternately, this acknowlegement may appear in the software itself,
 *    if and wherever such third-party acknowlegements normally appear.
 *
 * 4. The names "The Jakarta Project", "Tomcat", and "Apache Software
 *    Foundation" must not be used to endorse or promote products derived
 *    from this software without prior written permission. For written 
 *    permission, please contact apache@apache.org.
 *
 * 5. Products derived from this software may not be called "Apache"
 *    nor may "Apache" appear in their names without prior written
 *    permission of the Apache Group.
 *
 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
 * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
 * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
 * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
 * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE.
 * ====================================================================
 *
 * This software consists of voluntary contributions made by many
 * individuals on behalf of the Apache Software Foundation.  For more
 * information on the Apache Software Foundation, please see
 * <http://www.apache.org/>.
 *
 * ====================================================================
 *
 * This source code implements specifications defined by the Java
 * Community Process. In order to remain compliant with the specification
 * DO NOT add / change / or delete method signatures!
 */ 

package javax.servlet.http;

import java.io.IOException;
import java.text.MessageFormat;
import java.util.ResourceBundle;

/**
 *
 * Creates a cookie, a small amount of information sent by a servlet to 
 * a Web browser, saved by the browser, and later sent back to the server.
 * A cookie's value can uniquely 
 * identify a client, so cookies are commonly used for session management.
 * 
 * <p>A cookie has a name, a single value, and optional attributes
 * such as a comment, path and domain qualifiers, a maximum age, and a
 * version number. Some Web browsers have bugs in how they handle the 
 * optional attributes, so use them sparingly to improve the interoperability 
 * of your servlets.
 *
 * <p>The servlet sends cookies to the browser by using the
 * {@link HttpServletResponse#addCookie} method, which adds
 * fields to HTTP response headers to send cookies to the 
 * browser, one at a time. The browser is expected to 
 * support 20 cookies for each Web server, 300 cookies total, and
 * may limit cookie size to 4 KB each.
 * 
 * <p>The browser returns cookies to the servlet by adding 
 * fields to HTTP request headers. Cookies can be retrieved
 * from a request by using the {@link HttpServletRequest#getCookies} method.
 * Several cookies might have the same name but different path attributes.
 * 
 * <p>Cookies affect the caching of the Web pages that use them. 
 * HTTP 1.0 does not cache pages that use cookies created with
 * this class. This class does not support the cache control
 * defined with HTTP 1.1.
 *
 * <p>This class supports both the Version 0 (by Netscape) and Version 1 
 * (by RFC 2109) cookie specifications. By default, cookies are
 * created using Version 0 to ensure the best interoperability.
 *
 *
 * @author	Various
 * @version	$Version$
 *
 */

// XXX would implement java.io.Serializable too, but can't do that
// so long as sun.servlet.* must run on older JDK 1.02 JVMs which
// don't include that support.

public class Cookie implements Cloneable {

    private static final String LSTRING_FILE =
	"javax.servlet.http.LocalStrings";
    private static ResourceBundle lStrings =
	ResourceBundle.getBundle(LSTRING_FILE);
    
    //
    // The value of the cookie itself.
    //
    
    private String name;	// NAME= ... "$Name" style is reserved
    private String value;	// value of NAME

    //
    // Attributes encoded in the header's cookie fields.
    //
    
    private String comment;	// ;Comment=VALUE ... describes cookie's use
				// ;Discard ... implied by maxAge < 0
    private String domain;	// ;Domain=VALUE ... domain that sees cookie
    private int maxAge = -1;	// ;Max-Age=VALUE ... cookies auto-expire
    private String path;	// ;Path=VALUE ... URLs that see the cookie
    private boolean secure;	// ;Secure ... e.g. use SSL
    private int version = 0;	// ;Version=1 ... means RFC 2109++ style
    
    

    /**
     * Constructs a cookie with a specified name and value.
     *
     * <p>The name must conform to RFC 2109. That means it can contain 
     * only ASCII alphanumeric characters and cannot contain commas, 
     * semicolons, or white space or begin with a $ character. The cookie's
     * name cannot be changed after creation.
     *
     * <p>The value can be anything the server chooses to send. Its
     * value is probably of interest only to the server. The cookie's
     * value can be changed after creation with the
     * <code>setValue</code> method.
     *
     * <p>By default, cookies are created according to the Netscape
     * cookie specification. The version can be changed with the 
     * <code>setVersion</code> method.
     *
     *
     * @param name 			a <code>String</code> specifying the name of the cookie
     *
     * @param value			a <code>String</code> specifying the value of the cookie
     *
     * @throws IllegalArgumentException	if the cookie name contains illegal characters
     *					(for example, a comma, space, or semicolon)
     *					or it is one of the tokens reserved for use
     *					by the cookie protocol
     * @see #setValue
     * @see #setVersion
     *
     */

    public Cookie(String name, String value) {
	if (!isToken(name)
		|| name.equalsIgnoreCase("Comment")	// rfc2019
		|| name.equalsIgnoreCase("Discard")	// 2019++
		|| name.equalsIgnoreCase("Domain")
		|| name.equalsIgnoreCase("Expires")	// (old cookies)
		|| name.equalsIgnoreCase("Max-Age")	// rfc2019
		|| name.equalsIgnoreCase("Path")
		|| name.equalsIgnoreCase("Secure")
		|| name.equalsIgnoreCase("Version")
	    ) {
	    String errMsg = lStrings.getString("err.cookie_name_is_token");
	    Object[] errArgs = new Object[1];
	    errArgs[0] = name;
	    errMsg = MessageFormat.format(errMsg, errArgs);
	    throw new IllegalArgumentException(errMsg);
	}

	this.name = name;
	this.value = value;
    }





    /**
     *
     * Specifies a comment that describes a cookie's purpose.
     * The comment is useful if the browser presents the cookie 
     * to the user. Comments
     * are not supported by Netscape Version 0 cookies.
     *
     * @param purpose		a <code>String</code> specifying the comment 
     *				to display to the user
     *
     * @see #getComment
     *
     */

    public void setComment(String purpose) {
	comment = purpose;
    }
    
    
    

    /**
     * Returns the comment describing the purpose of this cookie, or
     * <code>null</code> if the cookie has no comment.
     *
     * @return			a <code>String</code> containing the comment,
     *				or <code>null</code> if none
     *
     * @see #setComment
     *
     */ 

    public String getComment() {
	return comment;
    }
    
    
    


    /**
     *
     * Specifies the domain within which this cookie should be presented.
     *
     * <p>The form of the domain name is specified by RFC 2109. A domain
     * name begins with a dot (<code>.foo.com</code>) and means that
     * the cookie is visible to servers in a specified Domain Name System
     * (DNS) zone (for example, <code>www.foo.com</code>, but not 
     * <code>a.b.foo.com</code>). By default, cookies are only returned
     * to the server that sent them.
     *
     *
     * @param pattern		a <code>String</code> containing the domain name
     *				within which this cookie is visible;
     *				form is according to RFC 2109
     *
     * @see #getDomain
     *
     */

    public void setDomain(String pattern) {
	domain = pattern.toLowerCase();	// IE allegedly needs this
    }
    
    
    
    

    /**
     * Returns the domain name set for this cookie. The form of 
     * the domain name is set by RFC 2109.
     *
     * @return			a <code>String</code> containing the domain name
     *
     * @see #setDomain
     *
     */ 

    public String getDomain() {
	return domain;
    }




    /**
     * Sets the maximum age of the cookie in seconds.
     *
     * <p>A positive value indicates that the cookie will expire
     * after that many seconds have passed. Note that the value is
     * the <i>maximum</i> age when the cookie will expire, not the cookie's
     * current age.
     *
     * <p>A negative value means
     * that the cookie is not stored persistently and will be deleted
     * when the Web browser exits. A zero value causes the cookie

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲成av人片在线观看| 91成人免费在线视频| 精品国产一区二区国模嫣然| 亚洲欧美日韩久久精品| 99国产精品国产精品久久| 国产精品久久久久久久久动漫| 国产精品白丝av| 国产精品水嫩水嫩| 91视频在线观看| 亚洲午夜视频在线观看| 欧美一区二区在线免费播放| 国产原创一区二区| 中文字幕一区二区在线播放| 欧美无砖砖区免费| 蜜臀av国产精品久久久久| 久久久www成人免费无遮挡大片| 国产精品99久久久久久有的能看 | 国产91清纯白嫩初高中在线观看| 欧美国产成人在线| 日本久久电影网| 美女视频黄频大全不卡视频在线播放 | 91视频91自| 日本特黄久久久高潮| 精品99久久久久久| 99精品偷自拍| 美女任你摸久久 | 色综合天天综合在线视频| 亚洲国产日韩一级| 国产亚洲制服色| 欧美日韩在线直播| 狠狠色综合播放一区二区| 日韩毛片高清在线播放| 555夜色666亚洲国产免| 国产a久久麻豆| 亚洲成国产人片在线观看| 国产亚洲综合性久久久影院| 欧美色电影在线| 粉嫩av一区二区三区粉嫩| 亚洲福利一区二区| 中文字幕乱码日本亚洲一区二区 | 欧美日韩激情在线| 高清成人在线观看| 日韩中文字幕麻豆| 中文字幕亚洲综合久久菠萝蜜| 69av一区二区三区| 91亚洲国产成人精品一区二三| 麻豆久久久久久久| 一区二区三区四区在线播放 | 9色porny自拍视频一区二区| 美女精品一区二区| 亚洲第四色夜色| 中文字幕亚洲欧美在线不卡| 欧美xxxx老人做受| 欧美日韩高清一区二区不卡| 99热国产精品| 国产suv精品一区二区6| 美国毛片一区二区三区| 午夜亚洲国产au精品一区二区 | 亚洲天堂免费看| 国产色91在线| 精品国产在天天线2019| 国产精品久久久久9999吃药| 国产在线视视频有精品| 亚洲va国产天堂va久久en| 9191精品国产综合久久久久久| 免费在线观看一区| 337p粉嫩大胆噜噜噜噜噜91av | 日本一区二区三区四区| 成人免费福利片| 亚洲成在人线在线播放| fc2成人免费人成在线观看播放| 美女网站视频久久| 日本伊人午夜精品| 免费观看91视频大全| 五月天丁香久久| 亚洲成a人v欧美综合天堂| 亚洲一级在线观看| 亚洲午夜久久久久久久久电影院| 亚洲精品一二三区| 一区二区免费视频| 一区二区三区加勒比av| 亚洲国产日韩av| 亚洲成人动漫在线观看| 天堂在线一区二区| 日韩电影免费在线看| 免费av成人在线| 久草热8精品视频在线观看| 国内外成人在线| 国产精品一二三四区| 成人美女视频在线观看| 91玉足脚交白嫩脚丫在线播放| 91丨porny丨在线| 欧美艳星brazzers| 日韩欧美在线网站| 久久久www成人免费毛片麻豆| 国产精品色婷婷| 一区二区三区中文字幕电影| 亚洲成在人线在线播放| 国内精品免费在线观看| eeuss国产一区二区三区| 91国偷自产一区二区使用方法| 欧美午夜电影网| 欧美va亚洲va国产综合| 中文字幕亚洲一区二区av在线| 亚洲国产精品久久人人爱| 免费观看日韩电影| 国产999精品久久| 在线亚洲人成电影网站色www| 777亚洲妇女| 久久精品人人爽人人爽| 一区二区三区日韩精品视频| 日韩成人精品视频| 国产成a人亚洲精品| 欧日韩精品视频| xvideos.蜜桃一区二区| 亚洲精选免费视频| 激情五月婷婷综合| 在线观看精品一区| 久久夜色精品一区| 亚洲线精品一区二区三区八戒| 激情久久五月天| 在线免费一区三区| 国产三级一区二区三区| 8x福利精品第一导航| 精品免费一区二区三区| 成人激情动漫在线观看| 欧美一区二区视频免费观看| 中文字幕在线不卡国产视频| 亚洲人成在线播放网站岛国| 麻豆精品视频在线观看| 91偷拍与自偷拍精品| 精品少妇一区二区三区免费观看| 日韩一区在线看| 久色婷婷小香蕉久久| 一本大道久久a久久综合| 日韩限制级电影在线观看| 丁香五精品蜜臀久久久久99网站| 91久久人澡人人添人人爽欧美| 亚洲精品一区二区在线观看| 亚洲一区二区三区爽爽爽爽爽 | 亚洲一卡二卡三卡四卡| 国产精品亚洲成人| 欧美成人在线直播| 五月天视频一区| 91在线porny国产在线看| 久久久久国产一区二区三区四区 | 亚洲高清在线精品| 99国产一区二区三精品乱码| 久久久99免费| 久久国产尿小便嘘嘘| 这里只有精品电影| 亚洲午夜激情网站| 91久久久免费一区二区| 国产精品不卡一区| 岛国精品在线播放| 久久精品亚洲麻豆av一区二区| 美女视频黄 久久| 日韩一区二区免费视频| 亚欧色一区w666天堂| 欧美性猛片xxxx免费看久爱| 亚洲免费资源在线播放| 99国产精品久久久久| 中文字幕五月欧美| 大白屁股一区二区视频| 亚洲国产高清不卡| 高清不卡一二三区| 欧美激情一区二区三区蜜桃视频| 国产麻豆精品在线| 国产蜜臀av在线一区二区三区| 久草精品在线观看| 国产欧美综合色| 成人夜色视频网站在线观看| 国产精品视频在线看| 99久久99久久精品国产片果冻 | 日本不卡视频在线| 日韩免费观看高清完整版| 看片的网站亚洲| 久久综合九色综合97_久久久| 激情偷乱视频一区二区三区| 久久精品视频一区| 92国产精品观看| 亚洲电影一级黄| 欧美一级日韩一级| 国产精品 日产精品 欧美精品| 久久精品夜夜夜夜久久| 91免费看片在线观看| 亚洲一区二区三区影院| 婷婷国产v国产偷v亚洲高清| 国产三级精品在线| 精品一区二区免费视频| 成人性生交大片免费看视频在线 | 欧美极品xxx| 欧美一区二区三区公司| 欧美色爱综合网| 欧美影片第一页| 在线观看亚洲精品| 精品视频1区2区| 欧美精品tushy高清| 欧美精品一区视频| 成人av免费网站|