
public final class InetAddressPrincipal
extends java.lang.Object
implements java.security.Principal, java.lang.Cloneable
| Constructor and Description |
|---|
InetAddressPrincipal(java.net.InetAddress inetAddress)
Create a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
InetAddressPrincipal |
clone()
Create a clone of this instance.
|
boolean |
equals(InetAddressPrincipal other)
Determine whether this instance is equal to another.
|
boolean |
equals(java.lang.Object other)
Determine whether this instance is equal to another.
|
java.net.InetAddress |
getInetAddress()
Get the IP address of this principal.
|
java.lang.String |
getName()
Get the name of this principal; it will be the string representation of the IP address.
|
int |
hashCode()
Get the hash code for this instance.
|
java.lang.String |
toString()
Get a human-readable representation of this principal.
|
public InetAddressPrincipal(java.net.InetAddress inetAddress)
inetAddress - the addresspublic java.lang.String getName()
getName in interface java.security.Principalpublic java.net.InetAddress getInetAddress()
public boolean equals(java.lang.Object other)
equals in interface java.security.Principalequals in class java.lang.Objectother - the other instancetrue if they are equal, false otherwisepublic boolean equals(InetAddressPrincipal other)
other - the other instancetrue if they are equal, false otherwisepublic int hashCode()
InetAddress object herein.hashCode in interface java.security.PrincipalhashCode in class java.lang.Objectpublic java.lang.String toString()
toString in interface java.security.PrincipaltoString in class java.lang.Objectpublic InetAddressPrincipal clone()
clone in class java.lang.ObjectCopyright © 2014 JBoss, a division of Red Hat, Inc.. All Rights Reserved.