Package com.sun.gssapi
Interface GSSNameSpi
public interface GSSNameSpi
This class represents a mechanism specific name element. One or
more instances of this class are contained in an instance of
a GSSName object. Each GSSNameSpi object represents at most 1
mechanism specific name element.
-
Method Summary
Modifier and TypeMethodDescriptionclone()
Produces a copy of this object.boolean
equals
(GSSNameSpi name) Equal method for the GSSNameSpi objects.byte[]
export()
Returns a flat name representation for this object.getMech()
Get the mechanism type that this NameElement corresponds to.Returns the name type oid for this name.Returns the oid describing the format of the printable name.void
Initializer for the GSSNameSpi object using a byte array.void
Initializer for the GSSNameSpi object using a String.boolean
Indicates if this name object represents an Anonymous name.toString()
Returns a string representation for this name.
-
Method Details
-
init
Initializer for the GSSNameSpi object using a byte array.- Parameters:
byte
- [] name bytes which is to be interpreted based on the nameTypenameType
- - oid representing the type of name supplied- Throws:
GSSException
- The major codes can be BAD_NAMETYPE, BAD_NAME, and FAILURE.- See Also:
-
init
Initializer for the GSSNameSpi object using a String.- Parameters:
name
- string which is to be interpreted based on the nameTypenameType
- - oid representing the type of name supplied- Throws:
GSSException
- The major codes can be BAD_NAMETYPE, BAD_NAME, and FAILURE.- See Also:
-
equals
Equal method for the GSSNameSpi objects. If either name denotes an anonymous principal, the call should return false.- Parameters:
name
- to be compared with- Throws:
GSSException
- with major codes of BAD_NAMETYPE, BAD_NAME, FAILURE
-
export
Returns a flat name representation for this object. The name format is defined in RFC 2078.- Returns:
- the flat name representation for this object
- Throws:
GSSException
- with major codes NAME_NOT_MN, BAD_NAME, BAD_NAME, FAILURE.
-
getMech
Oid getMech()Get the mechanism type that this NameElement corresponds to.- Returns:
- the Oid of the mechanism type
-
getNameType
Oid getNameType()Returns the name type oid for this name.- Returns:
- the name type oid for this name
-
toString
String toString()Returns a string representation for this name. The printed name type can be obtained by calling getStringNameType(). -
getStringNameType
Oid getStringNameType()Returns the oid describing the format of the printable name.- Returns:
- the Oid for the format of the printed name
-
clone
Object clone()Produces a copy of this object. -
isAnonymousName
boolean isAnonymousName()Indicates if this name object represents an Anonymous name.
-