Build 1.0_r1

org.apache.http.params
Class AbstractHttpParams

java.lang.Object
  extended by org.apache.http.params.AbstractHttpParams
All Implemented Interfaces:
HttpParams
Direct Known Subclasses:
BasicHttpParams, ClientParamsStack, DefaultedHttpParams

public abstract class AbstractHttpParams
extends Object
implements HttpParams

Abstract base class for parameter collections. Type specific setters and getters are mapped to the abstract, generic getters and setters.


Constructor Summary
protected AbstractHttpParams()
          Instantiates parameters.
 
Method Summary
 boolean getBooleanParameter(String name, boolean defaultValue)
          Returns a Boolean parameter value with the given name.
 double getDoubleParameter(String name, double defaultValue)
          Returns a Double parameter value with the given name.
 int getIntParameter(String name, int defaultValue)
          Returns an Integer parameter value with the given name.
 long getLongParameter(String name, long defaultValue)
          Returns a Long parameter value with the given name.
 boolean isParameterFalse(String name)
          Checks if a boolean parameter is not set or false.
 boolean isParameterTrue(String name)
          Checks if a boolean parameter is set to true.
 HttpParams setBooleanParameter(String name, boolean value)
          Assigns a Boolean to the parameter with the given name
 HttpParams setDoubleParameter(String name, double value)
          Assigns a Double to the parameter with the given name
 HttpParams setIntParameter(String name, int value)
          Assigns an Integer to the parameter with the given name
 HttpParams setLongParameter(String name, long value)
          Assigns a Long to the parameter with the given name
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.http.params.HttpParams
copy, getParameter, removeParameter, setParameter
 

Constructor Detail

AbstractHttpParams

protected AbstractHttpParams()
Instantiates parameters.

Method Detail

getLongParameter

public long getLongParameter(String name,
                             long defaultValue)
Returns a Long parameter value with the given name. If the parameter is not explicitly set, the default value is returned.

Specified by:
getLongParameter in interface HttpParams

setLongParameter

public HttpParams setLongParameter(String name,
                                   long value)
Assigns a Long to the parameter with the given name

Specified by:
setLongParameter in interface HttpParams

getIntParameter

public int getIntParameter(String name,
                           int defaultValue)
Returns an Integer parameter value with the given name. If the parameter is not explicitly set, the default value is returned.

Specified by:
getIntParameter in interface HttpParams

setIntParameter

public HttpParams setIntParameter(String name,
                                  int value)
Assigns an Integer to the parameter with the given name

Specified by:
setIntParameter in interface HttpParams

getDoubleParameter

public double getDoubleParameter(String name,
                                 double defaultValue)
Returns a Double parameter value with the given name. If the parameter is not explicitly set, the default value is returned.

Specified by:
getDoubleParameter in interface HttpParams

setDoubleParameter

public HttpParams setDoubleParameter(String name,
                                     double value)
Assigns a Double to the parameter with the given name

Specified by:
setDoubleParameter in interface HttpParams

getBooleanParameter

public boolean getBooleanParameter(String name,
                                   boolean defaultValue)
Returns a Boolean parameter value with the given name. If the parameter is not explicitly set, the default value is returned.

Specified by:
getBooleanParameter in interface HttpParams

setBooleanParameter

public HttpParams setBooleanParameter(String name,
                                      boolean value)
Assigns a Boolean to the parameter with the given name

Specified by:
setBooleanParameter in interface HttpParams

isParameterTrue

public boolean isParameterTrue(String name)
Checks if a boolean parameter is set to true.

Specified by:
isParameterTrue in interface HttpParams

isParameterFalse

public boolean isParameterFalse(String name)
Checks if a boolean parameter is not set or false.

Specified by:
isParameterFalse in interface HttpParams

Build 1.0_r1

Please submit a feedback, bug or feature