org.keycloak.models.sessions.mongo

## Class UsernameLoginFailureAdapter

- java.lang.Object
- - org.keycloak.models.sessions.mongo.AbstractMongoAdapter<MongoUsernameLoginFailureEntity>
  - - org.keycloak.models.sessions.mongo.UsernameLoginFailureAdapter

- All Implemented Interfaces:
    UsernameLoginFailureModel

      public class UsernameLoginFailureAdapter
      extends AbstractMongoAdapter<MongoUsernameLoginFailureEntity>
      implements UsernameLoginFailureModel

  Version:
    $Revision: 1 $
  Author:
    Bill Burke

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected MongoUsernameLoginFailureEntity` | `user`

    - ### Fields inherited from class org.keycloak.models.sessions.mongo.AbstractMongoAdapter

      `invocationContext`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `UsernameLoginFailureAdapter(MongoStoreInvocationContext invocationContext, MongoUsernameLoginFailureEntity user)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `clearFailures()`
    `int` | `getFailedLoginNotBefore()`
    `long` | `getLastFailure()`
    `String` | `getLastIPFailure()`
    `protected MongoUsernameLoginFailureEntity` | `getMongoEntity()`
    `int` | `getNumFailures()`
    `String` | `getUsername()`
    `void` | `incrementFailures()`
    `void` | `setFailedLoginNotBefore(int notBefore)`
    `void` | `setLastFailure(long lastFailure)`
    `void` | `setLastIPFailure(String ip)`

    - ### Methods inherited from class org.keycloak.models.sessions.mongo.AbstractMongoAdapter

      `equals, getMongoStore, hashCode, updateMongoEntity`

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

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

- - ### Field Detail

    - #### user

          protected MongoUsernameLoginFailureEntity user

  - ### Constructor Detail

    - #### UsernameLoginFailureAdapter

          public UsernameLoginFailureAdapter(MongoStoreInvocationContext invocationContext,
                                     MongoUsernameLoginFailureEntity user)

  - ### Method Detail

    - #### getMongoEntity

          protected MongoUsernameLoginFailureEntity getMongoEntity()

      Specified by:
        `getMongoEntity` in class `AbstractMongoAdapter<MongoUsernameLoginFailureEntity>`

    - #### getUsername

          public String getUsername()

      Specified by:
        `getUsername` in interface `UsernameLoginFailureModel`

    - #### getFailedLoginNotBefore

          public int getFailedLoginNotBefore()

      Specified by:
        `getFailedLoginNotBefore` in interface `UsernameLoginFailureModel`

    - #### setFailedLoginNotBefore

          public void setFailedLoginNotBefore(int notBefore)

      Specified by:
        `setFailedLoginNotBefore` in interface `UsernameLoginFailureModel`

    - #### getNumFailures

          public int getNumFailures()

      Specified by:
        `getNumFailures` in interface `UsernameLoginFailureModel`

    - #### incrementFailures

          public void incrementFailures()

      Specified by:
        `incrementFailures` in interface `UsernameLoginFailureModel`

    - #### clearFailures

          public void clearFailures()

      Specified by:
        `clearFailures` in interface `UsernameLoginFailureModel`

    - #### getLastFailure

          public long getLastFailure()

      Specified by:
        `getLastFailure` in interface `UsernameLoginFailureModel`

    - #### setLastFailure

          public void setLastFailure(long lastFailure)

      Specified by:
        `setLastFailure` in interface `UsernameLoginFailureModel`

    - #### getLastIPFailure

          public String getLastIPFailure()

      Specified by:
        `getLastIPFailure` in interface `UsernameLoginFailureModel`

    - #### setLastIPFailure

          public void setLastIPFailure(String ip)

      Specified by:
        `setLastIPFailure` in interface `UsernameLoginFailureModel`

Copyright © 2014. All Rights Reserved.