BEA Systems, Inc.

BEA WebLogic Server 9.1 API Reference


weblogic.security.principal
Class WLSAbstractPrincipal

java.lang.Object
  extended byweblogic.security.principal.WLSAbstractPrincipal
All Implemented Interfaces:
Principal, Serializable, WLSPrincipal
Direct Known Subclasses:
WLSGroupImpl, WLSUserImpl

public abstract class WLSAbstractPrincipal
extends Object
implements WLSPrincipal

The WLSAbstractPrincipal class is a convenience abstract class that implements a principal whose name field will be signed by the PrincipalValidatorImpl class. To use this class, you should make the PrincipalValidatorImpl class the runtime class for your Principal Validation provider, or extend that class and make the extended class your Principal Validation provider.

Note: Use of this class is not required by WebLogic Server. It is simply a convenience class.

See Also:
Serialized Form
Copyright © 2005 BEA Systems, Inc. All Rights Reserved.

Constructor Summary
protected WLSAbstractPrincipal()
          Constructs an instance of the WLSAbstractPrincipal.
 
Method Summary
 boolean equals(Object another)
          Compares this principal to the principal in the specified object.
 String getName()
          Gets the name of this principal.
 byte[] getSalt()
          Gets the principal's salt.
 byte[] getSignature()
          Gets the derived principal's trust signature.
 byte[] getSignedData()
          Gets the derived principal's signing data, which is used to generate the trust signature.
 int hashCode()
          Returns a hashcode for the name of this principal.
protected  void setName(String name)
          Sets the name of this principal.
 void setSalt(byte[] salt)
          Sets the principal's salt.
 void setSignature(byte[] signature)
          Sets the derived principal's trust signature.
 String toString()
          Returns a String representation of this principal.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

WLSAbstractPrincipal

protected WLSAbstractPrincipal()
Constructs an instance of the WLSAbstractPrincipal.

Method Detail

equals

public boolean equals(Object another)
Compares this principal to the principal in the specified object.

Specified by:
equals in interface Principal
Parameters:
another - the other principal with which to compare this principal.

Returns:
TRUE if the principal passed in matches the principal passed in, and FALSE otherwise.


getName

public String getName()
Gets the name of this principal.

Specified by:
getName in interface Principal
Returns:
the name of this principal, represented as a String.

See Also:
setName(java.lang.String)

getSalt

public byte[] getSalt()
Gets the principal's salt.

Specified by:
getSalt in interface WLSPrincipal
Returns:
the principal's salt, represented as an array of bytes.

See Also:
setSalt(byte[])

getSignature

public byte[] getSignature()
Gets the derived principal's trust signature.

Specified by:
getSignature in interface WLSPrincipal
Returns:
the derived principal's trust signature, represented as an array of bytes.

See Also:
setSignature(byte[])

getSignedData

public byte[] getSignedData()
Gets the derived principal's signing data, which is used to generate the trust signature.

Specified by:
getSignedData in interface WLSPrincipal
Returns:
the derived principal's signing data, represented as a sequence of bytes in the platform's default charset.


hashCode

public int hashCode()
Returns a hashcode for the name of this principal.

Specified by:
hashCode in interface Principal
Returns:
the name of this principal, represented as an int.


setName

protected void setName(String name)
Sets the name of this principal.

Parameters:
name - the name of this principal, represented as a String.

See Also:
getName()

setSalt

public void setSalt(byte[] salt)
Sets the principal's salt.

Parameters:
salt - the principal's salt, represented as an array of bytes.

See Also:
getSalt()

setSignature

public void setSignature(byte[] signature)
Sets the derived principal's trust signature.

Specified by:
setSignature in interface WLSPrincipal
Parameters:
signature - the derived principal's trust signsture, represented as an array of bytes.

See Also:
getSignature()

toString

public String toString()
Returns a String representation of this principal.

Specified by:
toString in interface Principal
Returns:
this principal, represented as a String.


Documentation is available at
http://download.oracle.com/docs/cd/E13222_01/wls/docs91
Copyright 2005 BEA Systems Inc.