Identity


Identity java.security

Java 1.1; Deprecated in 1.2 @Deprecated serializable

This deprecated class was used in Java 1.1 to represent an entity or Principal with an associated PublicKey object. In Java 1.1, the public key for a named entity could be retrieved from the system keystore with a line like the following:

 IdentityScope.getSystemScope( ).getIdentity(name).getPublicKey( ) 

As of Java 1.2, the Identity class and the related IdentityScope and Signer classes have been deprecated in favor of KeyStore and java.security.cert.Certificate .

Figure 14-12. java.security.Identity

 public abstract class  Identity  implements Principal, Serializable {  // Public Constructors  public  Identity  (String  name  );        public  Identity  (String  name  , IdentityScope  scope  )          throws KeyManagementException;  // Protected Constructors  protected  Identity  ( );  // Public Instance Methods  public void  addCertificate  (java.security.Certificate  certificate  )          throws KeyManagementException;        public java.security.Certificate[ ]  certificates  ( );        public String  getInfo  ( );        public PublicKey  getPublicKey  ( );        public final IdentityScope  getScope  ( );        public void  removeCertificate  (java.security.Certificate  certificate  )          throws KeyManagementException;        public void  setInfo  (String  info  );        public void  setPublicKey  (PublicKey  key  ) throws KeyManagementException;        public String  toString  (boolean  detailed  );  // Methods Implementing Principal  public final boolean  equals  (Object  identity  );        public final String  getName  ( );        public int  hashCode  ( );        public String  toString  ( );  // Protected Instance Methods  protected boolean  identityEquals  (Identity  identity  );   } 

Subclasses

IdentityScope , Signer

Passed To

IdentityScope.{addIdentity( ) , removeIdentity( )}

Returned By

IdentityScope.getIdentity( )



Java In A Nutshell
Java In A Nutshell, 5th Edition
ISBN: 0596007736
EAN: 2147483647
Year: 2004
Pages: 1220

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net