|
Android 2.3 Gingerbread | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.Dictionary<K,V>
java.util.Hashtable<Object,Object>
java.util.Properties
java.security.Provider
public abstract class Provider
Provider is the abstract superclass for all security providers in the
Java security infrastructure.
| Nested Class Summary | |
|---|---|
static class |
Provider.Service
Service represents a service in the Java Security infrastructure. |
| Nested classes/interfaces inherited from interface java.util.Map |
|---|
Map.Entry<K,V> |
| Field Summary |
|---|
| Fields inherited from class java.util.Properties |
|---|
defaults |
| Constructor Summary | |
|---|---|
protected |
Provider(String name,
double version,
String info)
Constructs a new instance of Provider with its name, version and
description. |
| Method Summary | |
|---|---|
void |
clear()
Clears all properties used to look up services implemented by this Provider. |
Set<Map.Entry<Object,Object>> |
entrySet()
Returns a set of the mappings contained in this Hashtable. |
String |
getInfo()
Returns a description of the services being provided. |
String |
getName()
Returns the name of this provider. |
(package private) int |
getProviderNumber()
Get the provider preference order number. |
(package private) Provider.Service |
getService(String type)
Get the service of the specified type |
Provider.Service |
getService(String type,
String algorithm)
Returns the service with the specified type implementing the
specified algorithm, or null if no such implementation
exists. |
Set<Provider.Service> |
getServices()
Returns an unmodifiable Set of all services registered by this
provider. |
double |
getVersion()
Returns the version number for the services being provided. |
(package private) boolean |
implementsAlg(String serv,
String alg,
String attribute,
String val)
Returns true if this provider implements the given algorithm. |
Set<Object> |
keySet()
Returns a set of the keys contained in this Hashtable. |
void |
load(InputStream inStream)
Loads properties from the specified InputStream. |
Object |
put(Object key,
Object value)
Maps the specified key property name to the specified value. |
void |
putAll(Map<?,?> t)
Copies all from the provided map to this Provider. |
protected void |
putService(Provider.Service s)
Adds a Service to this Provider. |
Object |
remove(Object key)
Removes the specified key and its associated value from this
Provider. |
protected void |
removeService(Provider.Service s)
Removes a previously registered Service from this Provider. |
(package private) void |
setProviderNumber(int n)
Set the provider preference order number. |
String |
toString()
Returns a string containing a concise, human-readable description of this Provider including its name and its version. |
Collection<Object> |
values()
Returns a collection of the values contained in this Hashtable. |
| Methods inherited from class java.util.Properties |
|---|
getProperty, getProperty, list, list, load, loadFromXML, propertyNames, save, setProperty, store, store, storeToXML, storeToXML, stringPropertyNames |
| Methods inherited from class java.util.Hashtable |
|---|
clone, contains, containsKey, containsValue, elements, equals, get, hashCode, isEmpty, keys, rehash, size |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
protected Provider(String name,
double version,
String info)
Provider with its name, version and
description.
name - the name of the provider.version - the version of the provider.info - a description of the provider.| Method Detail |
|---|
public String getName()
public double getVersion()
public String getInfo()
public String toString()
Provider including its name and its version.
toString in class Hashtable<Object,Object>Provider.public void clear()
Provider.
If a SecurityManager is installed, code calling this method needs
the SecurityPermission clearProviderProperties.NAME
(where NAME is the provider name) to be granted, otherwise a SecurityException will be thrown.
clear in interface Map<Object,Object>clear in class Hashtable<Object,Object>SecurityException - if a SecurityManager is installed and the caller does
not have permission to invoke this method.Hashtable.isEmpty(),
Hashtable.size
public void load(InputStream inStream)
throws IOException
PropertiesInputStream. The encoding is
ISO-8859-1.
load in class PropertiesinStream - the InputStream
IOExceptionpublic void putAll(Map<?,?> t)
Provider.
If a SecurityManager is installed, code calling this method needs
the SecurityPermission putProviderProperty.NAME (where
NAME is the provider name) to be granted, otherwise a SecurityException will be thrown.
putAll in interface Map<Object,Object>putAll in class Hashtable<Object,Object>t - the mappings to copy to this provider.
SecurityException - if a SecurityManager is installed and the caller does
not have permission to invoke this method.public Set<Map.Entry<Object,Object>> entrySet()
HashtableHashtable. Each
element in the set is a Map.Entry. The set is backed by this
Hashtable so changes to one are reflected by the other. The set
does not support adding.
entrySet in interface Map<Object,Object>entrySet in class Hashtable<Object,Object>public Set<Object> keySet()
HashtableHashtable. The set
is backed by this Hashtable so changes to one are reflected by
the other. The set does not support adding.
keySet in interface Map<Object,Object>keySet in class Hashtable<Object,Object>public Collection<Object> values()
HashtableHashtable.
The collection is backed by this Hashtable so changes to one are
reflected by the other. The collection does not support adding.
values in interface Map<Object,Object>values in class Hashtable<Object,Object>
public Object put(Object key,
Object value)
key property name to the specified value.
If a SecurityManager is installed, code calling this method needs
the SecurityPermission putProviderProperty.NAME (where
NAME is the provider name) to be granted, otherwise a SecurityException will be thrown.
put in interface Map<Object,Object>put in class Hashtable<Object,Object>key - the name of the property.value - the value of the property.
key
,or null if it did not have one.
SecurityException - if a SecurityManager is installed and the caller does
not have permission to invoke this method.Hashtable.elements(),
Hashtable.get(java.lang.Object),
Hashtable.keys(),
Object.equals(java.lang.Object)public Object remove(Object key)
key and its associated value from this
Provider.
If a SecurityManager is installed, code calling this method needs
the SecurityPermission removeProviderProperty.NAME (where
NAME is the provider name) to be granted, otherwise a SecurityException will be thrown.
remove in interface Map<Object,Object>remove in class Hashtable<Object,Object>key - the name of the property
key ,or
null if no mapping was present
SecurityException - if a SecurityManager is installed and the caller does
not have the permission to invoke this method.Hashtable.get(java.lang.Object),
Hashtable.put(K, V)
boolean implementsAlg(String serv,
String alg,
String attribute,
String val)
serv - Crypto service.alg - Algorithm or type.attribute - The attribute name or null.val - The attribute value.
void setProviderNumber(int n)
n - int getProviderNumber()
Provider.Service getService(String type)
public Provider.Service getService(String type,
String algorithm)
type implementing the
specified algorithm, or null if no such implementation
exists.
If two services match the requested type and algorithm, the one added
with the putService(Service) is returned (as opposed to the one
added via put(Object, Object).
type - the type of the service (for example KeyPairGenerator)algorithm - the algorithm name (case insensitive)
null if no such implementation
existspublic Set<Provider.Service> getServices()
Set of all services registered by this
provider.
Set of all services registered by this
providerprotected void putService(Provider.Service s)
Service to this Provider. If a service with the
same name was registered via this method, it is replace.
If a SecurityManager is installed, code calling this method needs
the SecurityPermission putProviderProperty.NAME (where
NAME is the provider name) to be granted, otherwise a SecurityException will be thrown.
s - the Service to register
SecurityException - if a SecurityManager is installed and the caller does
not have permission to invoke this methodprotected void removeService(Provider.Service s)
Service from this Provider.
If a SecurityManager is installed, code calling this method needs
the SecurityPermission removeProviderProperty.NAME (where
NAME is the provider name) to be granted, otherwise a SecurityException will be thrown.
s - the Service to remove
SecurityException - if a SecurityManager is installed and the caller does
not have permission to invoke this method
NullPointerException - if s is null
|
Android 2.3 Gingerbread | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||