java.lang.Object
com.liferay.multi.factor.authentication.timebased.otp.service.persistence.MFATimeBasedOTPEntryUtil

public class MFATimeBasedOTPEntryUtil extends Object
The persistence utility for the mfa time based otp entry service. This utility wraps com.liferay.multi.factor.authentication.timebased.otp.service.persistence.impl.MFATimeBasedOTPEntryPersistenceImpl and provides direct access to the database for CRUD operations. This utility should only be used by the service layer, as it must operate within a transaction. Never access this utility in a JSP, controller, model, or other front-end class.

Caching information and settings can be found in portal.properties

See Also:
Generated:
  • Constructor Details

    • MFATimeBasedOTPEntryUtil

      public MFATimeBasedOTPEntryUtil()
  • Method Details

    • cacheResult

      public static void cacheResult(List<MFATimeBasedOTPEntry> mfaTimeBasedOTPEntries)
      See Also:
      • BasePersistence.cacheResult(List)
    • cacheResult

      public static void cacheResult(MFATimeBasedOTPEntry mfaTimeBasedOTPEntry)
      See Also:
      • BasePersistence.cacheResult(com.liferay.portal.kernel.model.BaseModel)
    • clearCache

      public static void clearCache()
      See Also:
      • BasePersistence.clearCache()
    • clearCache

      public static void clearCache(MFATimeBasedOTPEntry mfaTimeBasedOTPEntry)
      See Also:
      • BasePersistence.clearCache(com.liferay.portal.kernel.model.BaseModel)
    • countWithDynamicQuery

      public static long countWithDynamicQuery(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
      See Also:
      • BasePersistence.countWithDynamicQuery(DynamicQuery)
    • fetchByPrimaryKeys

      public static Map<Serializable,MFATimeBasedOTPEntry> fetchByPrimaryKeys(Set<Serializable> primaryKeys)
      See Also:
      • BasePersistence.fetchByPrimaryKeys(Set)
    • findWithDynamicQuery

      public static List<MFATimeBasedOTPEntry> findWithDynamicQuery(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
      See Also:
      • BasePersistence.findWithDynamicQuery(DynamicQuery)
    • findWithDynamicQuery

      public static List<MFATimeBasedOTPEntry> findWithDynamicQuery(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, int end)
      See Also:
      • BasePersistence.findWithDynamicQuery(DynamicQuery, int, int)
    • findWithDynamicQuery

      public static List<MFATimeBasedOTPEntry> findWithDynamicQuery(com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, int end, com.liferay.portal.kernel.util.OrderByComparator<MFATimeBasedOTPEntry> orderByComparator)
      See Also:
      • BasePersistence.findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator)
    • update

      public static MFATimeBasedOTPEntry update(MFATimeBasedOTPEntry mfaTimeBasedOTPEntry)
      See Also:
      • BasePersistence.update(com.liferay.portal.kernel.model.BaseModel)
    • update

      public static MFATimeBasedOTPEntry update(MFATimeBasedOTPEntry mfaTimeBasedOTPEntry, com.liferay.portal.kernel.service.ServiceContext serviceContext)
      See Also:
      • BasePersistence.update(com.liferay.portal.kernel.model.BaseModel, ServiceContext)
    • findByUserId

      public static MFATimeBasedOTPEntry findByUserId(long userId) throws NoSuchEntryException
      Returns the mfa time based otp entry where userId = ? or throws a NoSuchEntryException if it could not be found.
      Parameters:
      userId - the user ID
      Returns:
      the matching mfa time based otp entry
    • fetchByUserId

      public static MFATimeBasedOTPEntry fetchByUserId(long userId, boolean useFinderCache)
      Returns the mfa time based otp entry where userId = ? or returns null if it could not be found, optionally using the finder cache.
      Parameters:
      userId - the user ID
      useFinderCache - whether to use the finder cache
      Returns:
      the matching mfa time based otp entry, or null if a matching mfa time based otp entry could not be found
    • removeByUserId

      public static MFATimeBasedOTPEntry removeByUserId(long userId) throws NoSuchEntryException
      Removes the mfa time based otp entry where userId = ? from the database.
      Parameters:
      userId - the user ID
      Returns:
      the mfa time based otp entry that was removed
      Throws:
      NoSuchEntryException
    • countByUserId

      public static int countByUserId(long userId)
      Returns the number of mfa time based otp entries where userId = ?.
      Parameters:
      userId - the user ID
      Returns:
      the number of matching mfa time based otp entries
    • create

      public static MFATimeBasedOTPEntry create(long mfaTimeBasedOTPEntryId)
      Creates a new mfa time based otp entry with the primary key. Does not add the mfa time based otp entry to the database.
      Parameters:
      mfaTimeBasedOTPEntryId - the primary key for the new mfa time based otp entry
      Returns:
      the new mfa time based otp entry
    • remove

      public static MFATimeBasedOTPEntry remove(long mfaTimeBasedOTPEntryId) throws NoSuchEntryException
      Removes the mfa time based otp entry with the primary key from the database. Also notifies the appropriate model listeners.
      Parameters:
      mfaTimeBasedOTPEntryId - the primary key of the mfa time based otp entry
      Returns:
      the mfa time based otp entry that was removed
    • updateImpl

      public static MFATimeBasedOTPEntry updateImpl(MFATimeBasedOTPEntry mfaTimeBasedOTPEntry)
    • findByPrimaryKey

      public static MFATimeBasedOTPEntry findByPrimaryKey(long mfaTimeBasedOTPEntryId) throws NoSuchEntryException
      Returns the mfa time based otp entry with the primary key or throws a NoSuchEntryException if it could not be found.
      Parameters:
      mfaTimeBasedOTPEntryId - the primary key of the mfa time based otp entry
      Returns:
      the mfa time based otp entry
    • fetchByPrimaryKey

      public static MFATimeBasedOTPEntry fetchByPrimaryKey(long mfaTimeBasedOTPEntryId)
      Returns the mfa time based otp entry with the primary key or returns null if it could not be found.
      Parameters:
      mfaTimeBasedOTPEntryId - the primary key of the mfa time based otp entry
      Returns:
      the mfa time based otp entry, or null if a mfa time based otp entry with the primary key could not be found
    • fetchByUserId

      public static MFATimeBasedOTPEntry fetchByUserId(long userId)
      Returns the mfa time based otp entry where userId = ? or returns null if it could not be found. Uses the finder cache.
      Parameters:
      userId - the user ID
      Returns:
      the matching mfa time based otp entry, or null if a matching mfa time based otp entry could not be found
    • getPersistence

      public static MFATimeBasedOTPEntryPersistence getPersistence()
    • setPersistence

      public static void setPersistence(MFATimeBasedOTPEntryPersistence persistence)