Class DLStorageQuotaUtil

java.lang.Object
com.liferay.document.library.service.persistence.DLStorageQuotaUtil

public class DLStorageQuotaUtil extends Object
The persistence utility for the dl storage quota service. This utility wraps com.liferay.document.library.service.persistence.impl.DLStorageQuotaPersistenceImpl 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

    • DLStorageQuotaUtil

      public DLStorageQuotaUtil()
  • Method Details

    • clearCache

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

      public static void clearCache(DLStorageQuota dlStorageQuota)
      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,DLStorageQuota> fetchByPrimaryKeys(Set<Serializable> primaryKeys)
      See Also:
      • BasePersistence.fetchByPrimaryKeys(Set)
    • findWithDynamicQuery

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

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

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

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

      public static DLStorageQuota update(DLStorageQuota dlStorageQuota, com.liferay.portal.kernel.service.ServiceContext serviceContext)
      See Also:
      • BasePersistence.update(com.liferay.portal.kernel.model.BaseModel, ServiceContext)
    • findByCompanyId

      public static DLStorageQuota findByCompanyId(long companyId) throws NoSuchStorageQuotaException
      Returns the dl storage quota where companyId = ? or throws a NoSuchStorageQuotaException if it could not be found.
      Parameters:
      companyId - the company ID
      Returns:
      the matching dl storage quota
      Throws:
      NoSuchStorageQuotaException - if a matching dl storage quota could not be found
      NoSuchStorageQuotaException
    • fetchByCompanyId

      public static DLStorageQuota fetchByCompanyId(long companyId)
      Returns the dl storage quota where companyId = ? or returns null if it could not be found. Uses the finder cache.
      Parameters:
      companyId - the company ID
      Returns:
      the matching dl storage quota, or null if a matching dl storage quota could not be found
    • fetchByCompanyId

      public static DLStorageQuota fetchByCompanyId(long companyId, boolean useFinderCache)
      Returns the dl storage quota where companyId = ? or returns null if it could not be found, optionally using the finder cache.
      Parameters:
      companyId - the company ID
      useFinderCache - whether to use the finder cache
      Returns:
      the matching dl storage quota, or null if a matching dl storage quota could not be found
    • removeByCompanyId

      public static DLStorageQuota removeByCompanyId(long companyId) throws NoSuchStorageQuotaException
      Removes the dl storage quota where companyId = ? from the database.
      Parameters:
      companyId - the company ID
      Returns:
      the dl storage quota that was removed
      Throws:
      NoSuchStorageQuotaException
    • countByCompanyId

      public static int countByCompanyId(long companyId)
      Returns the number of dl storage quotas where companyId = ?.
      Parameters:
      companyId - the company ID
      Returns:
      the number of matching dl storage quotas
    • cacheResult

      public static void cacheResult(DLStorageQuota dlStorageQuota)
      Caches the dl storage quota in the entity cache if it is enabled.
      Parameters:
      dlStorageQuota - the dl storage quota
    • cacheResult

      public static void cacheResult(List<DLStorageQuota> dlStorageQuotas)
      Caches the dl storage quotas in the entity cache if it is enabled.
      Parameters:
      dlStorageQuotas - the dl storage quotas
    • create

      public static DLStorageQuota create(long dlStorageQuotaId)
      Creates a new dl storage quota with the primary key. Does not add the dl storage quota to the database.
      Parameters:
      dlStorageQuotaId - the primary key for the new dl storage quota
      Returns:
      the new dl storage quota
    • remove

      public static DLStorageQuota remove(long dlStorageQuotaId) throws NoSuchStorageQuotaException
      Removes the dl storage quota with the primary key from the database. Also notifies the appropriate model listeners.
      Parameters:
      dlStorageQuotaId - the primary key of the dl storage quota
      Returns:
      the dl storage quota that was removed
      Throws:
      NoSuchStorageQuotaException - if a dl storage quota with the primary key could not be found
      NoSuchStorageQuotaException
    • updateImpl

      public static DLStorageQuota updateImpl(DLStorageQuota dlStorageQuota)
    • findByPrimaryKey

      public static DLStorageQuota findByPrimaryKey(long dlStorageQuotaId) throws NoSuchStorageQuotaException
      Returns the dl storage quota with the primary key or throws a NoSuchStorageQuotaException if it could not be found.
      Parameters:
      dlStorageQuotaId - the primary key of the dl storage quota
      Returns:
      the dl storage quota
      Throws:
      NoSuchStorageQuotaException - if a dl storage quota with the primary key could not be found
      NoSuchStorageQuotaException
    • fetchByPrimaryKey

      public static DLStorageQuota fetchByPrimaryKey(long dlStorageQuotaId)
      Returns the dl storage quota with the primary key or returns null if it could not be found.
      Parameters:
      dlStorageQuotaId - the primary key of the dl storage quota
      Returns:
      the dl storage quota, or null if a dl storage quota with the primary key could not be found
    • findAll

      public static List<DLStorageQuota> findAll()
      Returns all the dl storage quotas.
      Returns:
      the dl storage quotas
    • findAll

      public static List<DLStorageQuota> findAll(int start, int end)
      Returns a range of all the dl storage quotas.

      Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent, then the query will include the default ORDER BY logic from DLStorageQuotaModelImpl.

      Parameters:
      start - the lower bound of the range of dl storage quotas
      end - the upper bound of the range of dl storage quotas (not inclusive)
      Returns:
      the range of dl storage quotas
    • findAll

      public static List<DLStorageQuota> findAll(int start, int end, com.liferay.portal.kernel.util.OrderByComparator<DLStorageQuota> orderByComparator)
      Returns an ordered range of all the dl storage quotas.

      Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent, then the query will include the default ORDER BY logic from DLStorageQuotaModelImpl.

      Parameters:
      start - the lower bound of the range of dl storage quotas
      end - the upper bound of the range of dl storage quotas (not inclusive)
      orderByComparator - the comparator to order the results by (optionally null)
      Returns:
      the ordered range of dl storage quotas
    • findAll

      public static List<DLStorageQuota> findAll(int start, int end, com.liferay.portal.kernel.util.OrderByComparator<DLStorageQuota> orderByComparator, boolean useFinderCache)
      Returns an ordered range of all the dl storage quotas.

      Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil#ALL_POS will return the full result set. If orderByComparator is specified, then the query will include the given ORDER BY logic. If orderByComparator is absent, then the query will include the default ORDER BY logic from DLStorageQuotaModelImpl.

      Parameters:
      start - the lower bound of the range of dl storage quotas
      end - the upper bound of the range of dl storage quotas (not inclusive)
      orderByComparator - the comparator to order the results by (optionally null)
      useFinderCache - whether to use the finder cache
      Returns:
      the ordered range of dl storage quotas
    • removeAll

      public static void removeAll()
      Removes all the dl storage quotas from the database.
    • countAll

      public static int countAll()
      Returns the number of dl storage quotas.
      Returns:
      the number of dl storage quotas
    • getPersistence

      public static DLStorageQuotaPersistence getPersistence()
    • setPersistence

      public static void setPersistence(DLStorageQuotaPersistence persistence)