Class AuthenticationException

  • All Implemented Interfaces:
    Serializable

    public final class AuthenticationException
    extends StreamNegotiationException
    An exception thrown during the login process, if SASL negotiation with the XMPP server fails.

    Typical error cases are invalid username and/or password in which case the failure condition is Failure.Condition.NOT_AUTHORIZED.

    If you want to know the exact failure case, ask for the condition as shown below:

    
     catch (AuthenticationException e) {
         if (e.getCondition() == Failure.Condition.NOT_AUTHORIZED) {
             //...
         }
     }
     
    See Also:
    Serialized Form
    • Constructor Detail

      • AuthenticationException

        public AuthenticationException​(String message)
      • AuthenticationException

        public AuthenticationException​(String message,
                                       Failure failure)