Class UserPrincipal

  • All Implemented Interfaces:,
    Direct Known Subclasses:
    DataSourceLoginService.DBUserPrincipal, JDBCLoginService.JDBCUserPrincipal

    public class UserPrincipal
    extends java.lang.Object
    UserPrincipal Represents a user with a credential. Instances of this class can be added to a Subject to present the user, while the credentials can be added directly to the Subject.
    See Also:
    Serialized Form
    • Field Detail

      • _credential

        protected final Credential _credential
    • Constructor Detail

      • UserPrincipal

        public UserPrincipal​(java.lang.String name,
                             Credential credential)
    • Method Detail

      • authenticate

        public boolean authenticate​(java.lang.Object credentials)
      • authenticate

        public boolean authenticate​(Credential c)
      • authenticate

        public boolean authenticate​(UserPrincipal u)
      • configureSubject

        public void configureSubject​( subject)
      • deconfigureSubject

        public void deconfigureSubject​( subject)
      • getName

        public java.lang.String getName()
        Specified by:
        getName in interface
      • toString

        public java.lang.String toString()
        Specified by:
        toString in interface
        toString in class java.lang.Object