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

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

?? httpconnection.java

?? 一個基于lucene&heritrix的搜索引擎
?? JAVA
?? 第 1 頁 / 共 4 頁
字號:
/* * $Header: /cvsroot/archive-crawler/ArchiveOpenCrawler/src/java/org/apache/commons/httpclient/HttpConnection.java,v 1.10 2006/08/15 04:38:59 gojomo Exp $ * $Revision: 1.10 $ * $Date: 2006/08/15 04:38:59 $ * * ==================================================================== * *  Copyright 1999-2004 The Apache Software Foundation * *  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. * ==================================================================== * * 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/>. * */package org.apache.commons.httpclient;import java.io.BufferedInputStream;import java.io.BufferedOutputStream;import java.io.IOException;import java.io.InputStream;import java.io.InterruptedIOException;import java.io.OutputStream;import java.lang.reflect.Method;import java.net.InetAddress;import java.net.Socket;import java.net.SocketException;import org.apache.commons.httpclient.params.HttpConnectionParams;import org.apache.commons.httpclient.protocol.DefaultProtocolSocketFactory;import org.apache.commons.httpclient.protocol.Protocol;import org.apache.commons.httpclient.protocol.ProtocolSocketFactory;import org.apache.commons.httpclient.protocol.SecureProtocolSocketFactory;import org.apache.commons.httpclient.util.EncodingUtil;import org.apache.commons.httpclient.util.ExceptionUtil;import org.apache.commons.logging.Log;import org.apache.commons.logging.LogFactory;// HERITRIX import.import org.archive.util.HttpRecorder;/** * An abstraction of an HTTP {@link InputStream} and {@link OutputStream} * pair, together with the relevant attributes. * <p> * The following options are set on the socket before getting the input/output  * streams in the {@link #open()} method: * <table border=1><tr> *    <th>Socket Method *    <th>Sockets Option *    <th>Configuration * </tr><tr> *    <td>{@link java.net.Socket#setTcpNoDelay(boolean)} *    <td>SO_NODELAY *    <td>{@link HttpConnectionParams#setTcpNoDelay(boolean)} * </tr><tr> *    <td>{@link java.net.Socket#setSoTimeout(int)} *    <td>SO_TIMEOUT *    <td>{@link HttpConnectionParams#setSoTimeout(int)} * </tr><tr> *    <td>{@link java.net.Socket#setSendBufferSize(int)} *    <td>SO_SNDBUF *    <td>{@link HttpConnectionParams#setSendBufferSize(int)} * </tr><tr> *    <td>{@link java.net.Socket#setReceiveBufferSize(int)} *    <td>SO_RCVBUF *    <td>{@link HttpConnectionParams#setReceiveBufferSize(int)} * </tr></table> * * @author Rod Waldhoff * @author Sean C. Sullivan * @author Ortwin Glueck * @author <a href="mailto:jsdever@apache.org">Jeff Dever</a> * @author <a href="mailto:mbowler@GargoyleSoftware.com">Mike Bowler</a> * @author <a href="mailto:oleg@ural.ru">Oleg Kalnichevski</a> * @author Michael Becke * @author Eric E Johnson * @author Laura Werner *  * @version   $Revision: 1.10 $ $Date: 2006/08/15 04:38:59 $ */public class HttpConnection {    // ----------------------------------------------------------- Constructors    /**     * Creates a new HTTP connection for the given host and port.     *     * @param host the host to connect to     * @param port the port to connect to     */    public HttpConnection(String host, int port) {        this(null, -1, host, null, port, Protocol.getProtocol("http"));    }    /**     * Creates a new HTTP connection for the given host and port     * using the given protocol.     *     * @param host the host to connect to     * @param port the port to connect to     * @param protocol the protocol to use     */    public HttpConnection(String host, int port, Protocol protocol) {        this(null, -1, host, null, port, protocol);    }    /**     * Creates a new HTTP connection for the given host with the virtual      * alias and port using given protocol.     *     * @param host the host to connect to     * @param virtualHost the virtual host requests will be sent to     * @param port the port to connect to     * @param protocol the protocol to use     */    public HttpConnection(String host, String virtualHost, int port, Protocol protocol) {        this(null, -1, host, virtualHost, port, protocol);    }    /**     * Creates a new HTTP connection for the given host and port via the      * given proxy host and port using the default protocol.     *     * @param proxyHost the host to proxy via     * @param proxyPort the port to proxy via     * @param host the host to connect to     * @param port the port to connect to     */    public HttpConnection(        String proxyHost,        int proxyPort,        String host,        int port) {        this(proxyHost, proxyPort, host, null, port, Protocol.getProtocol("http"));    }    /**     * Creates a new HTTP connection for the given host configuration.     *      * @param hostConfiguration the host/proxy/protocol to use     */    public HttpConnection(HostConfiguration hostConfiguration) {        this(hostConfiguration.getProxyHost(),             hostConfiguration.getProxyPort(),             hostConfiguration.getHost(),             hostConfiguration.getPort(),             hostConfiguration.getProtocol());        this.localAddress = hostConfiguration.getLocalAddress();    }    /**     * Creates a new HTTP connection for the given host with the virtual      * alias and port via the given proxy host and port using the given      * protocol.     *      * @param proxyHost the host to proxy via     * @param proxyPort the port to proxy via     * @param host the host to connect to. Parameter value must be non-null.     * @param virtualHost No longer applicable.      * @param port the port to connect to     * @param protocol The protocol to use. Parameter value must be non-null.     *      * @deprecated use #HttpConnection(String, int, String, int, Protocol)     */    public HttpConnection(        String proxyHost,        int proxyPort,        String host,        String virtualHost,        int port,        Protocol protocol) {        this(proxyHost, proxyPort, host, port, protocol);    }    /**     * Creates a new HTTP connection for the given host with the virtual      * alias and port via the given proxy host and port using the given      * protocol.     *      * @param proxyHost the host to proxy via     * @param proxyPort the port to proxy via     * @param host the host to connect to. Parameter value must be non-null.     * @param port the port to connect to     * @param protocol The protocol to use. Parameter value must be non-null.     */    public HttpConnection(        String proxyHost,        int proxyPort,        String host,        int port,        Protocol protocol) {        if (host == null) {            throw new IllegalArgumentException("host parameter is null");        }        if (protocol == null) {            throw new IllegalArgumentException("protocol is null");        }        proxyHostName = proxyHost;        proxyPortNumber = proxyPort;        hostName = host;        portNumber = protocol.resolvePort(port);        protocolInUse = protocol;    }    // ------------------------------------------ Attribute Setters and Getters    /**     * Returns the connection socket.     *     * @return the socket.     *      * @since 3.0     */    protected Socket getSocket() {        return this.socket;    }    /**     * Returns the host.     *     * @return the host.     */    public String getHost() {        return hostName;    }    /**     * Sets the host to connect to.     *     * @param host the host to connect to. Parameter value must be non-null.     * @throws IllegalStateException if the connection is already open     */    public void setHost(String host) throws IllegalStateException {        if (host == null) {            throw new IllegalArgumentException("host parameter is null");        }        assertNotOpen();        hostName = host;    }    /**     * Returns the target virtual host.     *     * @return the virtual host.     *      * @deprecated no longer applicable     */    public String getVirtualHost() {        return this.hostName;    }    /**     * Sets the virtual host to target.     *     * @param host the virtual host name that should be used instead of      *        physical host name when sending HTTP requests. Virtual host      *        name can be set to <tt> null</tt> if virtual host name is not     *        to be used     *      * @throws IllegalStateException if the connection is already open     *      * @deprecated no longer applicable     */    public void setVirtualHost(String host) throws IllegalStateException {        assertNotOpen();    }    /**     * Returns the port of the host.     *     * If the port is -1 (or less than 0) the default port for     * the current protocol is returned.     *     * @return the port.     */    public int getPort() {        if (portNumber < 0) {            return isSecure() ? 443 : 80;        } else {            return portNumber;        }    }    /**     * Sets the port to connect to.     *     * @param port the port to connect to     *      * @throws IllegalStateException if the connection is already open     */    public void setPort(int port) throws IllegalStateException {        assertNotOpen();        portNumber = port;    }    /**     * Returns the proxy host.     *     * @return the proxy host.     */    public String getProxyHost() {        return proxyHostName;    }    /**     * Sets the host to proxy through.     *     * @param host the host to proxy through.     *      * @throws IllegalStateException if the connection is already open     */    public void setProxyHost(String host) throws IllegalStateException {        assertNotOpen();        proxyHostName = host;    }    /**     * Returns the port of the proxy host.     *     * @return the proxy port.     */    public int getProxyPort() {        return proxyPortNumber;    }    /**     * Sets the port of the host to proxy through.     *     * @param port the port of the host to proxy through.     *      * @throws IllegalStateException if the connection is already open

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
韩国中文字幕2020精品| 亚洲三级在线看| 美国毛片一区二区三区| 日韩欧美国产一区在线观看| 久久成人羞羞网站| 久久老女人爱爱| 成人av在线资源| 一区二区不卡在线视频 午夜欧美不卡在| 91啦中文在线观看| 午夜视频一区二区| 欧美mv日韩mv国产网站app| 国产999精品久久久久久绿帽| 日韩伦理免费电影| 9191成人精品久久| 国产精品一级片在线观看| 中文字幕在线免费不卡| 色屁屁一区二区| 亚欧色一区w666天堂| 日韩欧美一级二级| 成人免费高清视频| 香蕉久久夜色精品国产使用方法| 日韩情涩欧美日韩视频| 成人性色生活片免费看爆迷你毛片| 玉米视频成人免费看| 精品免费日韩av| 99精品视频在线免费观看| 亚洲成a人片综合在线| 久久精品欧美日韩精品| 在线亚洲欧美专区二区| 久久97超碰色| 亚洲精品美国一| 久久久久久久综合| 精品视频一区 二区 三区| 国产乱一区二区| 亚洲第一av色| 欧美国产1区2区| 在线综合视频播放| 色综合久久久久综合体桃花网| 久久国产精品免费| 一区二区三区四区不卡视频| 精品国产123| 欧美片网站yy| 色狠狠av一区二区三区| 国产一本一道久久香蕉| 石原莉奈在线亚洲二区| 1024亚洲合集| 久久精品视频在线免费观看| 欧美二区三区的天堂| 97se亚洲国产综合在线| 精品中文字幕一区二区小辣椒| 亚洲精品老司机| 国产欧美日韩视频在线观看| 欧美一区二区三区播放老司机| 色综合天天综合给合国产| 国产福利精品一区二区| 理论电影国产精品| 日韩电影在线一区二区三区| 一区二区三区视频在线观看| 欧美激情资源网| 久久综合av免费| 欧美一二区视频| 欧美一区在线视频| 欧美午夜片在线观看| 色婷婷激情综合| jlzzjlzz亚洲女人18| 国产精品一区二区果冻传媒| 久久精品国产一区二区三 | kk眼镜猥琐国模调教系列一区二区| 另类小说一区二区三区| 日本成人在线电影网| 亚洲va欧美va国产va天堂影院| 日本一区二区三区在线不卡| 久久久久99精品一区| 精品国产免费人成电影在线观看四季| 欧美福利视频一区| 欧美人牲a欧美精品| 欧美精品亚洲二区| 制服丝袜亚洲色图| 日韩一区二区电影网| 日韩欧美一区电影| 欧美成人女星排行榜| 麻豆91免费观看| 久久精品国产77777蜜臀| 日韩中文字幕区一区有砖一区| 精品99一区二区三区| 欧美日韩高清影院| 欧美亚洲动漫精品| 成人一区在线看| 国产美女久久久久| 依依成人精品视频| 亚洲精选在线视频| 综合自拍亚洲综合图不卡区| 亚洲美女淫视频| 亚洲成人免费看| 日韩电影免费在线看| 青青草97国产精品免费观看| 美女视频一区在线观看| 国产专区欧美精品| 成av人片一区二区| 日本韩国精品在线| 欧美片网站yy| 久久精品一区蜜桃臀影院| 一色屋精品亚洲香蕉网站| 夜夜揉揉日日人人青青一国产精品 | 欧美日韩二区三区| 欧美一区二区三区四区五区 | 欧美日韩亚洲综合一区| 日韩一区二区三区高清免费看看| 精品国产制服丝袜高跟| 亚洲图片欧美激情| 日韩av一区二区在线影视| 国产在线播精品第三| 一本高清dvd不卡在线观看| 91精品国产91久久久久久最新毛片| 久久精品一区四区| 亚洲高清视频的网址| 国产精品一区久久久久| 欧美在线观看你懂的| 精品国产一区二区三区不卡| 中文字幕综合网| 国内外精品视频| 欧美性受xxxx黑人xyx| 精品入口麻豆88视频| 亚洲天天做日日做天天谢日日欢 | 亚洲国产精品国自产拍av| 亚洲综合久久久| 国产999精品久久久久久绿帽| 欧美体内she精视频| 国产三区在线成人av| 婷婷综合五月天| 99久久婷婷国产综合精品电影| 日韩一区二区视频| 亚洲精品乱码久久久久久日本蜜臀| 激情五月激情综合网| 在线观看亚洲一区| 国产精品入口麻豆原神| 激情av综合网| 91精品国产aⅴ一区二区| 一区二区三区丝袜| av在线免费不卡| 久久嫩草精品久久久久| 男人的j进女人的j一区| 99久久国产综合色|国产精品| 亚洲国产精品视频| 26uuu国产电影一区二区| 亚洲国产另类精品专区| 不卡电影一区二区三区| 国产精品欧美极品| 国产一区二区三区黄视频 | 亚洲成人一二三| 91国内精品野花午夜精品| 亚洲福利视频导航| 另类小说欧美激情| 在线综合视频播放| 亚洲福利电影网| 色哟哟国产精品| 日韩一区在线免费观看| 成人伦理片在线| 日本一区二区高清| 成人v精品蜜桃久久一区| 久久久91精品国产一区二区精品| 日本中文字幕一区| 91麻豆精品国产91| 日韩精品高清不卡| 精品婷婷伊人一区三区三| 亚洲精品乱码久久久久久日本蜜臀| 不卡高清视频专区| 亚洲欧美日韩国产中文在线| 91亚洲精品一区二区乱码| 国产精品福利一区| 99久久99久久久精品齐齐| 中文字幕成人av| 成+人+亚洲+综合天堂| 国产精品不卡在线| 色欧美片视频在线观看| 一区二区欧美精品| 欧美伦理视频网站| 精品一区二区三区在线观看 | 欧美中文字幕亚洲一区二区va在线 | 亚洲精选视频在线| 在线精品国精品国产尤物884a | 男人操女人的视频在线观看欧美| 欧美肥大bbwbbw高潮| 激情综合网最新| 中文字幕av一区二区三区| 成人高清视频免费观看| 亚洲欧美日韩一区二区 | 精品国产乱码久久久久久免费 | 蜜桃av噜噜一区二区三区小说| 欧美一区二区福利在线| 国产一区二区在线观看免费 | 一区二区在线看| 欧美区一区二区三区| 韩国v欧美v亚洲v日本v| 亚洲欧洲另类国产综合| 欧美精品在线一区二区| 国内精品免费**视频| 亚洲婷婷综合色高清在线| 91精品国产免费| 成人晚上爱看视频|