tigase.jaxmpp.core.client.xmpp.modules.auth.saslmechanisms

## Class PlainMechanism

- java.lang.Object
- - tigase.jaxmpp.core.client.xmpp.modules.auth.saslmechanisms.AbstractSaslMechanism
  - - tigase.jaxmpp.core.client.xmpp.modules.auth.saslmechanisms.PlainMechanism

- All Implemented Interfaces:
    SaslMechanism

      public class PlainMechanism
      extends AbstractSaslMechanism

- - ### Field Summary

    - ### Fields inherited from class tigase.jaxmpp.core.client.xmpp.modules.auth.saslmechanisms.AbstractSaslMechanism

      `SASL_COMPLETE_KEY`

    - ### Fields inherited from interface tigase.jaxmpp.core.client.xmpp.modules.auth.SaslMechanism

      `FORCE_AUTHZID`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `PlainMechanism()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `evaluateChallenge(String input, SessionObject sessionObject)` Evaluating challenge received from server.
    `boolean` | `isAllowedToUse(SessionObject sessionObject)` This method is used to check if mechanism can be used with current session.
    `String` | `name()` Return mechanism name.

    - ### Methods inherited from class tigase.jaxmpp.core.client.xmpp.modules.auth.saslmechanisms.AbstractSaslMechanism

      `isComplete, setComplete`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### PlainMechanism

          public PlainMechanism()

  - ### Method Detail

    - #### evaluateChallenge

          public String evaluateChallenge(String input,
                                          SessionObject sessionObject)
                                   throws ClientSaslException

      Description copied from interface: `SaslMechanism`
      Evaluating challenge received from server.
      Parameters:
        `input` - received data
        `sessionObject` - current SessionObject
      Returns:
        calculated response
      Throws:
        `ClientSaslException`

    - #### isAllowedToUse

          public boolean isAllowedToUse(SessionObject sessionObject)

      Description copied from interface: `SaslMechanism`
      This method is used to check if mechanism can be used with current session. For example if no username and passowrd is stored in sessionObject, then PlainMechanism can't be used.
      Parameters:
        `sessionObject` - current SessionObject
      Returns:
        `true` if mechanism can be used it current XMPP session.

    - #### name

          public String name()

      Description copied from interface: `SaslMechanism`
      Return mechanism name.
      Returns:
        mechanism name.

Copyright © 2006–2020 Tigase. All rights reserved.