org.apache.httpcomponents.httpclient_4.1.2.v201202091730

16:41:05.856 INFO  jd.cli.Main - Decompiling org.apache.httpcomponents.httpclient_4.1.2.v201202091730.jar
package org.apache.http.annotation;

import java.lang.annotation.Annotation;
import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

@Documented
@Target({java.lang.annotation.ElementType.FIELD, java.lang.annotation.ElementType.METHOD})
@Retention(RetentionPolicy.CLASS)
public @interface GuardedBy
{
  String value();
}

/* Location:
 * Qualified Name:     org.apache.http.annotation.GuardedBy
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.annotation;

import java.lang.annotation.Annotation;
import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

@Documented
@Target({java.lang.annotation.ElementType.TYPE})
@Retention(RetentionPolicy.CLASS)
public @interface Immutable {}

/* Location:
 * Qualified Name:     org.apache.http.annotation.Immutable
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.annotation;

import java.lang.annotation.Annotation;
import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

@Documented
@Target({java.lang.annotation.ElementType.TYPE})
@Retention(RetentionPolicy.CLASS)
public @interface NotThreadSafe {}

/* Location:
 * Qualified Name:     org.apache.http.annotation.NotThreadSafe
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.annotation;

import java.lang.annotation.Annotation;
import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

@Documented
@Target({java.lang.annotation.ElementType.TYPE})
@Retention(RetentionPolicy.CLASS)
public @interface ThreadSafe {}

/* Location:
 * Qualified Name:     org.apache.http.annotation.ThreadSafe
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import org.apache.http.annotation.Immutable;

@Immutable
public final class AUTH
{
  public static final String WWW_AUTH = "WWW-Authenticate";
  public static final String WWW_AUTH_RESP = "Authorization";
  public static final String PROXY_AUTH = "Proxy-Authenticate";
  public static final String PROXY_AUTH_RESP = "Proxy-Authorization";
}

/* Location:
 * Qualified Name:     org.apache.http.auth.AUTH
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import org.apache.http.Header;
import org.apache.http.HttpRequest;

public abstract interface AuthScheme
{
  public abstract void processChallenge(Header paramHeader)
    throws MalformedChallengeException;
  
  public abstract String getSchemeName();
  
  public abstract String getParameter(String paramString);
  
  public abstract String getRealm();
  
  public abstract boolean isConnectionBased();
  
  public abstract boolean isComplete();
  
  @Deprecated
  public abstract Header authenticate(Credentials paramCredentials, HttpRequest paramHttpRequest)
    throws AuthenticationException;
}

/* Location:
 * Qualified Name:     org.apache.http.auth.AuthScheme
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import org.apache.http.params.HttpParams;

public abstract interface AuthSchemeFactory
{
  public abstract AuthScheme newInstance(HttpParams paramHttpParams);
}

/* Location:
 * Qualified Name:     org.apache.http.auth.AuthSchemeFactory
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import java.util.ArrayList;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;
import org.apache.http.annotation.ThreadSafe;
import org.apache.http.params.HttpParams;

@ThreadSafe
public final class AuthSchemeRegistry
{
  private final ConcurrentHashMap<String, AuthSchemeFactory> registeredSchemes;
  
  public AuthSchemeRegistry()
  {
    registeredSchemes = new ConcurrentHashMap();
  }
  
  public void register(String name, AuthSchemeFactory factory)
  {
    if (name == null) {
      throw new IllegalArgumentException("Name may not be null");
    }
    if (factory == null) {
      throw new IllegalArgumentException("Authentication scheme factory may not be null");
    }
    registeredSchemes.put(name.toLowerCase(Locale.ENGLISH), factory);
  }
  
  public void unregister(String name)
  {
    if (name == null) {
      throw new IllegalArgumentException("Name may not be null");
    }
    registeredSchemes.remove(name.toLowerCase(Locale.ENGLISH));
  }
  
  public AuthScheme getAuthScheme(String name, HttpParams params)
    throws IllegalStateException
  {
    if (name == null) {
      throw new IllegalArgumentException("Name may not be null");
    }
    AuthSchemeFactory factory = (AuthSchemeFactory)registeredSchemes.get(name.toLowerCase(Locale.ENGLISH));
    if (factory != null) {
      return factory.newInstance(params);
    }
    throw new IllegalStateException("Unsupported authentication scheme: " + name);
  }
  
  public List<String> getSchemeNames()
  {
    return new ArrayList(registeredSchemes.keySet());
  }
  
  public void setItems(Map<String, AuthSchemeFactory> map)
  {
    if (map == null) {
      return;
    }
    registeredSchemes.clear();
    registeredSchemes.putAll(map);
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.AuthSchemeRegistry
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import java.util.Locale;
import org.apache.http.annotation.Immutable;
import org.apache.http.util.LangUtils;

@Immutable
public class AuthScope
{
  public static final String ANY_HOST = null;
  public static final int ANY_PORT = -1;
  public static final String ANY_REALM = null;
  public static final String ANY_SCHEME = null;
  public static final AuthScope ANY = new AuthScope(ANY_HOST, -1, ANY_REALM, ANY_SCHEME);
  private final String scheme;
  private final String realm;
  private final String host;
  private final int port;
  
  public AuthScope(String host, int port, String realm, String scheme)
  {
    this.host = (host == null ? ANY_HOST : host.toLowerCase(Locale.ENGLISH));
    this.port = (port < 0 ? -1 : port);
    this.realm = (realm == null ? ANY_REALM : realm);
    this.scheme = (scheme == null ? ANY_SCHEME : scheme.toUpperCase(Locale.ENGLISH));
  }
  
  public AuthScope(String host, int port, String realm)
  {
    this(host, port, realm, ANY_SCHEME);
  }
  
  public AuthScope(String host, int port)
  {
    this(host, port, ANY_REALM, ANY_SCHEME);
  }
  
  public AuthScope(AuthScope authscope)
  {
    if (authscope == null) {
      throw new IllegalArgumentException("Scope may not be null");
    }
    host = authscope.getHost();
    port = authscope.getPort();
    realm = authscope.getRealm();
    scheme = authscope.getScheme();
  }
  
  public String getHost()
  {
    return host;
  }
  
  public int getPort()
  {
    return port;
  }
  
  public String getRealm()
  {
    return realm;
  }
  
  public String getScheme()
  {
    return scheme;
  }
  
  public int match(AuthScope that)
  {
    int factor = 0;
    if (LangUtils.equals(scheme, scheme)) {
      factor++;
    } else if ((scheme != ANY_SCHEME) && (scheme != ANY_SCHEME)) {
      return -1;
    }
    if (LangUtils.equals(realm, realm)) {
      factor += 2;
    } else if ((realm != ANY_REALM) && (realm != ANY_REALM)) {
      return -1;
    }
    if (port == port) {
      factor += 4;
    } else if ((port != -1) && (port != -1)) {
      return -1;
    }
    if (LangUtils.equals(host, host)) {
      factor += 8;
    } else if ((host != ANY_HOST) && (host != ANY_HOST)) {
      return -1;
    }
    return factor;
  }
  
  public boolean equals(Object o)
  {
    if (o == null) {
      return false;
    }
    if (o == this) {
      return true;
    }
    if (!(o instanceof AuthScope)) {
      return super.equals(o);
    }
    AuthScope that = (AuthScope)o;
    return (LangUtils.equals(host, host)) && (port == port) && (LangUtils.equals(realm, realm)) && (LangUtils.equals(scheme, scheme));
  }
  
  public String toString()
  {
    StringBuilder buffer = new StringBuilder();
    if (scheme != null)
    {
      buffer.append(scheme.toUpperCase(Locale.ENGLISH));
      buffer.append(' ');
    }
    if (realm != null)
    {
      buffer.append('\'');
      buffer.append(realm);
      buffer.append('\'');
    }
    else
    {
      buffer.append("<any realm>");
    }
    if (host != null)
    {
      buffer.append('@');
      buffer.append(host);
      if (port >= 0)
      {
        buffer.append(':');
        buffer.append(port);
      }
    }
    return buffer.toString();
  }
  
  public int hashCode()
  {
    int hash = 17;
    hash = LangUtils.hashCode(hash, host);
    hash = LangUtils.hashCode(hash, port);
    hash = LangUtils.hashCode(hash, realm);
    hash = LangUtils.hashCode(hash, scheme);
    return hash;
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.AuthScope
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import org.apache.http.annotation.NotThreadSafe;

@NotThreadSafe
public class AuthState
{
  private AuthScheme authScheme;
  private AuthScope authScope;
  private Credentials credentials;
  
  public void invalidate()
  {
    authScheme = null;
    authScope = null;
    credentials = null;
  }
  
  public boolean isValid()
  {
    return authScheme != null;
  }
  
  public void setAuthScheme(AuthScheme authScheme)
  {
    if (authScheme == null)
    {
      invalidate();
      return;
    }
    this.authScheme = authScheme;
  }
  
  public AuthScheme getAuthScheme()
  {
    return authScheme;
  }
  
  public Credentials getCredentials()
  {
    return credentials;
  }
  
  public void setCredentials(Credentials credentials)
  {
    this.credentials = credentials;
  }
  
  public AuthScope getAuthScope()
  {
    return authScope;
  }
  
  public void setAuthScope(AuthScope authScope)
  {
    this.authScope = authScope;
  }
  
  public String toString()
  {
    StringBuilder buffer = new StringBuilder();
    buffer.append("auth scope [");
    buffer.append(authScope);
    buffer.append("]; credentials set [");
    buffer.append(credentials != null ? "true" : "false");
    buffer.append("]");
    return buffer.toString();
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.AuthState
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import org.apache.http.ProtocolException;
import org.apache.http.annotation.Immutable;

@Immutable
public class AuthenticationException
  extends ProtocolException
{
  private static final long serialVersionUID = -6794031905674764776L;
  
  public AuthenticationException() {}
  
  public AuthenticationException(String message)
  {
    super(message);
  }
  
  public AuthenticationException(String message, Throwable cause)
  {
    super(message, cause);
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.AuthenticationException
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import java.io.Serializable;
import java.security.Principal;
import org.apache.http.annotation.Immutable;
import org.apache.http.util.LangUtils;

@Immutable
public final class BasicUserPrincipal
  implements Principal, Serializable
{
  private static final long serialVersionUID = -2266305184969850467L;
  private final String username;
  
  public BasicUserPrincipal(String username)
  {
    if (username == null) {
      throw new IllegalArgumentException("User name may not be null");
    }
    this.username = username;
  }
  
  public String getName()
  {
    return username;
  }
  
  public int hashCode()
  {
    int hash = 17;
    hash = LangUtils.hashCode(hash, username);
    return hash;
  }
  
  public boolean equals(Object o)
  {
    if (this == o) {
      return true;
    }
    if ((o instanceof BasicUserPrincipal))
    {
      BasicUserPrincipal that = (BasicUserPrincipal)o;
      if (LangUtils.equals(username, username)) {
        return true;
      }
    }
    return false;
  }
  
  public String toString()
  {
    StringBuilder buffer = new StringBuilder();
    buffer.append("[principal: ");
    buffer.append(username);
    buffer.append("]");
    return buffer.toString();
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.BasicUserPrincipal
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import org.apache.http.Header;
import org.apache.http.HttpRequest;
import org.apache.http.protocol.HttpContext;

public abstract interface ContextAwareAuthScheme
  extends AuthScheme
{
  public abstract Header authenticate(Credentials paramCredentials, HttpRequest paramHttpRequest, HttpContext paramHttpContext)
    throws AuthenticationException;
}

/* Location:
 * Qualified Name:     org.apache.http.auth.ContextAwareAuthScheme
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import java.security.Principal;

public abstract interface Credentials
{
  public abstract Principal getUserPrincipal();
  
  public abstract String getPassword();
}

/* Location:
 * Qualified Name:     org.apache.http.auth.Credentials
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import org.apache.http.annotation.Immutable;

@Immutable
public class InvalidCredentialsException
  extends AuthenticationException
{
  private static final long serialVersionUID = -4834003835215460648L;
  
  public InvalidCredentialsException() {}
  
  public InvalidCredentialsException(String message)
  {
    super(message);
  }
  
  public InvalidCredentialsException(String message, Throwable cause)
  {
    super(message, cause);
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.InvalidCredentialsException
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import org.apache.http.ProtocolException;
import org.apache.http.annotation.Immutable;

@Immutable
public class MalformedChallengeException
  extends ProtocolException
{
  private static final long serialVersionUID = 814586927989932284L;
  
  public MalformedChallengeException() {}
  
  public MalformedChallengeException(String message)
  {
    super(message);
  }
  
  public MalformedChallengeException(String message, Throwable cause)
  {
    super(message, cause);
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.MalformedChallengeException
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import java.io.Serializable;
import java.security.Principal;
import java.util.Locale;
import org.apache.http.annotation.Immutable;
import org.apache.http.util.LangUtils;

@Immutable
public class NTCredentials
  implements Credentials, Serializable
{
  private static final long serialVersionUID = -7385699315228907265L;
  private final NTUserPrincipal principal;
  private final String password;
  private final String workstation;
  
  public NTCredentials(String usernamePassword)
  {
    if (usernamePassword == null) {
      throw new IllegalArgumentException("Username:password string may not be null");
    }
    int atColon = usernamePassword.indexOf(':');
    String username;
    if (atColon >= 0)
    {
      String username = usernamePassword.substring(0, atColon);
      password = usernamePassword.substring(atColon + 1);
    }
    else
    {
      username = usernamePassword;
      password = null;
    }
    int atSlash = username.indexOf('/');
    if (atSlash >= 0) {
      principal = new NTUserPrincipal(username.substring(0, atSlash).toUpperCase(Locale.ENGLISH), username.substring(atSlash + 1));
    } else {
      principal = new NTUserPrincipal(null, username.substring(atSlash + 1));
    }
    workstation = null;
  }
  
  public NTCredentials(String userName, String password, String workstation, String domain)
  {
    if (userName == null) {
      throw new IllegalArgumentException("User name may not be null");
    }
    principal = new NTUserPrincipal(domain, userName);
    this.password = password;
    if (workstation != null) {
      this.workstation = workstation.toUpperCase(Locale.ENGLISH);
    } else {
      this.workstation = null;
    }
  }
  
  public Principal getUserPrincipal()
  {
    return principal;
  }
  
  public String getUserName()
  {
    return principal.getUsername();
  }
  
  public String getPassword()
  {
    return password;
  }
  
  public String getDomain()
  {
    return principal.getDomain();
  }
  
  public String getWorkstation()
  {
    return workstation;
  }
  
  public int hashCode()
  {
    int hash = 17;
    hash = LangUtils.hashCode(hash, principal);
    hash = LangUtils.hashCode(hash, workstation);
    return hash;
  }
  
  public boolean equals(Object o)
  {
    if (this == o) {
      return true;
    }
    if ((o instanceof NTCredentials))
    {
      NTCredentials that = (NTCredentials)o;
      if ((LangUtils.equals(principal, principal)) && (LangUtils.equals(workstation, workstation))) {
        return true;
      }
    }
    return false;
  }
  
  public String toString()
  {
    StringBuilder buffer = new StringBuilder();
    buffer.append("[principal: ");
    buffer.append(principal);
    buffer.append("][workstation: ");
    buffer.append(workstation);
    buffer.append("]");
    return buffer.toString();
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.NTCredentials
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import java.io.Serializable;
import java.security.Principal;
import java.util.Locale;
import org.apache.http.annotation.Immutable;
import org.apache.http.util.LangUtils;

@Immutable
public class NTUserPrincipal
  implements Principal, Serializable
{
  private static final long serialVersionUID = -6870169797924406894L;
  private final String username;
  private final String domain;
  private final String ntname;
  
  public NTUserPrincipal(String domain, String username)
  {
    if (username == null) {
      throw new IllegalArgumentException("User name may not be null");
    }
    this.username = username;
    if (domain != null) {
      this.domain = domain.toUpperCase(Locale.ENGLISH);
    } else {
      this.domain = null;
    }
    if ((this.domain != null) && (this.domain.length() > 0))
    {
      StringBuilder buffer = new StringBuilder();
      buffer.append(this.domain);
      buffer.append('/');
      buffer.append(this.username);
      ntname = buffer.toString();
    }
    else
    {
      ntname = this.username;
    }
  }
  
  public String getName()
  {
    return ntname;
  }
  
  public String getDomain()
  {
    return domain;
  }
  
  public String getUsername()
  {
    return username;
  }
  
  public int hashCode()
  {
    int hash = 17;
    hash = LangUtils.hashCode(hash, username);
    hash = LangUtils.hashCode(hash, domain);
    return hash;
  }
  
  public boolean equals(Object o)
  {
    if (this == o) {
      return true;
    }
    if ((o instanceof NTUserPrincipal))
    {
      NTUserPrincipal that = (NTUserPrincipal)o;
      if ((LangUtils.equals(username, username)) && (LangUtils.equals(domain, domain))) {
        return true;
      }
    }
    return false;
  }
  
  public String toString()
  {
    return ntname;
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.NTUserPrincipal
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth;

import java.io.Serializable;
import java.security.Principal;
import org.apache.http.annotation.Immutable;
import org.apache.http.util.LangUtils;

@Immutable
public class UsernamePasswordCredentials
  implements Credentials, Serializable
{
  private static final long serialVersionUID = 243343858802739403L;
  private final BasicUserPrincipal principal;
  private final String password;
  
  public UsernamePasswordCredentials(String usernamePassword)
  {
    if (usernamePassword == null) {
      throw new IllegalArgumentException("Username:password string may not be null");
    }
    int atColon = usernamePassword.indexOf(':');
    if (atColon >= 0)
    {
      principal = new BasicUserPrincipal(usernamePassword.substring(0, atColon));
      password = usernamePassword.substring(atColon + 1);
    }
    else
    {
      principal = new BasicUserPrincipal(usernamePassword);
      password = null;
    }
  }
  
  public UsernamePasswordCredentials(String userName, String password)
  {
    if (userName == null) {
      throw new IllegalArgumentException("Username may not be null");
    }
    principal = new BasicUserPrincipal(userName);
    this.password = password;
  }
  
  public Principal getUserPrincipal()
  {
    return principal;
  }
  
  public String getUserName()
  {
    return principal.getName();
  }
  
  public String getPassword()
  {
    return password;
  }
  
  public int hashCode()
  {
    return principal.hashCode();
  }
  
  public boolean equals(Object o)
  {
    if (this == o) {
      return true;
    }
    if ((o instanceof UsernamePasswordCredentials))
    {
      UsernamePasswordCredentials that = (UsernamePasswordCredentials)o;
      if (LangUtils.equals(principal, principal)) {
        return true;
      }
    }
    return false;
  }
  
  public String toString()
  {
    return principal.toString();
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.UsernamePasswordCredentials
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth.params;

public abstract interface AuthPNames
{
  public static final String CREDENTIAL_CHARSET = "http.auth.credential-charset";
  public static final String TARGET_AUTH_PREF = "http.auth.target-scheme-pref";
  public static final String PROXY_AUTH_PREF = "http.auth.proxy-scheme-pref";
}

/* Location:
 * Qualified Name:     org.apache.http.auth.params.AuthPNames
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth.params;

import org.apache.http.params.HttpAbstractParamBean;
import org.apache.http.params.HttpParams;

public class AuthParamBean
  extends HttpAbstractParamBean
{
  public AuthParamBean(HttpParams params)
  {
    super(params);
  }
  
  public void setCredentialCharset(String charset)
  {
    AuthParams.setCredentialCharset(params, charset);
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.params.AuthParamBean
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.auth.params;

import org.apache.http.annotation.Immutable;
import org.apache.http.params.HttpParams;

@Immutable
public final class AuthParams
{
  public static String getCredentialCharset(HttpParams params)
  {
    if (params == null) {
      throw new IllegalArgumentException("HTTP parameters may not be null");
    }
    String charset = (String)params.getParameter("http.auth.credential-charset");
    if (charset == null) {
      charset = "US-ASCII";
    }
    return charset;
  }
  
  public static void setCredentialCharset(HttpParams params, String charset)
  {
    if (params == null) {
      throw new IllegalArgumentException("HTTP parameters may not be null");
    }
    params.setParameter("http.auth.credential-charset", charset);
  }
}

/* Location:
 * Qualified Name:     org.apache.http.auth.params.AuthParams
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import org.apache.http.HttpHost;
import org.apache.http.auth.AuthScheme;

public abstract interface AuthCache
{
  public abstract void put(HttpHost paramHttpHost, AuthScheme paramAuthScheme);
  
  public abstract AuthScheme get(HttpHost paramHttpHost);
  
  public abstract void remove(HttpHost paramHttpHost);
  
  public abstract void clear();
}

/* Location:
 * Qualified Name:     org.apache.http.client.AuthCache
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import java.util.Map;
import org.apache.http.Header;
import org.apache.http.HttpResponse;
import org.apache.http.auth.AuthScheme;
import org.apache.http.auth.AuthenticationException;
import org.apache.http.auth.MalformedChallengeException;
import org.apache.http.protocol.HttpContext;

public abstract interface AuthenticationHandler
{
  public abstract boolean isAuthenticationRequested(HttpResponse paramHttpResponse, HttpContext paramHttpContext);
  
  public abstract Map<String, Header> getChallenges(HttpResponse paramHttpResponse, HttpContext paramHttpContext)
    throws MalformedChallengeException;
  
  public abstract AuthScheme selectScheme(Map<String, Header> paramMap, HttpResponse paramHttpResponse, HttpContext paramHttpContext)
    throws AuthenticationException;
}

/* Location:
 * Qualified Name:     org.apache.http.client.AuthenticationHandler
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import org.apache.http.annotation.Immutable;

@Immutable
public class CircularRedirectException
  extends RedirectException
{
  private static final long serialVersionUID = 6830063487001091803L;
  
  public CircularRedirectException() {}
  
  public CircularRedirectException(String message)
  {
    super(message);
  }
  
  public CircularRedirectException(String message, Throwable cause)
  {
    super(message, cause);
  }
}

/* Location:
 * Qualified Name:     org.apache.http.client.CircularRedirectException
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import java.io.IOException;
import org.apache.http.annotation.Immutable;

@Immutable
public class ClientProtocolException
  extends IOException
{
  private static final long serialVersionUID = -5596590843227115865L;
  
  public ClientProtocolException() {}
  
  public ClientProtocolException(String s)
  {
    super(s);
  }
  
  public ClientProtocolException(Throwable cause)
  {
    initCause(cause);
  }
  
  public ClientProtocolException(String message, Throwable cause)
  {
    super(message);
    initCause(cause);
  }
}

/* Location:
 * Qualified Name:     org.apache.http.client.ClientProtocolException
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import java.util.Date;
import java.util.List;
import org.apache.http.cookie.Cookie;

public abstract interface CookieStore
{
  public abstract void addCookie(Cookie paramCookie);
  
  public abstract List<Cookie> getCookies();
  
  public abstract boolean clearExpired(Date paramDate);
  
  public abstract void clear();
}

/* Location:
 * Qualified Name:     org.apache.http.client.CookieStore
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import org.apache.http.auth.AuthScope;
import org.apache.http.auth.Credentials;

public abstract interface CredentialsProvider
{
  public abstract void setCredentials(AuthScope paramAuthScope, Credentials paramCredentials);
  
  public abstract Credentials getCredentials(AuthScope paramAuthScope);
  
  public abstract void clear();
}

/* Location:
 * Qualified Name:     org.apache.http.client.CredentialsProvider
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import java.io.IOException;
import org.apache.http.HttpHost;
import org.apache.http.HttpRequest;
import org.apache.http.HttpResponse;
import org.apache.http.client.methods.HttpUriRequest;
import org.apache.http.conn.ClientConnectionManager;
import org.apache.http.params.HttpParams;
import org.apache.http.protocol.HttpContext;

public abstract interface HttpClient
{
  public abstract HttpParams getParams();
  
  public abstract ClientConnectionManager getConnectionManager();
  
  public abstract HttpResponse execute(HttpUriRequest paramHttpUriRequest)
    throws IOException, ClientProtocolException;
  
  public abstract HttpResponse execute(HttpUriRequest paramHttpUriRequest, HttpContext paramHttpContext)
    throws IOException, ClientProtocolException;
  
  public abstract HttpResponse execute(HttpHost paramHttpHost, HttpRequest paramHttpRequest)
    throws IOException, ClientProtocolException;
  
  public abstract HttpResponse execute(HttpHost paramHttpHost, HttpRequest paramHttpRequest, HttpContext paramHttpContext)
    throws IOException, ClientProtocolException;
  
  public abstract <T> T execute(HttpUriRequest paramHttpUriRequest, ResponseHandler<? extends T> paramResponseHandler)
    throws IOException, ClientProtocolException;
  
  public abstract <T> T execute(HttpUriRequest paramHttpUriRequest, ResponseHandler<? extends T> paramResponseHandler, HttpContext paramHttpContext)
    throws IOException, ClientProtocolException;
  
  public abstract <T> T execute(HttpHost paramHttpHost, HttpRequest paramHttpRequest, ResponseHandler<? extends T> paramResponseHandler)
    throws IOException, ClientProtocolException;
  
  public abstract <T> T execute(HttpHost paramHttpHost, HttpRequest paramHttpRequest, ResponseHandler<? extends T> paramResponseHandler, HttpContext paramHttpContext)
    throws IOException, ClientProtocolException;
}

/* Location:
 * Qualified Name:     org.apache.http.client.HttpClient
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import java.io.IOException;
import org.apache.http.protocol.HttpContext;

public abstract interface HttpRequestRetryHandler
{
  public abstract boolean retryRequest(IOException paramIOException, int paramInt, HttpContext paramHttpContext);
}

/* Location:
 * Qualified Name:     org.apache.http.client.HttpRequestRetryHandler
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import org.apache.http.annotation.Immutable;

@Immutable
public class HttpResponseException
  extends ClientProtocolException
{
  private static final long serialVersionUID = -7186627969477257933L;
  private final int statusCode;
  
  public HttpResponseException(int statusCode, String s)
  {
    super(s);
    this.statusCode = statusCode;
  }
  
  public int getStatusCode()
  {
    return statusCode;
  }
}

/* Location:
 * Qualified Name:     org.apache.http.client.HttpResponseException
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import org.apache.http.ProtocolException;
import org.apache.http.annotation.Immutable;

@Immutable
public class NonRepeatableRequestException
  extends ProtocolException
{
  private static final long serialVersionUID = 82685265288806048L;
  
  public NonRepeatableRequestException() {}
  
  public NonRepeatableRequestException(String message)
  {
    super(message);
  }
  
  public NonRepeatableRequestException(String message, Throwable cause)
  {
    super(message, cause);
  }
}

/* Location:
 * Qualified Name:     org.apache.http.client.NonRepeatableRequestException
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import org.apache.http.ProtocolException;
import org.apache.http.annotation.Immutable;

@Immutable
public class RedirectException
  extends ProtocolException
{
  private static final long serialVersionUID = 4418824536372559326L;
  
  public RedirectException() {}
  
  public RedirectException(String message)
  {
    super(message);
  }
  
  public RedirectException(String message, Throwable cause)
  {
    super(message, cause);
  }
}

/* Location:
 * Qualified Name:     org.apache.http.client.RedirectException
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import java.net.URI;
import org.apache.http.HttpResponse;
import org.apache.http.ProtocolException;
import org.apache.http.protocol.HttpContext;

@Deprecated
public abstract interface RedirectHandler
{
  public abstract boolean isRedirectRequested(HttpResponse paramHttpResponse, HttpContext paramHttpContext);
  
  public abstract URI getLocationURI(HttpResponse paramHttpResponse, HttpContext paramHttpContext)
    throws ProtocolException;
}

/* Location:
 * Qualified Name:     org.apache.http.client.RedirectHandler
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import org.apache.http.HttpRequest;
import org.apache.http.HttpResponse;
import org.apache.http.ProtocolException;
import org.apache.http.client.methods.HttpUriRequest;
import org.apache.http.protocol.HttpContext;

public abstract interface RedirectStrategy
{
  public abstract boolean isRedirected(HttpRequest paramHttpRequest, HttpResponse paramHttpResponse, HttpContext paramHttpContext)
    throws ProtocolException;
  
  public abstract HttpUriRequest getRedirect(HttpRequest paramHttpRequest, HttpResponse paramHttpResponse, HttpContext paramHttpContext)
    throws ProtocolException;
}

/* Location:
 * Qualified Name:     org.apache.http.client.RedirectStrategy
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import java.io.IOException;
import org.apache.http.HttpException;
import org.apache.http.HttpHost;
import org.apache.http.HttpRequest;
import org.apache.http.HttpResponse;
import org.apache.http.protocol.HttpContext;

public abstract interface RequestDirector
{
  public abstract HttpResponse execute(HttpHost paramHttpHost, HttpRequest paramHttpRequest, HttpContext paramHttpContext)
    throws HttpException, IOException;
}

/* Location:
 * Qualified Name:     org.apache.http.client.RequestDirector
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import java.io.IOException;
import org.apache.http.HttpResponse;

public abstract interface ResponseHandler<T>
{
  public abstract T handleResponse(HttpResponse paramHttpResponse)
    throws ClientProtocolException, IOException;
}

/* Location:
 * Qualified Name:     org.apache.http.client.ResponseHandler
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client;

import org.apache.http.protocol.HttpContext;

public abstract interface UserTokenHandler
{
  public abstract Object getUserToken(HttpContext paramHttpContext);
}

/* Location:
 * Qualified Name:     org.apache.http.client.UserTokenHandler
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client.cache;

public enum CacheResponseStatus
{
  CACHE_MODULE_RESPONSE,  CACHE_HIT,  CACHE_MISS,  VALIDATED;
  
  private CacheResponseStatus() {}
}

/* Location:
 * Qualified Name:     org.apache.http.client.cache.CacheResponseStatus
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client.cache;

import org.apache.http.annotation.Immutable;

@Immutable
public class HeaderConstants
{
  public static final String GET_METHOD = "GET";
  public static final String HEAD_METHOD = "HEAD";
  public static final String OPTIONS_METHOD = "OPTIONS";
  public static final String PUT_METHOD = "PUT";
  public static final String DELETE_METHOD = "DELETE";
  public static final String TRACE_METHOD = "TRACE";
  public static final String LAST_MODIFIED = "Last-Modified";
  public static final String IF_MATCH = "If-Match";
  public static final String IF_RANGE = "If-Range";
  public static final String IF_UNMODIFIED_SINCE = "If-Unmodified-Since";
  public static final String IF_MODIFIED_SINCE = "If-Modified-Since";
  public static final String IF_NONE_MATCH = "If-None-Match";
  public static final String PRAGMA = "Pragma";
  public static final String MAX_FORWARDS = "Max-Forwards";
  public static final String ETAG = "ETag";
  public static final String EXPIRES = "Expires";
  public static final String AGE = "Age";
  public static final String VARY = "Vary";
  public static final String ALLOW = "Allow";
  public static final String CACHE_CONTROL = "Cache-Control";
  public static final String CACHE_CONTROL_NO_STORE = "no-store";
  public static final String CACHE_CONTROL_NO_CACHE = "no-cache";
  public static final String CACHE_CONTROL_MAX_AGE = "max-age";
  public static final String CACHE_CONTROL_MAX_STALE = "max-stale";
  public static final String CACHE_CONTROL_MIN_FRESH = "min-fresh";
  public static final String CACHE_CONTROL_MUST_REVALIDATE = "must-revalidate";
  public static final String CACHE_CONTROL_PROXY_REVALIDATE = "proxy-revalidate";
  public static final String WARNING = "Warning";
  public static final String RANGE = "Range";
  public static final String CONTENT_RANGE = "Content-Range";
  public static final String WWW_AUTHENTICATE = "WWW-Authenticate";
  public static final String PROXY_AUTHENTICATE = "Proxy-Authenticate";
}

/* Location:
 * Qualified Name:     org.apache.http.client.cache.HeaderConstants
 * Java Class Version: 5 (49.0)
 * JD-Core Version:    0.7.1
 */
package org.apache.http.client.cache;

import java.io.Serializable;
import java.util.Collections;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
import org.apache.http.Header;
import org.apache.http.ProtocolVersion;
import org.apache.http.StatusLine;
import org.apache.http.annotation.Immutable;
import org.apache.http.message.HeaderGroup;

@Immutable
public class HttpCacheEntry
  implements Serializable
{
  private static final long serialVersionUID = -6300496422359477413L;
  private final Date requestDate;
  private final Date responseDate;
  private final StatusLine statusLine;
  private final HeaderGroup responseHeaders;
  private final Resource resource;
  private final Map<String, String> variantMap;
  
  public HttpCacheEntry(Date requestDate, Date responseDate, StatusLine statusLine, Header[] responseHeaders, Resource resource, Map<String, String> variantMap)
  {
    if (requestDate == null) {
      throw new IllegalArgumentException("Request date may not be null");
    }
    if (responseDate == null) {
      throw new IllegalArgumentException("Response date may not be null");
    }
    if (statusLine == null) {
      throw new IllegalArgumentException("Status line may not be null");
    }
    if (responseHeaders == null) {
      throw new IllegalArgumentException("Response headers may not be null");
    }
    if (resource == null) {
      throw new IllegalArgumentException("Resource may not be null");
    }
    this.requestDate = requestDate;
    this.responseDate = responseDate;
    this.statusLine = statusLine;
    this.responseHeaders = new HeaderGroup();
    this.responseHeaders.setHeaders(responseHeaders);
    this.resource = resource;
    this.variantMap = (variantMap != null ? new HashMap(variantMap) : null);
  }
  
  public HttpCacheEntry(Date requestDate, Date responseDate, StatusLine statusLine, Header[] responseHeaders, Resource resource)
  {
    this(requestDate, responseDate, statusLine, responseHeaders, resource, new HashMap());
  }
  
  public StatusLine getStatusLine()
  {
    return statusLine;
  }
  
  public ProtocolVersion getProtocolVersion()
  {
    return statusLine.getProtocolVersion();
  }
  
  public String getReasonPhrase()
  {
    return statusLine.getReasonPhrase();
  }
  
  public int getStatusCode()
  {
    return statusLine.getStatusCode();
  }
  
  public Date getRequestDate()
  {
    return requestDate;
  }
  
  public Date getResponseDate()
  {
    return responseDate;
  }
  
  public Header[] getAllHeaders()
  {
    return responseHeaders.getAllHeaders();
  }
  
  public Header getFirstHeader(String name)
  {
    return responseHeaders.getFirstHeader(name);
  }
  
  public Header[] getHeaders(String name)
  {
    return responseHeaders.getHeaders(name);
  }
  
  public Resource getResource()
  {
   
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20

Further reading...

For more information on Java 1.5 Tiger, you may find Java 1.5 Tiger, A developer's Notebook by D. Flanagan and B. McLaughlin from O'Reilly of interest.

New!JAR listings


Copyright 2006-2017. Infinite Loop Ltd