Deprecated
for removal since 1.2.
This class is deprecated and subject to removal in a future
version of Java SE. It has been replaced by
java.security.KeyStore
, the java.security.cert
package,
and java.security.Principal
.
This class represents a scope for identities. It is an Identity itself, and therefore has a name and can have a scope. It can also optionally have a public key and associated certificates.
An IdentityScope
can contain Identity
objects of all
kinds, including signers. All types of Identity
objects can be
retrieved, added, and removed using the same methods. Note that it is
possible, and in fact expected, that different types of identity scopes will
apply different policies for their various operations on the
various types of Identities.
There is a one-to-one mapping between keys and identities, and there can only be one copy of one key per scope. For example, suppose Acme Software, Inc is a software publisher known to a user. Suppose it is an Identity, that is, it has a public key, and a set of associated certificates. It is named in the scope using the name "Acme Software". No other named Identity in the scope has the same public key. Of course, none has the same name as well.
Identity
, Signer
, Principal
, Key
Modifier and Type | Field and Description |
---|---|
private static IdentityScope | scope
Hides java.
References Deprecated
IdentityScope is deprecated or references (maybe indirectly) at least one deprecated element.
|
private static final long |
Access | Constructor and Description |
---|---|
protected | IdentityScope()
This constructor is used for serialization only and should not be used by subclasses. |
public | |
public | IdentityScope(String
the scope name. name, IdentityScope the scope for the new identity scope. scope)
References Deprecated
IdentityScope is deprecated or references (maybe indirectly) at least one deprecated element.
Constructs a new identity scope with the specified name and scope. |
Modifier and Type | Method and Description |
---|---|
public abstract void | addIdentity(Identity
the identity)Identity to be added.
References Deprecated
Identity is deprecated or references (maybe indirectly) at least one deprecated element.
Adds an |
private static void | |
public abstract Identity | Returns: theIdentity named name , or null
if there are no identities named name in this scope.the name of the name)Identity to be retrieved.
References Deprecated
Identity is deprecated or references (maybe indirectly) at least one deprecated element.
Returns the |
public Identity | Returns: theIdentity whose name is the same as that of the
principal, or null if there are no identities of the same name
in this scope.the principal corresponding to the principal)Identity
to be retrieved.
References Deprecated
Identity is deprecated or references (maybe indirectly) at least one deprecated element.
Retrieves the |
public abstract Identity | Returns: the identity with the given key, ornull if there are
no identities in this scope with that key.the public key for the identity to be returned. key)
References Deprecated
Identity is deprecated or references (maybe indirectly) at least one deprecated element.
Retrieves the |
public static IdentityScope | Returns: the system's identity scope, ornull if none has been
set.
References Deprecated
IdentityScope is deprecated or references (maybe indirectly) at least one deprecated element.
Returns the system's identity scope. |
public abstract Enumeration | Returns: an enumeration of all identities in this identity scope.Returns an enumeration of all identities in this identity scope. |
private static void | |
public abstract void | removeIdentity(Identity
the identity)Identity to be removed.
References Deprecated
Identity is deprecated or references (maybe indirectly) at least one deprecated element.
Removes an |
protected static void | setSystemScope(IdentityScope
the scope to set. scope)
References Deprecated
IdentityScope is deprecated or references (maybe indirectly) at least one deprecated element.
Sets the system's identity scope. |
public abstract int | Returns: the number of identities within this identity scope.Returns the number of identities within this identity scope. |
public String | Returns: a string representation of this identity scope.Overrides java. Implements java. Returns a string representation of this identity scope, including its name, its scope name, and the number of identities in this identity scope. |
scope | back to summary |
---|---|
private static IdentityScope scope Hides java. References Deprecated
See corresponding docs for further information. |
serialVersionUID | back to summary |
---|---|
private static final long serialVersionUID Hides java. |
IdentityScope | back to summary |
---|---|
protected IdentityScope() This constructor is used for serialization only and should not be used by subclasses. |
IdentityScope | back to summary |
---|---|
public IdentityScope(String name) Constructs a new identity scope with the specified name.
|
IdentityScope | back to summary |
---|---|
public IdentityScope(String name, IdentityScope scope) throws KeyManagementException
References Deprecated
See corresponding docs for further information. Constructs a new identity scope with the specified name and scope.
|
addIdentity | back to summary |
---|---|
public abstract void addIdentity(Identity identity) throws KeyManagementException
References Deprecated
See corresponding docs for further information. Adds an
|
check | back to summary |
---|---|
private static void check(String directive) Hides java. |
getIdentity | back to summary |
---|---|
public abstract Identity getIdentity(String name)
References Deprecated
See corresponding docs for further information. Returns the |
getIdentity | back to summary |
---|---|
public Identity getIdentity(Principal principal)
References Deprecated
See corresponding docs for further information. Retrieves the |
getIdentity | back to summary |
---|---|
public abstract Identity getIdentity(PublicKey key)
References Deprecated
See corresponding docs for further information. Retrieves the |
getSystemScope | back to summary |
---|---|
public static IdentityScope getSystemScope()
References Deprecated
See corresponding docs for further information. Returns the system's identity scope.
|
identities | back to summary |
---|---|
public abstract Enumeration Returns an enumeration of all identities in this identity scope.
|
initializeSystemScope | back to summary |
---|---|
private static void initializeSystemScope() |
removeIdentity | back to summary |
---|---|
public abstract void removeIdentity(Identity identity) throws KeyManagementException
References Deprecated
See corresponding docs for further information. Removes an
|
setSystemScope | back to summary |
---|---|
protected static void setSystemScope(IdentityScope scope)
References Deprecated
See corresponding docs for further information. Sets the system's identity scope. First, if there is a security manager, its
|
size | back to summary |
---|---|
public abstract int size() Returns the number of identities within this identity scope.
|
toString | back to summary |
---|---|
public String toString() Overrides java. Implements java. Returns a string representation of this identity scope, including its name, its scope name, and the number of identities in this identity scope.
|