001    /**
002     * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portlet.softwarecatalog.service.persistence;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
020    import com.liferay.portal.kernel.dao.orm.DynamicQuery;
021    import com.liferay.portal.kernel.util.OrderByComparator;
022    import com.liferay.portal.kernel.util.ReferenceRegistry;
023    import com.liferay.portal.service.ServiceContext;
024    
025    import com.liferay.portlet.softwarecatalog.model.SCLicense;
026    
027    import java.util.List;
028    
029    /**
030     * The persistence utility for the s c license service. This utility wraps {@link SCLicensePersistenceImpl} 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.
031     *
032     * <p>
033     * Caching information and settings can be found in <code>portal.properties</code>
034     * </p>
035     *
036     * @author Brian Wing Shun Chan
037     * @see SCLicensePersistence
038     * @see SCLicensePersistenceImpl
039     * @generated
040     */
041    @ProviderType
042    public class SCLicenseUtil {
043            /*
044             * NOTE FOR DEVELOPERS:
045             *
046             * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class.
047             */
048    
049            /**
050             * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
051             */
052            public static void clearCache() {
053                    getPersistence().clearCache();
054            }
055    
056            /**
057             * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel)
058             */
059            public static void clearCache(SCLicense scLicense) {
060                    getPersistence().clearCache(scLicense);
061            }
062    
063            /**
064             * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery)
065             */
066            public static long countWithDynamicQuery(DynamicQuery dynamicQuery) {
067                    return getPersistence().countWithDynamicQuery(dynamicQuery);
068            }
069    
070            /**
071             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
072             */
073            public static List<SCLicense> findWithDynamicQuery(
074                    DynamicQuery dynamicQuery) {
075                    return getPersistence().findWithDynamicQuery(dynamicQuery);
076            }
077    
078            /**
079             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
080             */
081            public static List<SCLicense> findWithDynamicQuery(
082                    DynamicQuery dynamicQuery, int start, int end) {
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<SCLicense> findWithDynamicQuery(
090                    DynamicQuery dynamicQuery, int start, int end,
091                    OrderByComparator<SCLicense> orderByComparator) {
092                    return getPersistence()
093                                       .findWithDynamicQuery(dynamicQuery, start, end,
094                            orderByComparator);
095            }
096    
097            /**
098             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel)
099             */
100            public static SCLicense update(SCLicense scLicense) {
101                    return getPersistence().update(scLicense);
102            }
103    
104            /**
105             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext)
106             */
107            public static SCLicense update(SCLicense scLicense,
108                    ServiceContext serviceContext) {
109                    return getPersistence().update(scLicense, serviceContext);
110            }
111    
112            /**
113            * Returns all the s c licenses where active = &#63;.
114            *
115            * @param active the active
116            * @return the matching s c licenses
117            */
118            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> findByActive(
119                    boolean active) {
120                    return getPersistence().findByActive(active);
121            }
122    
123            /**
124            * Returns a range of all the s c licenses where active = &#63;.
125            *
126            * <p>
127            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
128            * </p>
129            *
130            * @param active the active
131            * @param start the lower bound of the range of s c licenses
132            * @param end the upper bound of the range of s c licenses (not inclusive)
133            * @return the range of matching s c licenses
134            */
135            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> findByActive(
136                    boolean active, int start, int end) {
137                    return getPersistence().findByActive(active, start, end);
138            }
139    
140            /**
141            * Returns an ordered range of all the s c licenses where active = &#63;.
142            *
143            * <p>
144            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
145            * </p>
146            *
147            * @param active the active
148            * @param start the lower bound of the range of s c licenses
149            * @param end the upper bound of the range of s c licenses (not inclusive)
150            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
151            * @return the ordered range of matching s c licenses
152            */
153            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> findByActive(
154                    boolean active, int start, int end,
155                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator) {
156                    return getPersistence()
157                                       .findByActive(active, start, end, orderByComparator);
158            }
159    
160            /**
161            * Returns the first s c license in the ordered set where active = &#63;.
162            *
163            * @param active the active
164            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
165            * @return the first matching s c license
166            * @throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException if a matching s c license could not be found
167            */
168            public static com.liferay.portlet.softwarecatalog.model.SCLicense findByActive_First(
169                    boolean active,
170                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator)
171                    throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException {
172                    return getPersistence().findByActive_First(active, orderByComparator);
173            }
174    
175            /**
176            * Returns the first s c license in the ordered set where active = &#63;.
177            *
178            * @param active the active
179            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
180            * @return the first matching s c license, or <code>null</code> if a matching s c license could not be found
181            */
182            public static com.liferay.portlet.softwarecatalog.model.SCLicense fetchByActive_First(
183                    boolean active,
184                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator) {
185                    return getPersistence().fetchByActive_First(active, orderByComparator);
186            }
187    
188            /**
189            * Returns the last s c license in the ordered set where active = &#63;.
190            *
191            * @param active the active
192            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
193            * @return the last matching s c license
194            * @throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException if a matching s c license could not be found
195            */
196            public static com.liferay.portlet.softwarecatalog.model.SCLicense findByActive_Last(
197                    boolean active,
198                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator)
199                    throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException {
200                    return getPersistence().findByActive_Last(active, orderByComparator);
201            }
202    
203            /**
204            * Returns the last s c license in the ordered set where active = &#63;.
205            *
206            * @param active the active
207            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
208            * @return the last matching s c license, or <code>null</code> if a matching s c license could not be found
209            */
210            public static com.liferay.portlet.softwarecatalog.model.SCLicense fetchByActive_Last(
211                    boolean active,
212                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator) {
213                    return getPersistence().fetchByActive_Last(active, orderByComparator);
214            }
215    
216            /**
217            * Returns the s c licenses before and after the current s c license in the ordered set where active = &#63;.
218            *
219            * @param licenseId the primary key of the current s c license
220            * @param active the active
221            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
222            * @return the previous, current, and next s c license
223            * @throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException if a s c license with the primary key could not be found
224            */
225            public static com.liferay.portlet.softwarecatalog.model.SCLicense[] findByActive_PrevAndNext(
226                    long licenseId, boolean active,
227                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator)
228                    throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException {
229                    return getPersistence()
230                                       .findByActive_PrevAndNext(licenseId, active,
231                            orderByComparator);
232            }
233    
234            /**
235            * Returns all the s c licenses that the user has permission to view where active = &#63;.
236            *
237            * @param active the active
238            * @return the matching s c licenses that the user has permission to view
239            */
240            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> filterFindByActive(
241                    boolean active) {
242                    return getPersistence().filterFindByActive(active);
243            }
244    
245            /**
246            * Returns a range of all the s c licenses that the user has permission to view where active = &#63;.
247            *
248            * <p>
249            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
250            * </p>
251            *
252            * @param active the active
253            * @param start the lower bound of the range of s c licenses
254            * @param end the upper bound of the range of s c licenses (not inclusive)
255            * @return the range of matching s c licenses that the user has permission to view
256            */
257            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> filterFindByActive(
258                    boolean active, int start, int end) {
259                    return getPersistence().filterFindByActive(active, start, end);
260            }
261    
262            /**
263            * Returns an ordered range of all the s c licenses that the user has permissions to view where active = &#63;.
264            *
265            * <p>
266            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
267            * </p>
268            *
269            * @param active the active
270            * @param start the lower bound of the range of s c licenses
271            * @param end the upper bound of the range of s c licenses (not inclusive)
272            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
273            * @return the ordered range of matching s c licenses that the user has permission to view
274            */
275            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> filterFindByActive(
276                    boolean active, int start, int end,
277                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator) {
278                    return getPersistence()
279                                       .filterFindByActive(active, start, end, orderByComparator);
280            }
281    
282            /**
283            * Returns the s c licenses before and after the current s c license in the ordered set of s c licenses that the user has permission to view where active = &#63;.
284            *
285            * @param licenseId the primary key of the current s c license
286            * @param active the active
287            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
288            * @return the previous, current, and next s c license
289            * @throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException if a s c license with the primary key could not be found
290            */
291            public static com.liferay.portlet.softwarecatalog.model.SCLicense[] filterFindByActive_PrevAndNext(
292                    long licenseId, boolean active,
293                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator)
294                    throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException {
295                    return getPersistence()
296                                       .filterFindByActive_PrevAndNext(licenseId, active,
297                            orderByComparator);
298            }
299    
300            /**
301            * Removes all the s c licenses where active = &#63; from the database.
302            *
303            * @param active the active
304            */
305            public static void removeByActive(boolean active) {
306                    getPersistence().removeByActive(active);
307            }
308    
309            /**
310            * Returns the number of s c licenses where active = &#63;.
311            *
312            * @param active the active
313            * @return the number of matching s c licenses
314            */
315            public static int countByActive(boolean active) {
316                    return getPersistence().countByActive(active);
317            }
318    
319            /**
320            * Returns the number of s c licenses that the user has permission to view where active = &#63;.
321            *
322            * @param active the active
323            * @return the number of matching s c licenses that the user has permission to view
324            */
325            public static int filterCountByActive(boolean active) {
326                    return getPersistence().filterCountByActive(active);
327            }
328    
329            /**
330            * Returns all the s c licenses where active = &#63; and recommended = &#63;.
331            *
332            * @param active the active
333            * @param recommended the recommended
334            * @return the matching s c licenses
335            */
336            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> findByA_R(
337                    boolean active, boolean recommended) {
338                    return getPersistence().findByA_R(active, recommended);
339            }
340    
341            /**
342            * Returns a range of all the s c licenses where active = &#63; and recommended = &#63;.
343            *
344            * <p>
345            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
346            * </p>
347            *
348            * @param active the active
349            * @param recommended the recommended
350            * @param start the lower bound of the range of s c licenses
351            * @param end the upper bound of the range of s c licenses (not inclusive)
352            * @return the range of matching s c licenses
353            */
354            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> findByA_R(
355                    boolean active, boolean recommended, int start, int end) {
356                    return getPersistence().findByA_R(active, recommended, start, end);
357            }
358    
359            /**
360            * Returns an ordered range of all the s c licenses where active = &#63; and recommended = &#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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
364            * </p>
365            *
366            * @param active the active
367            * @param recommended the recommended
368            * @param start the lower bound of the range of s c licenses
369            * @param end the upper bound of the range of s c licenses (not inclusive)
370            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
371            * @return the ordered range of matching s c licenses
372            */
373            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> findByA_R(
374                    boolean active, boolean recommended, int start, int end,
375                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator) {
376                    return getPersistence()
377                                       .findByA_R(active, recommended, start, end, orderByComparator);
378            }
379    
380            /**
381            * Returns the first s c license in the ordered set where active = &#63; and recommended = &#63;.
382            *
383            * @param active the active
384            * @param recommended the recommended
385            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
386            * @return the first matching s c license
387            * @throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException if a matching s c license could not be found
388            */
389            public static com.liferay.portlet.softwarecatalog.model.SCLicense findByA_R_First(
390                    boolean active, boolean recommended,
391                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator)
392                    throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException {
393                    return getPersistence()
394                                       .findByA_R_First(active, recommended, orderByComparator);
395            }
396    
397            /**
398            * Returns the first s c license in the ordered set where active = &#63; and recommended = &#63;.
399            *
400            * @param active the active
401            * @param recommended the recommended
402            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
403            * @return the first matching s c license, or <code>null</code> if a matching s c license could not be found
404            */
405            public static com.liferay.portlet.softwarecatalog.model.SCLicense fetchByA_R_First(
406                    boolean active, boolean recommended,
407                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator) {
408                    return getPersistence()
409                                       .fetchByA_R_First(active, recommended, orderByComparator);
410            }
411    
412            /**
413            * Returns the last s c license in the ordered set where active = &#63; and recommended = &#63;.
414            *
415            * @param active the active
416            * @param recommended the recommended
417            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
418            * @return the last matching s c license
419            * @throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException if a matching s c license could not be found
420            */
421            public static com.liferay.portlet.softwarecatalog.model.SCLicense findByA_R_Last(
422                    boolean active, boolean recommended,
423                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator)
424                    throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException {
425                    return getPersistence()
426                                       .findByA_R_Last(active, recommended, orderByComparator);
427            }
428    
429            /**
430            * Returns the last s c license in the ordered set where active = &#63; and recommended = &#63;.
431            *
432            * @param active the active
433            * @param recommended the recommended
434            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
435            * @return the last matching s c license, or <code>null</code> if a matching s c license could not be found
436            */
437            public static com.liferay.portlet.softwarecatalog.model.SCLicense fetchByA_R_Last(
438                    boolean active, boolean recommended,
439                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator) {
440                    return getPersistence()
441                                       .fetchByA_R_Last(active, recommended, orderByComparator);
442            }
443    
444            /**
445            * Returns the s c licenses before and after the current s c license in the ordered set where active = &#63; and recommended = &#63;.
446            *
447            * @param licenseId the primary key of the current s c license
448            * @param active the active
449            * @param recommended the recommended
450            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
451            * @return the previous, current, and next s c license
452            * @throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException if a s c license with the primary key could not be found
453            */
454            public static com.liferay.portlet.softwarecatalog.model.SCLicense[] findByA_R_PrevAndNext(
455                    long licenseId, boolean active, boolean recommended,
456                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator)
457                    throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException {
458                    return getPersistence()
459                                       .findByA_R_PrevAndNext(licenseId, active, recommended,
460                            orderByComparator);
461            }
462    
463            /**
464            * Returns all the s c licenses that the user has permission to view where active = &#63; and recommended = &#63;.
465            *
466            * @param active the active
467            * @param recommended the recommended
468            * @return the matching s c licenses that the user has permission to view
469            */
470            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> filterFindByA_R(
471                    boolean active, boolean recommended) {
472                    return getPersistence().filterFindByA_R(active, recommended);
473            }
474    
475            /**
476            * Returns a range of all the s c licenses that the user has permission to view where active = &#63; and recommended = &#63;.
477            *
478            * <p>
479            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
480            * </p>
481            *
482            * @param active the active
483            * @param recommended the recommended
484            * @param start the lower bound of the range of s c licenses
485            * @param end the upper bound of the range of s c licenses (not inclusive)
486            * @return the range of matching s c licenses that the user has permission to view
487            */
488            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> filterFindByA_R(
489                    boolean active, boolean recommended, int start, int end) {
490                    return getPersistence().filterFindByA_R(active, recommended, start, end);
491            }
492    
493            /**
494            * Returns an ordered range of all the s c licenses that the user has permissions to view where active = &#63; and recommended = &#63;.
495            *
496            * <p>
497            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
498            * </p>
499            *
500            * @param active the active
501            * @param recommended the recommended
502            * @param start the lower bound of the range of s c licenses
503            * @param end the upper bound of the range of s c licenses (not inclusive)
504            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
505            * @return the ordered range of matching s c licenses that the user has permission to view
506            */
507            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> filterFindByA_R(
508                    boolean active, boolean recommended, int start, int end,
509                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator) {
510                    return getPersistence()
511                                       .filterFindByA_R(active, recommended, start, end,
512                            orderByComparator);
513            }
514    
515            /**
516            * Returns the s c licenses before and after the current s c license in the ordered set of s c licenses that the user has permission to view where active = &#63; and recommended = &#63;.
517            *
518            * @param licenseId the primary key of the current s c license
519            * @param active the active
520            * @param recommended the recommended
521            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
522            * @return the previous, current, and next s c license
523            * @throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException if a s c license with the primary key could not be found
524            */
525            public static com.liferay.portlet.softwarecatalog.model.SCLicense[] filterFindByA_R_PrevAndNext(
526                    long licenseId, boolean active, boolean recommended,
527                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator)
528                    throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException {
529                    return getPersistence()
530                                       .filterFindByA_R_PrevAndNext(licenseId, active, recommended,
531                            orderByComparator);
532            }
533    
534            /**
535            * Removes all the s c licenses where active = &#63; and recommended = &#63; from the database.
536            *
537            * @param active the active
538            * @param recommended the recommended
539            */
540            public static void removeByA_R(boolean active, boolean recommended) {
541                    getPersistence().removeByA_R(active, recommended);
542            }
543    
544            /**
545            * Returns the number of s c licenses where active = &#63; and recommended = &#63;.
546            *
547            * @param active the active
548            * @param recommended the recommended
549            * @return the number of matching s c licenses
550            */
551            public static int countByA_R(boolean active, boolean recommended) {
552                    return getPersistence().countByA_R(active, recommended);
553            }
554    
555            /**
556            * Returns the number of s c licenses that the user has permission to view where active = &#63; and recommended = &#63;.
557            *
558            * @param active the active
559            * @param recommended the recommended
560            * @return the number of matching s c licenses that the user has permission to view
561            */
562            public static int filterCountByA_R(boolean active, boolean recommended) {
563                    return getPersistence().filterCountByA_R(active, recommended);
564            }
565    
566            /**
567            * Caches the s c license in the entity cache if it is enabled.
568            *
569            * @param scLicense the s c license
570            */
571            public static void cacheResult(
572                    com.liferay.portlet.softwarecatalog.model.SCLicense scLicense) {
573                    getPersistence().cacheResult(scLicense);
574            }
575    
576            /**
577            * Caches the s c licenses in the entity cache if it is enabled.
578            *
579            * @param scLicenses the s c licenses
580            */
581            public static void cacheResult(
582                    java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> scLicenses) {
583                    getPersistence().cacheResult(scLicenses);
584            }
585    
586            /**
587            * Creates a new s c license with the primary key. Does not add the s c license to the database.
588            *
589            * @param licenseId the primary key for the new s c license
590            * @return the new s c license
591            */
592            public static com.liferay.portlet.softwarecatalog.model.SCLicense create(
593                    long licenseId) {
594                    return getPersistence().create(licenseId);
595            }
596    
597            /**
598            * Removes the s c license with the primary key from the database. Also notifies the appropriate model listeners.
599            *
600            * @param licenseId the primary key of the s c license
601            * @return the s c license that was removed
602            * @throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException if a s c license with the primary key could not be found
603            */
604            public static com.liferay.portlet.softwarecatalog.model.SCLicense remove(
605                    long licenseId)
606                    throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException {
607                    return getPersistence().remove(licenseId);
608            }
609    
610            public static com.liferay.portlet.softwarecatalog.model.SCLicense updateImpl(
611                    com.liferay.portlet.softwarecatalog.model.SCLicense scLicense) {
612                    return getPersistence().updateImpl(scLicense);
613            }
614    
615            /**
616            * Returns the s c license with the primary key or throws a {@link com.liferay.portlet.softwarecatalog.NoSuchLicenseException} if it could not be found.
617            *
618            * @param licenseId the primary key of the s c license
619            * @return the s c license
620            * @throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException if a s c license with the primary key could not be found
621            */
622            public static com.liferay.portlet.softwarecatalog.model.SCLicense findByPrimaryKey(
623                    long licenseId)
624                    throws com.liferay.portlet.softwarecatalog.NoSuchLicenseException {
625                    return getPersistence().findByPrimaryKey(licenseId);
626            }
627    
628            /**
629            * Returns the s c license with the primary key or returns <code>null</code> if it could not be found.
630            *
631            * @param licenseId the primary key of the s c license
632            * @return the s c license, or <code>null</code> if a s c license with the primary key could not be found
633            */
634            public static com.liferay.portlet.softwarecatalog.model.SCLicense fetchByPrimaryKey(
635                    long licenseId) {
636                    return getPersistence().fetchByPrimaryKey(licenseId);
637            }
638    
639            public static java.util.Map<java.io.Serializable, com.liferay.portlet.softwarecatalog.model.SCLicense> fetchByPrimaryKeys(
640                    java.util.Set<java.io.Serializable> primaryKeys) {
641                    return getPersistence().fetchByPrimaryKeys(primaryKeys);
642            }
643    
644            /**
645            * Returns all the s c licenses.
646            *
647            * @return the s c licenses
648            */
649            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> findAll() {
650                    return getPersistence().findAll();
651            }
652    
653            /**
654            * Returns a range of all the s c licenses.
655            *
656            * <p>
657            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
658            * </p>
659            *
660            * @param start the lower bound of the range of s c licenses
661            * @param end the upper bound of the range of s c licenses (not inclusive)
662            * @return the range of s c licenses
663            */
664            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> findAll(
665                    int start, int end) {
666                    return getPersistence().findAll(start, end);
667            }
668    
669            /**
670            * Returns an ordered range of all the s c licenses.
671            *
672            * <p>
673            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
674            * </p>
675            *
676            * @param start the lower bound of the range of s c licenses
677            * @param end the upper bound of the range of s c licenses (not inclusive)
678            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
679            * @return the ordered range of s c licenses
680            */
681            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCLicense> findAll(
682                    int start, int end,
683                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCLicense> orderByComparator) {
684                    return getPersistence().findAll(start, end, orderByComparator);
685            }
686    
687            /**
688            * Removes all the s c licenses from the database.
689            */
690            public static void removeAll() {
691                    getPersistence().removeAll();
692            }
693    
694            /**
695            * Returns the number of s c licenses.
696            *
697            * @return the number of s c licenses
698            */
699            public static int countAll() {
700                    return getPersistence().countAll();
701            }
702    
703            /**
704            * Returns the primaryKeys of s c product entries associated with the s c license.
705            *
706            * @param pk the primary key of the s c license
707            * @return long[] of the primaryKeys of s c product entries associated with the s c license
708            */
709            public static long[] getSCProductEntryPrimaryKeys(long pk) {
710                    return getPersistence().getSCProductEntryPrimaryKeys(pk);
711            }
712    
713            /**
714            * Returns all the s c product entries associated with the s c license.
715            *
716            * @param pk the primary key of the s c license
717            * @return the s c product entries associated with the s c license
718            */
719            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> getSCProductEntries(
720                    long pk) {
721                    return getPersistence().getSCProductEntries(pk);
722            }
723    
724            /**
725            * Returns a range of all the s c product entries associated with the s c license.
726            *
727            * <p>
728            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
729            * </p>
730            *
731            * @param pk the primary key of the s c license
732            * @param start the lower bound of the range of s c licenses
733            * @param end the upper bound of the range of s c licenses (not inclusive)
734            * @return the range of s c product entries associated with the s c license
735            */
736            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> getSCProductEntries(
737                    long pk, int start, int end) {
738                    return getPersistence().getSCProductEntries(pk, start, end);
739            }
740    
741            /**
742            * Returns an ordered range of all the s c product entries associated with the s c license.
743            *
744            * <p>
745            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.softwarecatalog.model.impl.SCLicenseModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
746            * </p>
747            *
748            * @param pk the primary key of the s c license
749            * @param start the lower bound of the range of s c licenses
750            * @param end the upper bound of the range of s c licenses (not inclusive)
751            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
752            * @return the ordered range of s c product entries associated with the s c license
753            */
754            public static java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> getSCProductEntries(
755                    long pk, int start, int end,
756                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portlet.softwarecatalog.model.SCProductEntry> orderByComparator) {
757                    return getPersistence()
758                                       .getSCProductEntries(pk, start, end, orderByComparator);
759            }
760    
761            /**
762            * Returns the number of s c product entries associated with the s c license.
763            *
764            * @param pk the primary key of the s c license
765            * @return the number of s c product entries associated with the s c license
766            */
767            public static int getSCProductEntriesSize(long pk) {
768                    return getPersistence().getSCProductEntriesSize(pk);
769            }
770    
771            /**
772            * Returns <code>true</code> if the s c product entry is associated with the s c license.
773            *
774            * @param pk the primary key of the s c license
775            * @param scProductEntryPK the primary key of the s c product entry
776            * @return <code>true</code> if the s c product entry is associated with the s c license; <code>false</code> otherwise
777            */
778            public static boolean containsSCProductEntry(long pk, long scProductEntryPK) {
779                    return getPersistence().containsSCProductEntry(pk, scProductEntryPK);
780            }
781    
782            /**
783            * Returns <code>true</code> if the s c license has any s c product entries associated with it.
784            *
785            * @param pk the primary key of the s c license to check for associations with s c product entries
786            * @return <code>true</code> if the s c license has any s c product entries associated with it; <code>false</code> otherwise
787            */
788            public static boolean containsSCProductEntries(long pk) {
789                    return getPersistence().containsSCProductEntries(pk);
790            }
791    
792            /**
793            * Adds an association between the s c license and the s c product entry. Also notifies the appropriate model listeners and clears the mapping table finder cache.
794            *
795            * @param pk the primary key of the s c license
796            * @param scProductEntryPK the primary key of the s c product entry
797            */
798            public static void addSCProductEntry(long pk, long scProductEntryPK) {
799                    getPersistence().addSCProductEntry(pk, scProductEntryPK);
800            }
801    
802            /**
803            * Adds an association between the s c license and the s c product entry. Also notifies the appropriate model listeners and clears the mapping table finder cache.
804            *
805            * @param pk the primary key of the s c license
806            * @param scProductEntry the s c product entry
807            */
808            public static void addSCProductEntry(long pk,
809                    com.liferay.portlet.softwarecatalog.model.SCProductEntry scProductEntry) {
810                    getPersistence().addSCProductEntry(pk, scProductEntry);
811            }
812    
813            /**
814            * Adds an association between the s c license and the s c product entries. Also notifies the appropriate model listeners and clears the mapping table finder cache.
815            *
816            * @param pk the primary key of the s c license
817            * @param scProductEntryPKs the primary keys of the s c product entries
818            */
819            public static void addSCProductEntries(long pk, long[] scProductEntryPKs) {
820                    getPersistence().addSCProductEntries(pk, scProductEntryPKs);
821            }
822    
823            /**
824            * Adds an association between the s c license and the s c product entries. Also notifies the appropriate model listeners and clears the mapping table finder cache.
825            *
826            * @param pk the primary key of the s c license
827            * @param scProductEntries the s c product entries
828            */
829            public static void addSCProductEntries(long pk,
830                    java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> scProductEntries) {
831                    getPersistence().addSCProductEntries(pk, scProductEntries);
832            }
833    
834            /**
835            * Clears all associations between the s c license and its s c product entries. Also notifies the appropriate model listeners and clears the mapping table finder cache.
836            *
837            * @param pk the primary key of the s c license to clear the associated s c product entries from
838            */
839            public static void clearSCProductEntries(long pk) {
840                    getPersistence().clearSCProductEntries(pk);
841            }
842    
843            /**
844            * Removes the association between the s c license and the s c product entry. Also notifies the appropriate model listeners and clears the mapping table finder cache.
845            *
846            * @param pk the primary key of the s c license
847            * @param scProductEntryPK the primary key of the s c product entry
848            */
849            public static void removeSCProductEntry(long pk, long scProductEntryPK) {
850                    getPersistence().removeSCProductEntry(pk, scProductEntryPK);
851            }
852    
853            /**
854            * Removes the association between the s c license and the s c product entry. Also notifies the appropriate model listeners and clears the mapping table finder cache.
855            *
856            * @param pk the primary key of the s c license
857            * @param scProductEntry the s c product entry
858            */
859            public static void removeSCProductEntry(long pk,
860                    com.liferay.portlet.softwarecatalog.model.SCProductEntry scProductEntry) {
861                    getPersistence().removeSCProductEntry(pk, scProductEntry);
862            }
863    
864            /**
865            * Removes the association between the s c license and the s c product entries. Also notifies the appropriate model listeners and clears the mapping table finder cache.
866            *
867            * @param pk the primary key of the s c license
868            * @param scProductEntryPKs the primary keys of the s c product entries
869            */
870            public static void removeSCProductEntries(long pk, long[] scProductEntryPKs) {
871                    getPersistence().removeSCProductEntries(pk, scProductEntryPKs);
872            }
873    
874            /**
875            * Removes the association between the s c license and the s c product entries. Also notifies the appropriate model listeners and clears the mapping table finder cache.
876            *
877            * @param pk the primary key of the s c license
878            * @param scProductEntries the s c product entries
879            */
880            public static void removeSCProductEntries(long pk,
881                    java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> scProductEntries) {
882                    getPersistence().removeSCProductEntries(pk, scProductEntries);
883            }
884    
885            /**
886            * Sets the s c product entries associated with the s c license, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
887            *
888            * @param pk the primary key of the s c license
889            * @param scProductEntryPKs the primary keys of the s c product entries to be associated with the s c license
890            */
891            public static void setSCProductEntries(long pk, long[] scProductEntryPKs) {
892                    getPersistence().setSCProductEntries(pk, scProductEntryPKs);
893            }
894    
895            /**
896            * Sets the s c product entries associated with the s c license, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
897            *
898            * @param pk the primary key of the s c license
899            * @param scProductEntries the s c product entries to be associated with the s c license
900            */
901            public static void setSCProductEntries(long pk,
902                    java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductEntry> scProductEntries) {
903                    getPersistence().setSCProductEntries(pk, scProductEntries);
904            }
905    
906            public static SCLicensePersistence getPersistence() {
907                    if (_persistence == null) {
908                            _persistence = (SCLicensePersistence)PortalBeanLocatorUtil.locate(SCLicensePersistence.class.getName());
909    
910                            ReferenceRegistry.registerReference(SCLicenseUtil.class,
911                                    "_persistence");
912                    }
913    
914                    return _persistence;
915            }
916    
917            /**
918             * @deprecated As of 6.2.0
919             */
920            @Deprecated
921            public void setPersistence(SCLicensePersistence persistence) {
922            }
923    
924            private static SCLicensePersistence _persistence;
925    }