|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.http.auth.AuthScope
@Immutable public class AuthScope
The class represents an authentication scope consisting of a host name,
a port number, a realm name and an authentication scheme name which
Credentials
apply to.
Field Summary | |
---|---|
static AuthScope |
ANY
Default scope matching any host, port, realm and authentication scheme. |
static java.lang.String |
ANY_HOST
The null value represents any host. |
static int |
ANY_PORT
The -1 value represents any port. |
static java.lang.String |
ANY_REALM
The null value represents any realm. |
static java.lang.String |
ANY_SCHEME
The null value represents any authentication scheme. |
Constructor Summary | |
---|---|
AuthScope(AuthScope authscope)
Creates a copy of the given credentials scope. |
|
AuthScope(java.lang.String host,
int port)
Creates a new credentials scope for the given host, port, any realm name, and any authentication scheme. |
|
AuthScope(java.lang.String host,
int port,
java.lang.String realm)
Creates a new credentials scope for the given host, port, realm, and any authentication scheme. |
|
AuthScope(java.lang.String host,
int port,
java.lang.String realm,
java.lang.String scheme)
Creates a new credentials scope for the given host, port, realm, and authentication scheme. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object o)
|
java.lang.String |
getHost()
|
int |
getPort()
|
java.lang.String |
getRealm()
|
java.lang.String |
getScheme()
|
int |
hashCode()
|
int |
match(AuthScope that)
Tests if the authentication scopes match. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String ANY_HOST
public static final int ANY_PORT
public static final java.lang.String ANY_REALM
public static final java.lang.String ANY_SCHEME
public static final AuthScope ANY
Constructor Detail |
---|
public AuthScope(java.lang.String host, int port, java.lang.String realm, java.lang.String scheme)
host
- the host the credentials apply to. May be set
to null if credentials are applicable to
any host.port
- the port the credentials apply to. May be set
to negative value if credentials are applicable to
any port.realm
- the realm the credentials apply to. May be set
to null if credentials are applicable to
any realm.scheme
- the authentication scheme the credentials apply to.
May be set to null if credentials are applicable to
any authentication scheme.public AuthScope(java.lang.String host, int port, java.lang.String realm)
host
- the host the credentials apply to. May be set
to null if credentials are applicable to
any host.port
- the port the credentials apply to. May be set
to negative value if credentials are applicable to
any port.realm
- the realm the credentials apply to. May be set
to null if credentials are applicable to
any realm.public AuthScope(java.lang.String host, int port)
host
- the host the credentials apply to. May be set
to null if credentials are applicable to
any host.port
- the port the credentials apply to. May be set
to negative value if credentials are applicable to
any port.public AuthScope(AuthScope authscope)
Method Detail |
---|
public java.lang.String getHost()
public int getPort()
public java.lang.String getRealm()
public java.lang.String getScheme()
public int match(AuthScope that)
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
Object.equals(Object)
public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public int hashCode()
hashCode
in class java.lang.Object
Object.hashCode()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |