Class CPDefinitionLocalizationUtil

java.lang.Object
com.liferay.commerce.product.service.persistence.CPDefinitionLocalizationUtil

public class CPDefinitionLocalizationUtil extends Object
The persistence utility for the cp definition localization service. This utility wraps com.liferay.commerce.product.service.persistence.impl.CPDefinitionLocalizationPersistenceImpl 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

    • CPDefinitionLocalizationUtil

      public CPDefinitionLocalizationUtil()
  • Method Details

    • clearCache

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

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

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

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

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

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

      public static CPDefinitionLocalization update(CPDefinitionLocalization cpDefinitionLocalization, com.liferay.portal.kernel.service.ServiceContext serviceContext)
      See Also:
      • BasePersistence.update(com.liferay.portal.kernel.model.BaseModel, ServiceContext)
    • findByCPDefinitionId

      public static List<CPDefinitionLocalization> findByCPDefinitionId(long CPDefinitionId)
      Returns all the cp definition localizations where CPDefinitionId = ?.
      Parameters:
      CPDefinitionId - the cp definition ID
      Returns:
      the matching cp definition localizations
    • findByCPDefinitionId

      public static List<CPDefinitionLocalization> findByCPDefinitionId(long CPDefinitionId, int start, int end)
      Returns a range of all the cp definition localizations where CPDefinitionId = ?.

      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 CPDefinitionLocalizationModelImpl.

      Parameters:
      CPDefinitionId - the cp definition ID
      start - the lower bound of the range of cp definition localizations
      end - the upper bound of the range of cp definition localizations (not inclusive)
      Returns:
      the range of matching cp definition localizations
    • findByCPDefinitionId

      public static List<CPDefinitionLocalization> findByCPDefinitionId(long CPDefinitionId, int start, int end, com.liferay.portal.kernel.util.OrderByComparator<CPDefinitionLocalization> orderByComparator)
      Returns an ordered range of all the cp definition localizations where CPDefinitionId = ?.

      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 CPDefinitionLocalizationModelImpl.

      Parameters:
      CPDefinitionId - the cp definition ID
      start - the lower bound of the range of cp definition localizations
      end - the upper bound of the range of cp definition localizations (not inclusive)
      orderByComparator - the comparator to order the results by (optionally null)
      Returns:
      the ordered range of matching cp definition localizations
    • findByCPDefinitionId

      public static List<CPDefinitionLocalization> findByCPDefinitionId(long CPDefinitionId, int start, int end, com.liferay.portal.kernel.util.OrderByComparator<CPDefinitionLocalization> orderByComparator, boolean useFinderCache)
      Returns an ordered range of all the cp definition localizations where CPDefinitionId = ?.

      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 CPDefinitionLocalizationModelImpl.

      Parameters:
      CPDefinitionId - the cp definition ID
      start - the lower bound of the range of cp definition localizations
      end - the upper bound of the range of cp definition localizations (not inclusive)
      orderByComparator - the comparator to order the results by (optionally null)
      useFinderCache - whether to use the finder cache
      Returns:
      the ordered range of matching cp definition localizations
    • findByCPDefinitionId_First

      public static CPDefinitionLocalization findByCPDefinitionId_First(long CPDefinitionId, com.liferay.portal.kernel.util.OrderByComparator<CPDefinitionLocalization> orderByComparator) throws NoSuchCPDefinitionLocalizationException
      Returns the first cp definition localization in the ordered set where CPDefinitionId = ?.
      Parameters:
      CPDefinitionId - the cp definition ID
      orderByComparator - the comparator to order the set by (optionally null)
      Returns:
      the first matching cp definition localization
      Throws:
      NoSuchCPDefinitionLocalizationException - if a matching cp definition localization could not be found
      NoSuchCPDefinitionLocalizationException
    • fetchByCPDefinitionId_First

      public static CPDefinitionLocalization fetchByCPDefinitionId_First(long CPDefinitionId, com.liferay.portal.kernel.util.OrderByComparator<CPDefinitionLocalization> orderByComparator)
      Returns the first cp definition localization in the ordered set where CPDefinitionId = ?.
      Parameters:
      CPDefinitionId - the cp definition ID
      orderByComparator - the comparator to order the set by (optionally null)
      Returns:
      the first matching cp definition localization, or null if a matching cp definition localization could not be found
    • findByCPDefinitionId_Last

      public static CPDefinitionLocalization findByCPDefinitionId_Last(long CPDefinitionId, com.liferay.portal.kernel.util.OrderByComparator<CPDefinitionLocalization> orderByComparator) throws NoSuchCPDefinitionLocalizationException
      Returns the last cp definition localization in the ordered set where CPDefinitionId = ?.
      Parameters:
      CPDefinitionId - the cp definition ID
      orderByComparator - the comparator to order the set by (optionally null)
      Returns:
      the last matching cp definition localization
      Throws:
      NoSuchCPDefinitionLocalizationException - if a matching cp definition localization could not be found
      NoSuchCPDefinitionLocalizationException
    • fetchByCPDefinitionId_Last

      public static CPDefinitionLocalization fetchByCPDefinitionId_Last(long CPDefinitionId, com.liferay.portal.kernel.util.OrderByComparator<CPDefinitionLocalization> orderByComparator)
      Returns the last cp definition localization in the ordered set where CPDefinitionId = ?.
      Parameters:
      CPDefinitionId - the cp definition ID
      orderByComparator - the comparator to order the set by (optionally null)
      Returns:
      the last matching cp definition localization, or null if a matching cp definition localization could not be found
    • findByCPDefinitionId_PrevAndNext

      public static CPDefinitionLocalization[] findByCPDefinitionId_PrevAndNext(long cpDefinitionLocalizationId, long CPDefinitionId, com.liferay.portal.kernel.util.OrderByComparator<CPDefinitionLocalization> orderByComparator) throws NoSuchCPDefinitionLocalizationException
      Returns the cp definition localizations before and after the current cp definition localization in the ordered set where CPDefinitionId = ?.
      Parameters:
      cpDefinitionLocalizationId - the primary key of the current cp definition localization
      CPDefinitionId - the cp definition ID
      orderByComparator - the comparator to order the set by (optionally null)
      Returns:
      the previous, current, and next cp definition localization
      Throws:
      NoSuchCPDefinitionLocalizationException - if a cp definition localization with the primary key could not be found
      NoSuchCPDefinitionLocalizationException
    • removeByCPDefinitionId

      public static void removeByCPDefinitionId(long CPDefinitionId)
      Removes all the cp definition localizations where CPDefinitionId = ? from the database.
      Parameters:
      CPDefinitionId - the cp definition ID
    • countByCPDefinitionId

      public static int countByCPDefinitionId(long CPDefinitionId)
      Returns the number of cp definition localizations where CPDefinitionId = ?.
      Parameters:
      CPDefinitionId - the cp definition ID
      Returns:
      the number of matching cp definition localizations
    • findByCPDefinitionId_LanguageId

      public static CPDefinitionLocalization findByCPDefinitionId_LanguageId(long CPDefinitionId, String languageId) throws NoSuchCPDefinitionLocalizationException
      Returns the cp definition localization where CPDefinitionId = ? and languageId = ? or throws a NoSuchCPDefinitionLocalizationException if it could not be found.
      Parameters:
      CPDefinitionId - the cp definition ID
      languageId - the language ID
      Returns:
      the matching cp definition localization
      Throws:
      NoSuchCPDefinitionLocalizationException - if a matching cp definition localization could not be found
      NoSuchCPDefinitionLocalizationException
    • fetchByCPDefinitionId_LanguageId

      public static CPDefinitionLocalization fetchByCPDefinitionId_LanguageId(long CPDefinitionId, String languageId)
      Returns the cp definition localization where CPDefinitionId = ? and languageId = ? or returns null if it could not be found. Uses the finder cache.
      Parameters:
      CPDefinitionId - the cp definition ID
      languageId - the language ID
      Returns:
      the matching cp definition localization, or null if a matching cp definition localization could not be found
    • fetchByCPDefinitionId_LanguageId

      public static CPDefinitionLocalization fetchByCPDefinitionId_LanguageId(long CPDefinitionId, String languageId, boolean useFinderCache)
      Returns the cp definition localization where CPDefinitionId = ? and languageId = ? or returns null if it could not be found, optionally using the finder cache.
      Parameters:
      CPDefinitionId - the cp definition ID
      languageId - the language ID
      useFinderCache - whether to use the finder cache
      Returns:
      the matching cp definition localization, or null if a matching cp definition localization could not be found
    • removeByCPDefinitionId_LanguageId

      public static CPDefinitionLocalization removeByCPDefinitionId_LanguageId(long CPDefinitionId, String languageId) throws NoSuchCPDefinitionLocalizationException
      Removes the cp definition localization where CPDefinitionId = ? and languageId = ? from the database.
      Parameters:
      CPDefinitionId - the cp definition ID
      languageId - the language ID
      Returns:
      the cp definition localization that was removed
      Throws:
      NoSuchCPDefinitionLocalizationException
    • countByCPDefinitionId_LanguageId

      public static int countByCPDefinitionId_LanguageId(long CPDefinitionId, String languageId)
      Returns the number of cp definition localizations where CPDefinitionId = ? and languageId = ?.
      Parameters:
      CPDefinitionId - the cp definition ID
      languageId - the language ID
      Returns:
      the number of matching cp definition localizations
    • cacheResult

      public static void cacheResult(CPDefinitionLocalization cpDefinitionLocalization)
      Caches the cp definition localization in the entity cache if it is enabled.
      Parameters:
      cpDefinitionLocalization - the cp definition localization
    • cacheResult

      public static void cacheResult(List<CPDefinitionLocalization> cpDefinitionLocalizations)
      Caches the cp definition localizations in the entity cache if it is enabled.
      Parameters:
      cpDefinitionLocalizations - the cp definition localizations
    • create

      public static CPDefinitionLocalization create(long cpDefinitionLocalizationId)
      Creates a new cp definition localization with the primary key. Does not add the cp definition localization to the database.
      Parameters:
      cpDefinitionLocalizationId - the primary key for the new cp definition localization
      Returns:
      the new cp definition localization
    • remove

      public static CPDefinitionLocalization remove(long cpDefinitionLocalizationId) throws NoSuchCPDefinitionLocalizationException
      Removes the cp definition localization with the primary key from the database. Also notifies the appropriate model listeners.
      Parameters:
      cpDefinitionLocalizationId - the primary key of the cp definition localization
      Returns:
      the cp definition localization that was removed
      Throws:
      NoSuchCPDefinitionLocalizationException - if a cp definition localization with the primary key could not be found
      NoSuchCPDefinitionLocalizationException
    • updateImpl

      public static CPDefinitionLocalization updateImpl(CPDefinitionLocalization cpDefinitionLocalization)
    • findByPrimaryKey

      public static CPDefinitionLocalization findByPrimaryKey(long cpDefinitionLocalizationId) throws NoSuchCPDefinitionLocalizationException
      Returns the cp definition localization with the primary key or throws a NoSuchCPDefinitionLocalizationException if it could not be found.
      Parameters:
      cpDefinitionLocalizationId - the primary key of the cp definition localization
      Returns:
      the cp definition localization
      Throws:
      NoSuchCPDefinitionLocalizationException - if a cp definition localization with the primary key could not be found
      NoSuchCPDefinitionLocalizationException
    • fetchByPrimaryKey

      public static CPDefinitionLocalization fetchByPrimaryKey(long cpDefinitionLocalizationId)
      Returns the cp definition localization with the primary key or returns null if it could not be found.
      Parameters:
      cpDefinitionLocalizationId - the primary key of the cp definition localization
      Returns:
      the cp definition localization, or null if a cp definition localization with the primary key could not be found
    • findAll

      public static List<CPDefinitionLocalization> findAll()
      Returns all the cp definition localizations.
      Returns:
      the cp definition localizations
    • findAll

      public static List<CPDefinitionLocalization> findAll(int start, int end)
      Returns a range of all the cp definition localizations.

      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 CPDefinitionLocalizationModelImpl.

      Parameters:
      start - the lower bound of the range of cp definition localizations
      end - the upper bound of the range of cp definition localizations (not inclusive)
      Returns:
      the range of cp definition localizations
    • findAll

      public static List<CPDefinitionLocalization> findAll(int start, int end, com.liferay.portal.kernel.util.OrderByComparator<CPDefinitionLocalization> orderByComparator)
      Returns an ordered range of all the cp definition localizations.

      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 CPDefinitionLocalizationModelImpl.

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

      public static List<CPDefinitionLocalization> findAll(int start, int end, com.liferay.portal.kernel.util.OrderByComparator<CPDefinitionLocalization> orderByComparator, boolean useFinderCache)
      Returns an ordered range of all the cp definition localizations.

      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 CPDefinitionLocalizationModelImpl.

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

      public static void removeAll()
      Removes all the cp definition localizations from the database.
    • countAll

      public static int countAll()
      Returns the number of cp definition localizations.
      Returns:
      the number of cp definition localizations
    • getPersistence

      public static CPDefinitionLocalizationPersistence getPersistence()
    • setPersistence

      public static void setPersistence(CPDefinitionLocalizationPersistence persistence)