Registry
@Contract(threading=SAFE) @Deprecated public final class SchemeRegistry extends Object
Scheme
s.
Schemes are identified by lowercase names.Constructor and Description |
---|
SchemeRegistry()
Deprecated.
Creates a new, empty scheme registry.
|
Modifier and Type | Method and Description |
---|---|
Scheme |
get(String name)
Deprecated.
Obtains a scheme by name, if registered.
|
Scheme |
getScheme(org.apache.http.HttpHost host)
Deprecated.
Obtains the scheme for a host.
|
Scheme |
getScheme(String name)
Deprecated.
Obtains a scheme by name.
|
List<String> |
getSchemeNames()
Deprecated.
Obtains the names of the registered schemes.
|
Scheme |
register(Scheme sch)
Deprecated.
Registers a scheme.
|
void |
setItems(Map<String,Scheme> map)
Deprecated.
Populates the internal collection of registered
protocol schemes
with the content of the map passed as a parameter. |
Scheme |
unregister(String name)
Deprecated.
Unregisters a scheme.
|
public SchemeRegistry()
public Scheme getScheme(String name)
name
- the name of the scheme to look up (in lowercase)null
IllegalStateException
- if the scheme with the given name is not registeredpublic Scheme getScheme(org.apache.http.HttpHost host)
getScheme(host.getSchemeName())
host
- the host for which to obtain the schemenull
IllegalStateException
- if a scheme with the respective name is not registeredpublic Scheme get(String name)
name
- the name of the scheme to look up (in lowercase)null
if there is none by this namepublic Scheme register(Scheme sch)
sch
- the scheme to registernull
if none was registeredpublic Scheme unregister(String name)
name
- the name of the scheme to unregister (in lowercase)null
if there was nonepublic List<String> getSchemeNames()
public void setItems(Map<String,Scheme> map)
protocol schemes
with the content of the map passed as a parameter.map
- protocol schemesCopyright © 1999–2022 The Apache Software Foundation. All rights reserved.