001/* 002 * ==================================================================== 003 * Licensed to the Apache Software Foundation (ASF) under one 004 * or more contributor license agreements. See the NOTICE file 005 * distributed with this work for additional information 006 * regarding copyright ownership. The ASF licenses this file 007 * to you under the Apache License, Version 2.0 (the 008 * "License"); you may not use this file except in compliance 009 * with the License. You may obtain a copy of the License at 010 * 011 * http://www.apache.org/licenses/LICENSE-2.0 012 * 013 * Unless required by applicable law or agreed to in writing, 014 * software distributed under the License is distributed on an 015 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 016 * KIND, either express or implied. See the License for the 017 * specific language governing permissions and limitations 018 * under the License. 019 * ==================================================================== 020 * 021 * This software consists of voluntary contributions made by many 022 * individuals on behalf of the Apache Software Foundation. For more 023 * information on the Apache Software Foundation, please see 024 * <http://www.apache.org/>. 025 * 026 */ 027package org.apache.http.client.params; 028 029/** 030 * Parameter names for HTTP client parameters. 031 * 032 * @since 4.0 033 * 034 * @deprecated (4.3) use {@link org.apache.http.client.config.RequestConfig}. 035 */ 036@Deprecated 037public interface ClientPNames { 038 039 public static final String CONNECTION_MANAGER_FACTORY_CLASS_NAME = "http.connection-manager.factory-class-name"; 040 041 /** 042 * Defines whether redirects should be handled automatically 043 * <p> 044 * This parameter expects a value of type {@link Boolean}. 045 * </p> 046 */ 047 public static final String HANDLE_REDIRECTS = "http.protocol.handle-redirects"; 048 049 /** 050 * Defines whether relative redirects should be rejected. HTTP specification 051 * requires the location value be an absolute URI. 052 * <p> 053 * This parameter expects a value of type {@link Boolean}. 054 * </p> 055 */ 056 public static final String REJECT_RELATIVE_REDIRECT = "http.protocol.reject-relative-redirect"; 057 058 /** 059 * Defines the maximum number of redirects to be followed. 060 * The limit on number of redirects is intended to prevent infinite loops. 061 * <p> 062 * This parameter expects a value of type {@link Integer}. 063 * </p> 064 */ 065 public static final String MAX_REDIRECTS = "http.protocol.max-redirects"; 066 067 /** 068 * Defines whether circular redirects (redirects to the same location) should be allowed. 069 * The HTTP spec is not sufficiently clear whether circular redirects are permitted, 070 * therefore optionally they can be enabled 071 * <p> 072 * This parameter expects a value of type {@link Boolean}. 073 * </p> 074 */ 075 public static final String ALLOW_CIRCULAR_REDIRECTS = "http.protocol.allow-circular-redirects"; 076 077 /** 078 * Defines whether authentication should be handled automatically. 079 * <p> 080 * This parameter expects a value of type {@link Boolean}. 081 * </p> 082 */ 083 public static final String HANDLE_AUTHENTICATION = "http.protocol.handle-authentication"; 084 085 /** 086 * Defines the name of the cookie specification to be used for HTTP state management. 087 * <p> 088 * This parameter expects a value of type {@link String}. 089 * </p> 090 */ 091 public static final String COOKIE_POLICY = "http.protocol.cookie-policy"; 092 093 /** 094 * Defines the virtual host to be used in the {@code Host} 095 * request header instead of the physical host. 096 * <p> 097 * This parameter expects a value of type {@link org.apache.http.HttpHost}. 098 * </p> 099 * If a port is not provided, it will be derived from the request URL. 100 */ 101 public static final String VIRTUAL_HOST = "http.virtual-host"; 102 103 /** 104 * Defines the request headers to be sent per default with each request. 105 * <p> 106 * This parameter expects a value of type {@link java.util.Collection}. The 107 * collection is expected to contain {@link org.apache.http.Header}s. 108 * </p> 109 */ 110 public static final String DEFAULT_HEADERS = "http.default-headers"; 111 112 /** 113 * Defines the default host. The default value will be used if the target host is 114 * not explicitly specified in the request URI. 115 * <p> 116 * This parameter expects a value of type {@link org.apache.http.HttpHost}. 117 * </p> 118 */ 119 public static final String DEFAULT_HOST = "http.default-host"; 120 121 /** 122 * Defines the timeout in milliseconds used when retrieving an instance of 123 * {@link org.apache.http.conn.ManagedClientConnection} from the 124 * {@link org.apache.http.conn.ClientConnectionManager}. 125 * <p> 126 * This parameter expects a value of type {@link Long}. 127 * <p> 128 * @since 4.2 129 */ 130 public static final String CONN_MANAGER_TIMEOUT = "http.conn-manager.timeout"; 131 132} 133