This class is deprecated.
The functionality of this class has been replace by
Principal
, KeyStore
and the java.security.cert
package.
Class Overview
IdentityScope
represents a scope for Identity
objects.
Summary
Protected Constructors |
|
IdentityScope()
Constructs a new instance of IdentityScope .
|
Public Methods |
abstract
void
|
addIdentity(Identity identity)
Adds an Identity to this IdentityScope .
|
abstract
Identity
|
getIdentity(String name)
Returns the Identity with the specified name or null if
no Identity with the specified name is present in this scope.
|
abstract
Identity
|
getIdentity(PublicKey key)
Returns the Identity which is associated with the specified key
or null if no Identity associated with the specified key
is present in this scope.
|
Identity
|
getIdentity(Principal principal)
Returns the Identity with the name of the specified principal or
null if no Identity with the name of the specified
principal is present in this scope.
|
static
IdentityScope
|
getSystemScope()
Returns the system's scope.
|
abstract
Enumeration<Identity>
|
identities()
Returns an Enumeration over the Identity objects in this
IdentityScope .
|
abstract
void
|
removeIdentity(Identity identity)
Removes an Identity from this IdentityScope .
|
abstract
int
|
size()
Returns the number of Identity objects in this scope.
|
String
|
toString()
Returns a string containing a concise, human-readable description of this
IdentityScope .
|
[Expand]
Inherited Methods |
From class
java.security.Identity
void
|
addCertificate(Certificate certificate)
Adds a Certificate to this Identity .
|
Certificate[]
|
certificates()
Returns the certificates for this Identity .
|
final
boolean
|
equals(Object obj)
Compares the specified object with this Identity for equality and
returns true if the specified object is equal, false
otherwise.
|
String
|
getInfo()
Returns the information string of this Identity .
|
final
String
|
getName()
Returns the name of this Identity .
|
PublicKey
|
getPublicKey()
Returns the PublicKey associated with this Identity .
|
final
IdentityScope
|
getScope()
Returns the IdentityScope of this Identity .
|
int
|
hashCode()
Returns the hash code value for this Identity .
|
boolean
|
identityEquals(Identity identity)
Compares the specified Identity with this Identity for
equality and returns true if the specified object is equal,
false otherwise.
|
void
|
removeCertificate(Certificate certificate)
Removes the specified Certificate from this Identity .
|
void
|
setInfo(String info)
Sets an information string for this Identity .
|
void
|
setPublicKey(PublicKey key)
Sets the specified PublicKey to this Identity .
|
String
|
toString(boolean detailed)
Returns a string containing a concise, human-readable description of the
this Identity .
|
String
|
toString()
Returns a string containing a concise, human-readable description of the
this Identity including its name and its scope.
|
|
From class
java.lang.Object
Object
|
clone()
Creates and returns a copy of this Object .
|
boolean
|
equals(Object o)
Compares this instance with the specified object and indicates if they
are equal.
|
void
|
finalize()
Called before the object's memory is reclaimed by the VM.
|
final
Class<?>
|
getClass()
Returns the unique instance of Class that represents this
object's class.
|
int
|
hashCode()
Returns an integer hash code for this object.
|
final
void
|
notify()
Causes a thread which is waiting on this object's monitor (by means of
calling one of the wait() methods) to be woken up.
|
final
void
|
notifyAll()
Causes all threads which are waiting on this object's monitor (by means
of calling one of the wait() methods) to be woken up.
|
String
|
toString()
Returns a string containing a concise, human-readable description of this
object.
|
final
void
|
wait()
Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object.
|
final
void
|
wait(long millis, int nanos)
Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object or until the
specified timeout expires.
|
final
void
|
wait(long millis)
Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object or until the
specified timeout expires.
|
|
From interface
java.security.Principal
abstract
boolean
|
equals(Object obj)
Compares the specified object with this Principal for equality
and returns true if the specified object is equal, false
otherwise.
|
abstract
String
|
getName()
Returns the name of this Principal .
|
abstract
int
|
hashCode()
Returns the hash code value for this Principal .
|
abstract
String
|
toString()
Returns a string containing a concise, human-readable description of
this Principal .
|
|
Public Constructors
public
IdentityScope
(String name)
Constructs a new instance of IdentityScope
with the specified
name.
Parameters
name
| the name of this IdentityScope .
|
Constructs a new instance of IdentityScope
with the specified
name and the specified scope.
Parameters
name
| the name of this IdentityScope . |
scope
| the scope of this IdentityScope . |
Protected Constructors
protected
IdentityScope
()
Constructs a new instance of IdentityScope
.
Public Methods
public
abstract
void
addIdentity
(Identity identity)
Adds an Identity
to this IdentityScope
.
Parameters
identity
| the Identity to be added. |
public
abstract
Identity
getIdentity
(String name)
Returns the Identity
with the specified name or null
if
no Identity
with the specified name is present in this scope.
Parameters
name
| the name of the Identity to be returned. |
Returns
- the
Identity
with the specified name or null
if
not present.
public
abstract
Identity
getIdentity
(PublicKey key)
Returns the Identity
which is associated with the specified key
or null
if no Identity
associated with the specified key
is present in this scope.
Parameters
key
| the PublicKey of the Identity to be returned. |
Returns
- the
Identity
associated with the specified key or null
if not present.
Returns the Identity
with the name of the specified principal or
null
if no Identity
with the name of the specified
principal is present in this scope.
Parameters
principal
| the Principal whose name is used to lookup the Identity to be returned. |
Returns
- the
Identity
with the specified name or null
if
not present.
public
static
IdentityScope
getSystemScope
()
Returns the system's scope.
Returns an Enumeration
over the Identity
objects in this
IdentityScope
.
Returns
- an
Enumeration
over the Identity
objects in this
IdentityScope
.
public
abstract
void
removeIdentity
(Identity identity)
Removes an Identity
from this IdentityScope
.
Parameters
identity
| the Identity to be removed. |
public
abstract
int
size
()
Returns the number of Identity
objects in this scope.
Returns
- the number of
Identity
objects in this scope.
public
String
toString
()
Returns a string containing a concise, human-readable description of this
IdentityScope
.
Returns
- a printable representation for this
IdentityScope
.
Protected Methods