001    /**
002     * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portlet.asset.service.persistence;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    import com.liferay.portal.kernel.dao.orm.DynamicQuery;
019    import com.liferay.portal.kernel.exception.SystemException;
020    import com.liferay.portal.kernel.util.OrderByComparator;
021    import com.liferay.portal.kernel.util.ReferenceRegistry;
022    import com.liferay.portal.service.ServiceContext;
023    
024    import com.liferay.portlet.asset.model.AssetCategoryProperty;
025    
026    import java.util.List;
027    
028    /**
029     * The persistence utility for the asset category property service. This utility wraps {@link AssetCategoryPropertyPersistenceImpl} 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.
030     *
031     * <p>
032     * Caching information and settings can be found in <code>portal.properties</code>
033     * </p>
034     *
035     * @author Brian Wing Shun Chan
036     * @see AssetCategoryPropertyPersistence
037     * @see AssetCategoryPropertyPersistenceImpl
038     * @generated
039     */
040    public class AssetCategoryPropertyUtil {
041            /*
042             * NOTE FOR DEVELOPERS:
043             *
044             * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class.
045             */
046    
047            /**
048             * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
049             */
050            public static void clearCache() {
051                    getPersistence().clearCache();
052            }
053    
054            /**
055             * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel)
056             */
057            public static void clearCache(AssetCategoryProperty assetCategoryProperty) {
058                    getPersistence().clearCache(assetCategoryProperty);
059            }
060    
061            /**
062             * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery)
063             */
064            public long countWithDynamicQuery(DynamicQuery dynamicQuery)
065                    throws SystemException {
066                    return getPersistence().countWithDynamicQuery(dynamicQuery);
067            }
068    
069            /**
070             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
071             */
072            public static List<AssetCategoryProperty> findWithDynamicQuery(
073                    DynamicQuery dynamicQuery) throws SystemException {
074                    return getPersistence().findWithDynamicQuery(dynamicQuery);
075            }
076    
077            /**
078             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
079             */
080            public static List<AssetCategoryProperty> findWithDynamicQuery(
081                    DynamicQuery dynamicQuery, int start, int end)
082                    throws SystemException {
083                    return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
084            }
085    
086            /**
087             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator)
088             */
089            public static List<AssetCategoryProperty> findWithDynamicQuery(
090                    DynamicQuery dynamicQuery, int start, int end,
091                    OrderByComparator orderByComparator) throws SystemException {
092                    return getPersistence()
093                                       .findWithDynamicQuery(dynamicQuery, start, end,
094                            orderByComparator);
095            }
096    
097            /**
098             * @see com.liferay.portal.service.persistence.BasePersistence#remove(com.liferay.portal.model.BaseModel)
099             */
100            public static AssetCategoryProperty remove(
101                    AssetCategoryProperty assetCategoryProperty) throws SystemException {
102                    return getPersistence().remove(assetCategoryProperty);
103            }
104    
105            /**
106             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
107             */
108            public static AssetCategoryProperty update(
109                    AssetCategoryProperty assetCategoryProperty, boolean merge)
110                    throws SystemException {
111                    return getPersistence().update(assetCategoryProperty, merge);
112            }
113    
114            /**
115             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean, ServiceContext)
116             */
117            public static AssetCategoryProperty update(
118                    AssetCategoryProperty assetCategoryProperty, boolean merge,
119                    ServiceContext serviceContext) throws SystemException {
120                    return getPersistence()
121                                       .update(assetCategoryProperty, merge, serviceContext);
122            }
123    
124            /**
125            * Caches the asset category property in the entity cache if it is enabled.
126            *
127            * @param assetCategoryProperty the asset category property
128            */
129            public static void cacheResult(
130                    com.liferay.portlet.asset.model.AssetCategoryProperty assetCategoryProperty) {
131                    getPersistence().cacheResult(assetCategoryProperty);
132            }
133    
134            /**
135            * Caches the asset category properties in the entity cache if it is enabled.
136            *
137            * @param assetCategoryProperties the asset category properties
138            */
139            public static void cacheResult(
140                    java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> assetCategoryProperties) {
141                    getPersistence().cacheResult(assetCategoryProperties);
142            }
143    
144            /**
145            * Creates a new asset category property with the primary key. Does not add the asset category property to the database.
146            *
147            * @param categoryPropertyId the primary key for the new asset category property
148            * @return the new asset category property
149            */
150            public static com.liferay.portlet.asset.model.AssetCategoryProperty create(
151                    long categoryPropertyId) {
152                    return getPersistence().create(categoryPropertyId);
153            }
154    
155            /**
156            * Removes the asset category property with the primary key from the database. Also notifies the appropriate model listeners.
157            *
158            * @param categoryPropertyId the primary key of the asset category property
159            * @return the asset category property that was removed
160            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a asset category property with the primary key could not be found
161            * @throws SystemException if a system exception occurred
162            */
163            public static com.liferay.portlet.asset.model.AssetCategoryProperty remove(
164                    long categoryPropertyId)
165                    throws com.liferay.portal.kernel.exception.SystemException,
166                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
167                    return getPersistence().remove(categoryPropertyId);
168            }
169    
170            public static com.liferay.portlet.asset.model.AssetCategoryProperty updateImpl(
171                    com.liferay.portlet.asset.model.AssetCategoryProperty assetCategoryProperty,
172                    boolean merge)
173                    throws com.liferay.portal.kernel.exception.SystemException {
174                    return getPersistence().updateImpl(assetCategoryProperty, merge);
175            }
176    
177            /**
178            * Returns the asset category property with the primary key or throws a {@link com.liferay.portlet.asset.NoSuchCategoryPropertyException} if it could not be found.
179            *
180            * @param categoryPropertyId the primary key of the asset category property
181            * @return the asset category property
182            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a asset category property with the primary key could not be found
183            * @throws SystemException if a system exception occurred
184            */
185            public static com.liferay.portlet.asset.model.AssetCategoryProperty findByPrimaryKey(
186                    long categoryPropertyId)
187                    throws com.liferay.portal.kernel.exception.SystemException,
188                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
189                    return getPersistence().findByPrimaryKey(categoryPropertyId);
190            }
191    
192            /**
193            * Returns the asset category property with the primary key or returns <code>null</code> if it could not be found.
194            *
195            * @param categoryPropertyId the primary key of the asset category property
196            * @return the asset category property, or <code>null</code> if a asset category property with the primary key could not be found
197            * @throws SystemException if a system exception occurred
198            */
199            public static com.liferay.portlet.asset.model.AssetCategoryProperty fetchByPrimaryKey(
200                    long categoryPropertyId)
201                    throws com.liferay.portal.kernel.exception.SystemException {
202                    return getPersistence().fetchByPrimaryKey(categoryPropertyId);
203            }
204    
205            /**
206            * Returns all the asset category properties where companyId = &#63;.
207            *
208            * @param companyId the company ID
209            * @return the matching asset category properties
210            * @throws SystemException if a system exception occurred
211            */
212            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findByCompanyId(
213                    long companyId)
214                    throws com.liferay.portal.kernel.exception.SystemException {
215                    return getPersistence().findByCompanyId(companyId);
216            }
217    
218            /**
219            * Returns a range of all the asset category properties where companyId = &#63;.
220            *
221            * <p>
222            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
223            * </p>
224            *
225            * @param companyId the company ID
226            * @param start the lower bound of the range of asset category properties
227            * @param end the upper bound of the range of asset category properties (not inclusive)
228            * @return the range of matching asset category properties
229            * @throws SystemException if a system exception occurred
230            */
231            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findByCompanyId(
232                    long companyId, int start, int end)
233                    throws com.liferay.portal.kernel.exception.SystemException {
234                    return getPersistence().findByCompanyId(companyId, start, end);
235            }
236    
237            /**
238            * Returns an ordered range of all the asset category properties where companyId = &#63;.
239            *
240            * <p>
241            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
242            * </p>
243            *
244            * @param companyId the company ID
245            * @param start the lower bound of the range of asset category properties
246            * @param end the upper bound of the range of asset category properties (not inclusive)
247            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
248            * @return the ordered range of matching asset category properties
249            * @throws SystemException if a system exception occurred
250            */
251            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findByCompanyId(
252                    long companyId, int start, int end,
253                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
254                    throws com.liferay.portal.kernel.exception.SystemException {
255                    return getPersistence()
256                                       .findByCompanyId(companyId, start, end, orderByComparator);
257            }
258    
259            /**
260            * Returns the first asset category property in the ordered set where companyId = &#63;.
261            *
262            * <p>
263            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
264            * </p>
265            *
266            * @param companyId the company ID
267            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
268            * @return the first matching asset category property
269            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a matching asset category property could not be found
270            * @throws SystemException if a system exception occurred
271            */
272            public static com.liferay.portlet.asset.model.AssetCategoryProperty findByCompanyId_First(
273                    long companyId,
274                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
275                    throws com.liferay.portal.kernel.exception.SystemException,
276                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
277                    return getPersistence()
278                                       .findByCompanyId_First(companyId, orderByComparator);
279            }
280    
281            /**
282            * Returns the last asset category property in the ordered set where companyId = &#63;.
283            *
284            * <p>
285            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
286            * </p>
287            *
288            * @param companyId the company ID
289            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
290            * @return the last matching asset category property
291            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a matching asset category property could not be found
292            * @throws SystemException if a system exception occurred
293            */
294            public static com.liferay.portlet.asset.model.AssetCategoryProperty findByCompanyId_Last(
295                    long companyId,
296                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
297                    throws com.liferay.portal.kernel.exception.SystemException,
298                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
299                    return getPersistence()
300                                       .findByCompanyId_Last(companyId, orderByComparator);
301            }
302    
303            /**
304            * Returns the asset category properties before and after the current asset category property in the ordered set where companyId = &#63;.
305            *
306            * <p>
307            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
308            * </p>
309            *
310            * @param categoryPropertyId the primary key of the current asset category property
311            * @param companyId the company ID
312            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
313            * @return the previous, current, and next asset category property
314            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a asset category property with the primary key could not be found
315            * @throws SystemException if a system exception occurred
316            */
317            public static com.liferay.portlet.asset.model.AssetCategoryProperty[] findByCompanyId_PrevAndNext(
318                    long categoryPropertyId, long companyId,
319                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
320                    throws com.liferay.portal.kernel.exception.SystemException,
321                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
322                    return getPersistence()
323                                       .findByCompanyId_PrevAndNext(categoryPropertyId, companyId,
324                            orderByComparator);
325            }
326    
327            /**
328            * Returns all the asset category properties where categoryId = &#63;.
329            *
330            * @param categoryId the category ID
331            * @return the matching asset category properties
332            * @throws SystemException if a system exception occurred
333            */
334            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findByCategoryId(
335                    long categoryId)
336                    throws com.liferay.portal.kernel.exception.SystemException {
337                    return getPersistence().findByCategoryId(categoryId);
338            }
339    
340            /**
341            * Returns a range of all the asset category properties where categoryId = &#63;.
342            *
343            * <p>
344            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
345            * </p>
346            *
347            * @param categoryId the category ID
348            * @param start the lower bound of the range of asset category properties
349            * @param end the upper bound of the range of asset category properties (not inclusive)
350            * @return the range of matching asset category properties
351            * @throws SystemException if a system exception occurred
352            */
353            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findByCategoryId(
354                    long categoryId, int start, int end)
355                    throws com.liferay.portal.kernel.exception.SystemException {
356                    return getPersistence().findByCategoryId(categoryId, start, end);
357            }
358    
359            /**
360            * Returns an ordered range of all the asset category properties where categoryId = &#63;.
361            *
362            * <p>
363            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
364            * </p>
365            *
366            * @param categoryId the category ID
367            * @param start the lower bound of the range of asset category properties
368            * @param end the upper bound of the range of asset category properties (not inclusive)
369            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
370            * @return the ordered range of matching asset category properties
371            * @throws SystemException if a system exception occurred
372            */
373            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findByCategoryId(
374                    long categoryId, int start, int end,
375                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
376                    throws com.liferay.portal.kernel.exception.SystemException {
377                    return getPersistence()
378                                       .findByCategoryId(categoryId, start, end, orderByComparator);
379            }
380    
381            /**
382            * Returns the first asset category property in the ordered set where categoryId = &#63;.
383            *
384            * <p>
385            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
386            * </p>
387            *
388            * @param categoryId the category ID
389            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
390            * @return the first matching asset category property
391            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a matching asset category property could not be found
392            * @throws SystemException if a system exception occurred
393            */
394            public static com.liferay.portlet.asset.model.AssetCategoryProperty findByCategoryId_First(
395                    long categoryId,
396                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
397                    throws com.liferay.portal.kernel.exception.SystemException,
398                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
399                    return getPersistence()
400                                       .findByCategoryId_First(categoryId, orderByComparator);
401            }
402    
403            /**
404            * Returns the last asset category property in the ordered set where categoryId = &#63;.
405            *
406            * <p>
407            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
408            * </p>
409            *
410            * @param categoryId the category ID
411            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
412            * @return the last matching asset category property
413            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a matching asset category property could not be found
414            * @throws SystemException if a system exception occurred
415            */
416            public static com.liferay.portlet.asset.model.AssetCategoryProperty findByCategoryId_Last(
417                    long categoryId,
418                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
419                    throws com.liferay.portal.kernel.exception.SystemException,
420                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
421                    return getPersistence()
422                                       .findByCategoryId_Last(categoryId, orderByComparator);
423            }
424    
425            /**
426            * Returns the asset category properties before and after the current asset category property in the ordered set where categoryId = &#63;.
427            *
428            * <p>
429            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
430            * </p>
431            *
432            * @param categoryPropertyId the primary key of the current asset category property
433            * @param categoryId the category ID
434            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
435            * @return the previous, current, and next asset category property
436            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a asset category property with the primary key could not be found
437            * @throws SystemException if a system exception occurred
438            */
439            public static com.liferay.portlet.asset.model.AssetCategoryProperty[] findByCategoryId_PrevAndNext(
440                    long categoryPropertyId, long categoryId,
441                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
442                    throws com.liferay.portal.kernel.exception.SystemException,
443                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
444                    return getPersistence()
445                                       .findByCategoryId_PrevAndNext(categoryPropertyId,
446                            categoryId, orderByComparator);
447            }
448    
449            /**
450            * Returns all the asset category properties where companyId = &#63; and key = &#63;.
451            *
452            * @param companyId the company ID
453            * @param key the key
454            * @return the matching asset category properties
455            * @throws SystemException if a system exception occurred
456            */
457            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findByC_K(
458                    long companyId, java.lang.String key)
459                    throws com.liferay.portal.kernel.exception.SystemException {
460                    return getPersistence().findByC_K(companyId, key);
461            }
462    
463            /**
464            * Returns a range of all the asset category properties where companyId = &#63; and key = &#63;.
465            *
466            * <p>
467            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
468            * </p>
469            *
470            * @param companyId the company ID
471            * @param key the key
472            * @param start the lower bound of the range of asset category properties
473            * @param end the upper bound of the range of asset category properties (not inclusive)
474            * @return the range of matching asset category properties
475            * @throws SystemException if a system exception occurred
476            */
477            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findByC_K(
478                    long companyId, java.lang.String key, int start, int end)
479                    throws com.liferay.portal.kernel.exception.SystemException {
480                    return getPersistence().findByC_K(companyId, key, start, end);
481            }
482    
483            /**
484            * Returns an ordered range of all the asset category properties where companyId = &#63; and key = &#63;.
485            *
486            * <p>
487            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
488            * </p>
489            *
490            * @param companyId the company ID
491            * @param key the key
492            * @param start the lower bound of the range of asset category properties
493            * @param end the upper bound of the range of asset category properties (not inclusive)
494            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
495            * @return the ordered range of matching asset category properties
496            * @throws SystemException if a system exception occurred
497            */
498            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findByC_K(
499                    long companyId, java.lang.String key, int start, int end,
500                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
501                    throws com.liferay.portal.kernel.exception.SystemException {
502                    return getPersistence()
503                                       .findByC_K(companyId, key, start, end, orderByComparator);
504            }
505    
506            /**
507            * Returns the first asset category property in the ordered set where companyId = &#63; and key = &#63;.
508            *
509            * <p>
510            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
511            * </p>
512            *
513            * @param companyId the company ID
514            * @param key the key
515            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
516            * @return the first matching asset category property
517            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a matching asset category property could not be found
518            * @throws SystemException if a system exception occurred
519            */
520            public static com.liferay.portlet.asset.model.AssetCategoryProperty findByC_K_First(
521                    long companyId, java.lang.String key,
522                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
523                    throws com.liferay.portal.kernel.exception.SystemException,
524                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
525                    return getPersistence()
526                                       .findByC_K_First(companyId, key, orderByComparator);
527            }
528    
529            /**
530            * Returns the last asset category property in the ordered set where companyId = &#63; and key = &#63;.
531            *
532            * <p>
533            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
534            * </p>
535            *
536            * @param companyId the company ID
537            * @param key the key
538            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
539            * @return the last matching asset category property
540            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a matching asset category property could not be found
541            * @throws SystemException if a system exception occurred
542            */
543            public static com.liferay.portlet.asset.model.AssetCategoryProperty findByC_K_Last(
544                    long companyId, java.lang.String key,
545                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
546                    throws com.liferay.portal.kernel.exception.SystemException,
547                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
548                    return getPersistence().findByC_K_Last(companyId, key, orderByComparator);
549            }
550    
551            /**
552            * Returns the asset category properties before and after the current asset category property in the ordered set where companyId = &#63; and key = &#63;.
553            *
554            * <p>
555            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
556            * </p>
557            *
558            * @param categoryPropertyId the primary key of the current asset category property
559            * @param companyId the company ID
560            * @param key the key
561            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
562            * @return the previous, current, and next asset category property
563            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a asset category property with the primary key could not be found
564            * @throws SystemException if a system exception occurred
565            */
566            public static com.liferay.portlet.asset.model.AssetCategoryProperty[] findByC_K_PrevAndNext(
567                    long categoryPropertyId, long companyId, java.lang.String key,
568                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
569                    throws com.liferay.portal.kernel.exception.SystemException,
570                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
571                    return getPersistence()
572                                       .findByC_K_PrevAndNext(categoryPropertyId, companyId, key,
573                            orderByComparator);
574            }
575    
576            /**
577            * Returns the asset category property where categoryId = &#63; and key = &#63; or throws a {@link com.liferay.portlet.asset.NoSuchCategoryPropertyException} if it could not be found.
578            *
579            * @param categoryId the category ID
580            * @param key the key
581            * @return the matching asset category property
582            * @throws com.liferay.portlet.asset.NoSuchCategoryPropertyException if a matching asset category property could not be found
583            * @throws SystemException if a system exception occurred
584            */
585            public static com.liferay.portlet.asset.model.AssetCategoryProperty findByCA_K(
586                    long categoryId, java.lang.String key)
587                    throws com.liferay.portal.kernel.exception.SystemException,
588                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
589                    return getPersistence().findByCA_K(categoryId, key);
590            }
591    
592            /**
593            * Returns the asset category property where categoryId = &#63; and key = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
594            *
595            * @param categoryId the category ID
596            * @param key the key
597            * @return the matching asset category property, or <code>null</code> if a matching asset category property could not be found
598            * @throws SystemException if a system exception occurred
599            */
600            public static com.liferay.portlet.asset.model.AssetCategoryProperty fetchByCA_K(
601                    long categoryId, java.lang.String key)
602                    throws com.liferay.portal.kernel.exception.SystemException {
603                    return getPersistence().fetchByCA_K(categoryId, key);
604            }
605    
606            /**
607            * Returns the asset category property where categoryId = &#63; and key = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
608            *
609            * @param categoryId the category ID
610            * @param key the key
611            * @param retrieveFromCache whether to use the finder cache
612            * @return the matching asset category property, or <code>null</code> if a matching asset category property could not be found
613            * @throws SystemException if a system exception occurred
614            */
615            public static com.liferay.portlet.asset.model.AssetCategoryProperty fetchByCA_K(
616                    long categoryId, java.lang.String key, boolean retrieveFromCache)
617                    throws com.liferay.portal.kernel.exception.SystemException {
618                    return getPersistence().fetchByCA_K(categoryId, key, retrieveFromCache);
619            }
620    
621            /**
622            * Returns all the asset category properties.
623            *
624            * @return the asset category properties
625            * @throws SystemException if a system exception occurred
626            */
627            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findAll()
628                    throws com.liferay.portal.kernel.exception.SystemException {
629                    return getPersistence().findAll();
630            }
631    
632            /**
633            * Returns a range of all the asset category properties.
634            *
635            * <p>
636            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
637            * </p>
638            *
639            * @param start the lower bound of the range of asset category properties
640            * @param end the upper bound of the range of asset category properties (not inclusive)
641            * @return the range of asset category properties
642            * @throws SystemException if a system exception occurred
643            */
644            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findAll(
645                    int start, int end)
646                    throws com.liferay.portal.kernel.exception.SystemException {
647                    return getPersistence().findAll(start, end);
648            }
649    
650            /**
651            * Returns an ordered range of all the asset category properties.
652            *
653            * <p>
654            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
655            * </p>
656            *
657            * @param start the lower bound of the range of asset category properties
658            * @param end the upper bound of the range of asset category properties (not inclusive)
659            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
660            * @return the ordered range of asset category properties
661            * @throws SystemException if a system exception occurred
662            */
663            public static java.util.List<com.liferay.portlet.asset.model.AssetCategoryProperty> findAll(
664                    int start, int end,
665                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
666                    throws com.liferay.portal.kernel.exception.SystemException {
667                    return getPersistence().findAll(start, end, orderByComparator);
668            }
669    
670            /**
671            * Removes all the asset category properties where companyId = &#63; from the database.
672            *
673            * @param companyId the company ID
674            * @throws SystemException if a system exception occurred
675            */
676            public static void removeByCompanyId(long companyId)
677                    throws com.liferay.portal.kernel.exception.SystemException {
678                    getPersistence().removeByCompanyId(companyId);
679            }
680    
681            /**
682            * Removes all the asset category properties where categoryId = &#63; from the database.
683            *
684            * @param categoryId the category ID
685            * @throws SystemException if a system exception occurred
686            */
687            public static void removeByCategoryId(long categoryId)
688                    throws com.liferay.portal.kernel.exception.SystemException {
689                    getPersistence().removeByCategoryId(categoryId);
690            }
691    
692            /**
693            * Removes all the asset category properties where companyId = &#63; and key = &#63; from the database.
694            *
695            * @param companyId the company ID
696            * @param key the key
697            * @throws SystemException if a system exception occurred
698            */
699            public static void removeByC_K(long companyId, java.lang.String key)
700                    throws com.liferay.portal.kernel.exception.SystemException {
701                    getPersistence().removeByC_K(companyId, key);
702            }
703    
704            /**
705            * Removes the asset category property where categoryId = &#63; and key = &#63; from the database.
706            *
707            * @param categoryId the category ID
708            * @param key the key
709            * @throws SystemException if a system exception occurred
710            */
711            public static void removeByCA_K(long categoryId, java.lang.String key)
712                    throws com.liferay.portal.kernel.exception.SystemException,
713                            com.liferay.portlet.asset.NoSuchCategoryPropertyException {
714                    getPersistence().removeByCA_K(categoryId, key);
715            }
716    
717            /**
718            * Removes all the asset category properties from the database.
719            *
720            * @throws SystemException if a system exception occurred
721            */
722            public static void removeAll()
723                    throws com.liferay.portal.kernel.exception.SystemException {
724                    getPersistence().removeAll();
725            }
726    
727            /**
728            * Returns the number of asset category properties where companyId = &#63;.
729            *
730            * @param companyId the company ID
731            * @return the number of matching asset category properties
732            * @throws SystemException if a system exception occurred
733            */
734            public static int countByCompanyId(long companyId)
735                    throws com.liferay.portal.kernel.exception.SystemException {
736                    return getPersistence().countByCompanyId(companyId);
737            }
738    
739            /**
740            * Returns the number of asset category properties where categoryId = &#63;.
741            *
742            * @param categoryId the category ID
743            * @return the number of matching asset category properties
744            * @throws SystemException if a system exception occurred
745            */
746            public static int countByCategoryId(long categoryId)
747                    throws com.liferay.portal.kernel.exception.SystemException {
748                    return getPersistence().countByCategoryId(categoryId);
749            }
750    
751            /**
752            * Returns the number of asset category properties where companyId = &#63; and key = &#63;.
753            *
754            * @param companyId the company ID
755            * @param key the key
756            * @return the number of matching asset category properties
757            * @throws SystemException if a system exception occurred
758            */
759            public static int countByC_K(long companyId, java.lang.String key)
760                    throws com.liferay.portal.kernel.exception.SystemException {
761                    return getPersistence().countByC_K(companyId, key);
762            }
763    
764            /**
765            * Returns the number of asset category properties where categoryId = &#63; and key = &#63;.
766            *
767            * @param categoryId the category ID
768            * @param key the key
769            * @return the number of matching asset category properties
770            * @throws SystemException if a system exception occurred
771            */
772            public static int countByCA_K(long categoryId, java.lang.String key)
773                    throws com.liferay.portal.kernel.exception.SystemException {
774                    return getPersistence().countByCA_K(categoryId, key);
775            }
776    
777            /**
778            * Returns the number of asset category properties.
779            *
780            * @return the number of asset category properties
781            * @throws SystemException if a system exception occurred
782            */
783            public static int countAll()
784                    throws com.liferay.portal.kernel.exception.SystemException {
785                    return getPersistence().countAll();
786            }
787    
788            public static AssetCategoryPropertyPersistence getPersistence() {
789                    if (_persistence == null) {
790                            _persistence = (AssetCategoryPropertyPersistence)PortalBeanLocatorUtil.locate(AssetCategoryPropertyPersistence.class.getName());
791    
792                            ReferenceRegistry.registerReference(AssetCategoryPropertyUtil.class,
793                                    "_persistence");
794                    }
795    
796                    return _persistence;
797            }
798    
799            public void setPersistence(AssetCategoryPropertyPersistence persistence) {
800                    _persistence = persistence;
801    
802                    ReferenceRegistry.registerReference(AssetCategoryPropertyUtil.class,
803                            "_persistence");
804            }
805    
806            private static AssetCategoryPropertyPersistence _persistence;
807    }