com.ibm.security.auth

Class AIXNumericGroupPrincipal

  1. java.lang.Object
  2. extended bycom.ibm.security.auth.AIXNumericGroupPrincipal
All implemented interfaces:
java.io.Serializable, java.security.Principal

  1. public class AIXNumericGroupPrincipal
  2. extends java.lang.Object
  3. implements java.security.Principal, java.io.Serializable

This class represents a user's AIX group identification number (GID).

Principals such as this AIXNumericGroupPrincipal may be associated with a particular Subject to augment that Subject with an additional identity. Refer to the Subject class for more information on how to achieve this. Authorization decisions can then be based upon the Principals associated with a Subject.

This class will be replaced by GroupIDPrincipal and PrimaryGroupIDPrincipalin future releases of JAAS.

See Also:
Principal, Subject, GroupIDPrincipal, PrimaryGroupIDPrincipal, Serialized Form

Constructor Summary

Constructor and Description
AIXNumericGroupPrincipal(long name,boolean primaryGroup)
Create an AIXNumericGroupPrincipal using a long representation of the user's group identification number (GID).
AIXNumericGroupPrincipal(java.lang.String name,boolean primaryGroup)
Create an AIXNumericGroupPrincipal using a String representation of the user's group identification number (GID).

Method Summary

Modifier and Type Method and Description
  1. boolean
equals(java.lang.Object o)
Compares the specified Object with this AIXNumericGroupPrincipal for equality.
  1. java.lang.String
getName()
Return the user's group identification number (GID) for this AIXNumericGroupPrincipal.
  1. int
hashCode()
Return a hash code for this AIXNumericGroupPrincipal.
  1. boolean
isPrimaryGroup()
Return whether this group identification number (GID) represents the primary group to which this user belongs.
  1. long
longValue()
Return the user's group identification number (GID) for this AIXNumericGroupPrincipal as a long.
  1. java.lang.String
toString()
Return a string representation of this AIXNumericGroupPrincipal.
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait

Constructor Detail

AIXNumericGroupPrincipal

  1. public AIXNumericGroupPrincipal( java.lang.String name,
  2. boolean primaryGroup)
Create an AIXNumericGroupPrincipal using a String representation of the user's group identification number (GID).

Parameters:
name - the user's group identification number (GID) for this user.

primaryGroup - true if the specified GID represents the primary group to which this user belongs.
Throws:
java.lang.NullPointerException - if the name is null.

AIXNumericGroupPrincipal

  1. public AIXNumericGroupPrincipal( long name,
  2. boolean primaryGroup)
Create an AIXNumericGroupPrincipal using a long representation of the user's group identification number (GID).

Parameters:
name - the user's group identification number (GID) for this user represented as a long.

primaryGroup - true if the specified GID represents the primary group to which this user belongs.

Method Detail

getName

  1. public java.lang.String getName( )
Return the user's group identification number (GID) for this AIXNumericGroupPrincipal.

Specified by:
getName in interface java.security.Principal
Returns:
the user's group identification number (GID) for this AIXNumericGroupPrincipal

longValue

  1. public long longValue()
Return the user's group identification number (GID) for this AIXNumericGroupPrincipal as a long.

Returns:
the user's group identification number (GID) for this AIXNumericGroupPrincipal as a long.

isPrimaryGroup

  1. public boolean isPrimaryGroup()
Return whether this group identification number (GID) represents the primary group to which this user belongs.

Returns:
true if this group identification number (GID) represents the primary group to which this user belongs, or false otherwise.

toString

  1. public java.lang.String toString( )
Return a string representation of this AIXNumericGroupPrincipal.

Specified by:
toString in interface java.security.Principal
Overrides:
toString in class java.lang.Object
Returns:
a string representation of this AIXNumericGroupPrincipal.

equals

  1. public boolean equals(java.lang.Object o)
Compares the specified Object with this AIXNumericGroupPrincipal for equality. Returns true if the given object is also an AIXNumericGroupPrincipal and the two AIXNumericGroupPrincipals have the same group identification number (GID).

Specified by:
equals in interface java.security.Principal
Overrides:
equals in class java.lang.Object
Parameters:
o - Object to be compared for equality with this AIXNumericGroupPrincipal.
Returns:
true if the specified Object is equal to this AIXNumericGroupPrincipal.

hashCode

  1. public int hashCode()
Return a hash code for this AIXNumericGroupPrincipal.

Specified by:
hashCode in interface java.security.Principal
Overrides:
hashCode in class java.lang.Object
Returns:
a hash code for this AIXNumericGroupPrincipal.