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.social.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.social.model.SocialActivityCounter;
026    
027    import java.util.List;
028    
029    /**
030     * The persistence utility for the social activity counter service. This utility wraps {@link com.liferay.portlet.social.service.persistence.impl.SocialActivityCounterPersistenceImpl} 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 SocialActivityCounterPersistence
038     * @see com.liferay.portlet.social.service.persistence.impl.SocialActivityCounterPersistenceImpl
039     * @generated
040     */
041    @ProviderType
042    public class SocialActivityCounterUtil {
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(SocialActivityCounter socialActivityCounter) {
060                    getPersistence().clearCache(socialActivityCounter);
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<SocialActivityCounter> 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<SocialActivityCounter> 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<SocialActivityCounter> findWithDynamicQuery(
090                    DynamicQuery dynamicQuery, int start, int end,
091                    OrderByComparator<SocialActivityCounter> 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 SocialActivityCounter update(
101                    SocialActivityCounter socialActivityCounter) {
102                    return getPersistence().update(socialActivityCounter);
103            }
104    
105            /**
106             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext)
107             */
108            public static SocialActivityCounter update(
109                    SocialActivityCounter socialActivityCounter,
110                    ServiceContext serviceContext) {
111                    return getPersistence().update(socialActivityCounter, serviceContext);
112            }
113    
114            /**
115            * Returns all the social activity counters where groupId = &#63;.
116            *
117            * @param groupId the group ID
118            * @return the matching social activity counters
119            */
120            public static List<SocialActivityCounter> findByGroupId(long groupId) {
121                    return getPersistence().findByGroupId(groupId);
122            }
123    
124            /**
125            * Returns a range of all the social activity counters where groupId = &#63;.
126            *
127            * <p>
128            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
129            * </p>
130            *
131            * @param groupId the group ID
132            * @param start the lower bound of the range of social activity counters
133            * @param end the upper bound of the range of social activity counters (not inclusive)
134            * @return the range of matching social activity counters
135            */
136            public static List<SocialActivityCounter> findByGroupId(long groupId,
137                    int start, int end) {
138                    return getPersistence().findByGroupId(groupId, start, end);
139            }
140    
141            /**
142            * Returns an ordered range of all the social activity counters where groupId = &#63;.
143            *
144            * <p>
145            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
146            * </p>
147            *
148            * @param groupId the group ID
149            * @param start the lower bound of the range of social activity counters
150            * @param end the upper bound of the range of social activity counters (not inclusive)
151            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
152            * @return the ordered range of matching social activity counters
153            */
154            public static List<SocialActivityCounter> findByGroupId(long groupId,
155                    int start, int end,
156                    OrderByComparator<SocialActivityCounter> orderByComparator) {
157                    return getPersistence()
158                                       .findByGroupId(groupId, start, end, orderByComparator);
159            }
160    
161            /**
162            * Returns an ordered range of all the social activity counters where groupId = &#63;.
163            *
164            * <p>
165            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
166            * </p>
167            *
168            * @param groupId the group ID
169            * @param start the lower bound of the range of social activity counters
170            * @param end the upper bound of the range of social activity counters (not inclusive)
171            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
172            * @param retrieveFromCache whether to retrieve from the finder cache
173            * @return the ordered range of matching social activity counters
174            */
175            public static List<SocialActivityCounter> findByGroupId(long groupId,
176                    int start, int end,
177                    OrderByComparator<SocialActivityCounter> orderByComparator,
178                    boolean retrieveFromCache) {
179                    return getPersistence()
180                                       .findByGroupId(groupId, start, end, orderByComparator,
181                            retrieveFromCache);
182            }
183    
184            /**
185            * Returns the first social activity counter in the ordered set where groupId = &#63;.
186            *
187            * @param groupId the group ID
188            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
189            * @return the first matching social activity counter
190            * @throws NoSuchActivityCounterException if a matching social activity counter could not be found
191            */
192            public static SocialActivityCounter findByGroupId_First(long groupId,
193                    OrderByComparator<SocialActivityCounter> orderByComparator)
194                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
195                    return getPersistence().findByGroupId_First(groupId, orderByComparator);
196            }
197    
198            /**
199            * Returns the first social activity counter in the ordered set where groupId = &#63;.
200            *
201            * @param groupId the group ID
202            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
203            * @return the first matching social activity counter, or <code>null</code> if a matching social activity counter could not be found
204            */
205            public static SocialActivityCounter fetchByGroupId_First(long groupId,
206                    OrderByComparator<SocialActivityCounter> orderByComparator) {
207                    return getPersistence().fetchByGroupId_First(groupId, orderByComparator);
208            }
209    
210            /**
211            * Returns the last social activity counter in the ordered set where groupId = &#63;.
212            *
213            * @param groupId the group ID
214            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
215            * @return the last matching social activity counter
216            * @throws NoSuchActivityCounterException if a matching social activity counter could not be found
217            */
218            public static SocialActivityCounter findByGroupId_Last(long groupId,
219                    OrderByComparator<SocialActivityCounter> orderByComparator)
220                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
221                    return getPersistence().findByGroupId_Last(groupId, orderByComparator);
222            }
223    
224            /**
225            * Returns the last social activity counter in the ordered set where groupId = &#63;.
226            *
227            * @param groupId the group ID
228            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
229            * @return the last matching social activity counter, or <code>null</code> if a matching social activity counter could not be found
230            */
231            public static SocialActivityCounter fetchByGroupId_Last(long groupId,
232                    OrderByComparator<SocialActivityCounter> orderByComparator) {
233                    return getPersistence().fetchByGroupId_Last(groupId, orderByComparator);
234            }
235    
236            /**
237            * Returns the social activity counters before and after the current social activity counter in the ordered set where groupId = &#63;.
238            *
239            * @param activityCounterId the primary key of the current social activity counter
240            * @param groupId the group ID
241            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
242            * @return the previous, current, and next social activity counter
243            * @throws NoSuchActivityCounterException if a social activity counter with the primary key could not be found
244            */
245            public static SocialActivityCounter[] findByGroupId_PrevAndNext(
246                    long activityCounterId, long groupId,
247                    OrderByComparator<SocialActivityCounter> orderByComparator)
248                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
249                    return getPersistence()
250                                       .findByGroupId_PrevAndNext(activityCounterId, groupId,
251                            orderByComparator);
252            }
253    
254            /**
255            * Removes all the social activity counters where groupId = &#63; from the database.
256            *
257            * @param groupId the group ID
258            */
259            public static void removeByGroupId(long groupId) {
260                    getPersistence().removeByGroupId(groupId);
261            }
262    
263            /**
264            * Returns the number of social activity counters where groupId = &#63;.
265            *
266            * @param groupId the group ID
267            * @return the number of matching social activity counters
268            */
269            public static int countByGroupId(long groupId) {
270                    return getPersistence().countByGroupId(groupId);
271            }
272    
273            /**
274            * Returns all the social activity counters where classNameId = &#63; and classPK = &#63;.
275            *
276            * @param classNameId the class name ID
277            * @param classPK the class p k
278            * @return the matching social activity counters
279            */
280            public static List<SocialActivityCounter> findByC_C(long classNameId,
281                    long classPK) {
282                    return getPersistence().findByC_C(classNameId, classPK);
283            }
284    
285            /**
286            * Returns a range of all the social activity counters where classNameId = &#63; and classPK = &#63;.
287            *
288            * <p>
289            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
290            * </p>
291            *
292            * @param classNameId the class name ID
293            * @param classPK the class p k
294            * @param start the lower bound of the range of social activity counters
295            * @param end the upper bound of the range of social activity counters (not inclusive)
296            * @return the range of matching social activity counters
297            */
298            public static List<SocialActivityCounter> findByC_C(long classNameId,
299                    long classPK, int start, int end) {
300                    return getPersistence().findByC_C(classNameId, classPK, start, end);
301            }
302    
303            /**
304            * Returns an ordered range of all the social activity counters where classNameId = &#63; and classPK = &#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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
308            * </p>
309            *
310            * @param classNameId the class name ID
311            * @param classPK the class p k
312            * @param start the lower bound of the range of social activity counters
313            * @param end the upper bound of the range of social activity counters (not inclusive)
314            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
315            * @return the ordered range of matching social activity counters
316            */
317            public static List<SocialActivityCounter> findByC_C(long classNameId,
318                    long classPK, int start, int end,
319                    OrderByComparator<SocialActivityCounter> orderByComparator) {
320                    return getPersistence()
321                                       .findByC_C(classNameId, classPK, start, end,
322                            orderByComparator);
323            }
324    
325            /**
326            * Returns an ordered range of all the social activity counters where classNameId = &#63; and classPK = &#63;.
327            *
328            * <p>
329            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
330            * </p>
331            *
332            * @param classNameId the class name ID
333            * @param classPK the class p k
334            * @param start the lower bound of the range of social activity counters
335            * @param end the upper bound of the range of social activity counters (not inclusive)
336            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
337            * @param retrieveFromCache whether to retrieve from the finder cache
338            * @return the ordered range of matching social activity counters
339            */
340            public static List<SocialActivityCounter> findByC_C(long classNameId,
341                    long classPK, int start, int end,
342                    OrderByComparator<SocialActivityCounter> orderByComparator,
343                    boolean retrieveFromCache) {
344                    return getPersistence()
345                                       .findByC_C(classNameId, classPK, start, end,
346                            orderByComparator, retrieveFromCache);
347            }
348    
349            /**
350            * Returns the first social activity counter in the ordered set where classNameId = &#63; and classPK = &#63;.
351            *
352            * @param classNameId the class name ID
353            * @param classPK the class p k
354            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
355            * @return the first matching social activity counter
356            * @throws NoSuchActivityCounterException if a matching social activity counter could not be found
357            */
358            public static SocialActivityCounter findByC_C_First(long classNameId,
359                    long classPK, OrderByComparator<SocialActivityCounter> orderByComparator)
360                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
361                    return getPersistence()
362                                       .findByC_C_First(classNameId, classPK, orderByComparator);
363            }
364    
365            /**
366            * Returns the first social activity counter in the ordered set where classNameId = &#63; and classPK = &#63;.
367            *
368            * @param classNameId the class name ID
369            * @param classPK the class p k
370            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
371            * @return the first matching social activity counter, or <code>null</code> if a matching social activity counter could not be found
372            */
373            public static SocialActivityCounter fetchByC_C_First(long classNameId,
374                    long classPK, OrderByComparator<SocialActivityCounter> orderByComparator) {
375                    return getPersistence()
376                                       .fetchByC_C_First(classNameId, classPK, orderByComparator);
377            }
378    
379            /**
380            * Returns the last social activity counter in the ordered set where classNameId = &#63; and classPK = &#63;.
381            *
382            * @param classNameId the class name ID
383            * @param classPK the class p k
384            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
385            * @return the last matching social activity counter
386            * @throws NoSuchActivityCounterException if a matching social activity counter could not be found
387            */
388            public static SocialActivityCounter findByC_C_Last(long classNameId,
389                    long classPK, OrderByComparator<SocialActivityCounter> orderByComparator)
390                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
391                    return getPersistence()
392                                       .findByC_C_Last(classNameId, classPK, orderByComparator);
393            }
394    
395            /**
396            * Returns the last social activity counter in the ordered set where classNameId = &#63; and classPK = &#63;.
397            *
398            * @param classNameId the class name ID
399            * @param classPK the class p k
400            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
401            * @return the last matching social activity counter, or <code>null</code> if a matching social activity counter could not be found
402            */
403            public static SocialActivityCounter fetchByC_C_Last(long classNameId,
404                    long classPK, OrderByComparator<SocialActivityCounter> orderByComparator) {
405                    return getPersistence()
406                                       .fetchByC_C_Last(classNameId, classPK, orderByComparator);
407            }
408    
409            /**
410            * Returns the social activity counters before and after the current social activity counter in the ordered set where classNameId = &#63; and classPK = &#63;.
411            *
412            * @param activityCounterId the primary key of the current social activity counter
413            * @param classNameId the class name ID
414            * @param classPK the class p k
415            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
416            * @return the previous, current, and next social activity counter
417            * @throws NoSuchActivityCounterException if a social activity counter with the primary key could not be found
418            */
419            public static SocialActivityCounter[] findByC_C_PrevAndNext(
420                    long activityCounterId, long classNameId, long classPK,
421                    OrderByComparator<SocialActivityCounter> orderByComparator)
422                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
423                    return getPersistence()
424                                       .findByC_C_PrevAndNext(activityCounterId, classNameId,
425                            classPK, orderByComparator);
426            }
427    
428            /**
429            * Removes all the social activity counters where classNameId = &#63; and classPK = &#63; from the database.
430            *
431            * @param classNameId the class name ID
432            * @param classPK the class p k
433            */
434            public static void removeByC_C(long classNameId, long classPK) {
435                    getPersistence().removeByC_C(classNameId, classPK);
436            }
437    
438            /**
439            * Returns the number of social activity counters where classNameId = &#63; and classPK = &#63;.
440            *
441            * @param classNameId the class name ID
442            * @param classPK the class p k
443            * @return the number of matching social activity counters
444            */
445            public static int countByC_C(long classNameId, long classPK) {
446                    return getPersistence().countByC_C(classNameId, classPK);
447            }
448    
449            /**
450            * Returns all the social activity counters where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63;.
451            *
452            * @param groupId the group ID
453            * @param classNameId the class name ID
454            * @param classPK the class p k
455            * @param ownerType the owner type
456            * @return the matching social activity counters
457            */
458            public static List<SocialActivityCounter> findByG_C_C_O(long groupId,
459                    long classNameId, long classPK, int ownerType) {
460                    return getPersistence()
461                                       .findByG_C_C_O(groupId, classNameId, classPK, ownerType);
462            }
463    
464            /**
465            * Returns a range of all the social activity counters where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63;.
466            *
467            * <p>
468            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
469            * </p>
470            *
471            * @param groupId the group ID
472            * @param classNameId the class name ID
473            * @param classPK the class p k
474            * @param ownerType the owner type
475            * @param start the lower bound of the range of social activity counters
476            * @param end the upper bound of the range of social activity counters (not inclusive)
477            * @return the range of matching social activity counters
478            */
479            public static List<SocialActivityCounter> findByG_C_C_O(long groupId,
480                    long classNameId, long classPK, int ownerType, int start, int end) {
481                    return getPersistence()
482                                       .findByG_C_C_O(groupId, classNameId, classPK, ownerType,
483                            start, end);
484            }
485    
486            /**
487            * Returns an ordered range of all the social activity counters where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63;.
488            *
489            * <p>
490            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
491            * </p>
492            *
493            * @param groupId the group ID
494            * @param classNameId the class name ID
495            * @param classPK the class p k
496            * @param ownerType the owner type
497            * @param start the lower bound of the range of social activity counters
498            * @param end the upper bound of the range of social activity counters (not inclusive)
499            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
500            * @return the ordered range of matching social activity counters
501            */
502            public static List<SocialActivityCounter> findByG_C_C_O(long groupId,
503                    long classNameId, long classPK, int ownerType, int start, int end,
504                    OrderByComparator<SocialActivityCounter> orderByComparator) {
505                    return getPersistence()
506                                       .findByG_C_C_O(groupId, classNameId, classPK, ownerType,
507                            start, end, orderByComparator);
508            }
509    
510            /**
511            * Returns an ordered range of all the social activity counters where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63;.
512            *
513            * <p>
514            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
515            * </p>
516            *
517            * @param groupId the group ID
518            * @param classNameId the class name ID
519            * @param classPK the class p k
520            * @param ownerType the owner type
521            * @param start the lower bound of the range of social activity counters
522            * @param end the upper bound of the range of social activity counters (not inclusive)
523            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
524            * @param retrieveFromCache whether to retrieve from the finder cache
525            * @return the ordered range of matching social activity counters
526            */
527            public static List<SocialActivityCounter> findByG_C_C_O(long groupId,
528                    long classNameId, long classPK, int ownerType, int start, int end,
529                    OrderByComparator<SocialActivityCounter> orderByComparator,
530                    boolean retrieveFromCache) {
531                    return getPersistence()
532                                       .findByG_C_C_O(groupId, classNameId, classPK, ownerType,
533                            start, end, orderByComparator, retrieveFromCache);
534            }
535    
536            /**
537            * Returns the first social activity counter in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63;.
538            *
539            * @param groupId the group ID
540            * @param classNameId the class name ID
541            * @param classPK the class p k
542            * @param ownerType the owner type
543            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
544            * @return the first matching social activity counter
545            * @throws NoSuchActivityCounterException if a matching social activity counter could not be found
546            */
547            public static SocialActivityCounter findByG_C_C_O_First(long groupId,
548                    long classNameId, long classPK, int ownerType,
549                    OrderByComparator<SocialActivityCounter> orderByComparator)
550                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
551                    return getPersistence()
552                                       .findByG_C_C_O_First(groupId, classNameId, classPK,
553                            ownerType, orderByComparator);
554            }
555    
556            /**
557            * Returns the first social activity counter in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63;.
558            *
559            * @param groupId the group ID
560            * @param classNameId the class name ID
561            * @param classPK the class p k
562            * @param ownerType the owner type
563            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
564            * @return the first matching social activity counter, or <code>null</code> if a matching social activity counter could not be found
565            */
566            public static SocialActivityCounter fetchByG_C_C_O_First(long groupId,
567                    long classNameId, long classPK, int ownerType,
568                    OrderByComparator<SocialActivityCounter> orderByComparator) {
569                    return getPersistence()
570                                       .fetchByG_C_C_O_First(groupId, classNameId, classPK,
571                            ownerType, orderByComparator);
572            }
573    
574            /**
575            * Returns the last social activity counter in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63;.
576            *
577            * @param groupId the group ID
578            * @param classNameId the class name ID
579            * @param classPK the class p k
580            * @param ownerType the owner type
581            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
582            * @return the last matching social activity counter
583            * @throws NoSuchActivityCounterException if a matching social activity counter could not be found
584            */
585            public static SocialActivityCounter findByG_C_C_O_Last(long groupId,
586                    long classNameId, long classPK, int ownerType,
587                    OrderByComparator<SocialActivityCounter> orderByComparator)
588                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
589                    return getPersistence()
590                                       .findByG_C_C_O_Last(groupId, classNameId, classPK,
591                            ownerType, orderByComparator);
592            }
593    
594            /**
595            * Returns the last social activity counter in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63;.
596            *
597            * @param groupId the group ID
598            * @param classNameId the class name ID
599            * @param classPK the class p k
600            * @param ownerType the owner type
601            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
602            * @return the last matching social activity counter, or <code>null</code> if a matching social activity counter could not be found
603            */
604            public static SocialActivityCounter fetchByG_C_C_O_Last(long groupId,
605                    long classNameId, long classPK, int ownerType,
606                    OrderByComparator<SocialActivityCounter> orderByComparator) {
607                    return getPersistence()
608                                       .fetchByG_C_C_O_Last(groupId, classNameId, classPK,
609                            ownerType, orderByComparator);
610            }
611    
612            /**
613            * Returns the social activity counters before and after the current social activity counter in the ordered set where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63;.
614            *
615            * @param activityCounterId the primary key of the current social activity counter
616            * @param groupId the group ID
617            * @param classNameId the class name ID
618            * @param classPK the class p k
619            * @param ownerType the owner type
620            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
621            * @return the previous, current, and next social activity counter
622            * @throws NoSuchActivityCounterException if a social activity counter with the primary key could not be found
623            */
624            public static SocialActivityCounter[] findByG_C_C_O_PrevAndNext(
625                    long activityCounterId, long groupId, long classNameId, long classPK,
626                    int ownerType,
627                    OrderByComparator<SocialActivityCounter> orderByComparator)
628                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
629                    return getPersistence()
630                                       .findByG_C_C_O_PrevAndNext(activityCounterId, groupId,
631                            classNameId, classPK, ownerType, orderByComparator);
632            }
633    
634            /**
635            * Removes all the social activity counters where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63; from the database.
636            *
637            * @param groupId the group ID
638            * @param classNameId the class name ID
639            * @param classPK the class p k
640            * @param ownerType the owner type
641            */
642            public static void removeByG_C_C_O(long groupId, long classNameId,
643                    long classPK, int ownerType) {
644                    getPersistence()
645                            .removeByG_C_C_O(groupId, classNameId, classPK, ownerType);
646            }
647    
648            /**
649            * Returns the number of social activity counters where groupId = &#63; and classNameId = &#63; and classPK = &#63; and ownerType = &#63;.
650            *
651            * @param groupId the group ID
652            * @param classNameId the class name ID
653            * @param classPK the class p k
654            * @param ownerType the owner type
655            * @return the number of matching social activity counters
656            */
657            public static int countByG_C_C_O(long groupId, long classNameId,
658                    long classPK, int ownerType) {
659                    return getPersistence()
660                                       .countByG_C_C_O(groupId, classNameId, classPK, ownerType);
661            }
662    
663            /**
664            * Returns the social activity counter where groupId = &#63; and classNameId = &#63; and classPK = &#63; and name = &#63; and ownerType = &#63; and startPeriod = &#63; or throws a {@link NoSuchActivityCounterException} if it could not be found.
665            *
666            * @param groupId the group ID
667            * @param classNameId the class name ID
668            * @param classPK the class p k
669            * @param name the name
670            * @param ownerType the owner type
671            * @param startPeriod the start period
672            * @return the matching social activity counter
673            * @throws NoSuchActivityCounterException if a matching social activity counter could not be found
674            */
675            public static SocialActivityCounter findByG_C_C_N_O_S(long groupId,
676                    long classNameId, long classPK, java.lang.String name, int ownerType,
677                    int startPeriod)
678                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
679                    return getPersistence()
680                                       .findByG_C_C_N_O_S(groupId, classNameId, classPK, name,
681                            ownerType, startPeriod);
682            }
683    
684            /**
685            * Returns the social activity counter where groupId = &#63; and classNameId = &#63; and classPK = &#63; and name = &#63; and ownerType = &#63; and startPeriod = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
686            *
687            * @param groupId the group ID
688            * @param classNameId the class name ID
689            * @param classPK the class p k
690            * @param name the name
691            * @param ownerType the owner type
692            * @param startPeriod the start period
693            * @return the matching social activity counter, or <code>null</code> if a matching social activity counter could not be found
694            */
695            public static SocialActivityCounter fetchByG_C_C_N_O_S(long groupId,
696                    long classNameId, long classPK, java.lang.String name, int ownerType,
697                    int startPeriod) {
698                    return getPersistence()
699                                       .fetchByG_C_C_N_O_S(groupId, classNameId, classPK, name,
700                            ownerType, startPeriod);
701            }
702    
703            /**
704            * Returns the social activity counter where groupId = &#63; and classNameId = &#63; and classPK = &#63; and name = &#63; and ownerType = &#63; and startPeriod = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
705            *
706            * @param groupId the group ID
707            * @param classNameId the class name ID
708            * @param classPK the class p k
709            * @param name the name
710            * @param ownerType the owner type
711            * @param startPeriod the start period
712            * @param retrieveFromCache whether to retrieve from the finder cache
713            * @return the matching social activity counter, or <code>null</code> if a matching social activity counter could not be found
714            */
715            public static SocialActivityCounter fetchByG_C_C_N_O_S(long groupId,
716                    long classNameId, long classPK, java.lang.String name, int ownerType,
717                    int startPeriod, boolean retrieveFromCache) {
718                    return getPersistence()
719                                       .fetchByG_C_C_N_O_S(groupId, classNameId, classPK, name,
720                            ownerType, startPeriod, retrieveFromCache);
721            }
722    
723            /**
724            * Removes the social activity counter where groupId = &#63; and classNameId = &#63; and classPK = &#63; and name = &#63; and ownerType = &#63; and startPeriod = &#63; from the database.
725            *
726            * @param groupId the group ID
727            * @param classNameId the class name ID
728            * @param classPK the class p k
729            * @param name the name
730            * @param ownerType the owner type
731            * @param startPeriod the start period
732            * @return the social activity counter that was removed
733            */
734            public static SocialActivityCounter removeByG_C_C_N_O_S(long groupId,
735                    long classNameId, long classPK, java.lang.String name, int ownerType,
736                    int startPeriod)
737                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
738                    return getPersistence()
739                                       .removeByG_C_C_N_O_S(groupId, classNameId, classPK, name,
740                            ownerType, startPeriod);
741            }
742    
743            /**
744            * Returns the number of social activity counters where groupId = &#63; and classNameId = &#63; and classPK = &#63; and name = &#63; and ownerType = &#63; and startPeriod = &#63;.
745            *
746            * @param groupId the group ID
747            * @param classNameId the class name ID
748            * @param classPK the class p k
749            * @param name the name
750            * @param ownerType the owner type
751            * @param startPeriod the start period
752            * @return the number of matching social activity counters
753            */
754            public static int countByG_C_C_N_O_S(long groupId, long classNameId,
755                    long classPK, java.lang.String name, int ownerType, int startPeriod) {
756                    return getPersistence()
757                                       .countByG_C_C_N_O_S(groupId, classNameId, classPK, name,
758                            ownerType, startPeriod);
759            }
760    
761            /**
762            * Returns the social activity counter where groupId = &#63; and classNameId = &#63; and classPK = &#63; and name = &#63; and ownerType = &#63; and endPeriod = &#63; or throws a {@link NoSuchActivityCounterException} if it could not be found.
763            *
764            * @param groupId the group ID
765            * @param classNameId the class name ID
766            * @param classPK the class p k
767            * @param name the name
768            * @param ownerType the owner type
769            * @param endPeriod the end period
770            * @return the matching social activity counter
771            * @throws NoSuchActivityCounterException if a matching social activity counter could not be found
772            */
773            public static SocialActivityCounter findByG_C_C_N_O_E(long groupId,
774                    long classNameId, long classPK, java.lang.String name, int ownerType,
775                    int endPeriod)
776                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
777                    return getPersistence()
778                                       .findByG_C_C_N_O_E(groupId, classNameId, classPK, name,
779                            ownerType, endPeriod);
780            }
781    
782            /**
783            * Returns the social activity counter where groupId = &#63; and classNameId = &#63; and classPK = &#63; and name = &#63; and ownerType = &#63; and endPeriod = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
784            *
785            * @param groupId the group ID
786            * @param classNameId the class name ID
787            * @param classPK the class p k
788            * @param name the name
789            * @param ownerType the owner type
790            * @param endPeriod the end period
791            * @return the matching social activity counter, or <code>null</code> if a matching social activity counter could not be found
792            */
793            public static SocialActivityCounter fetchByG_C_C_N_O_E(long groupId,
794                    long classNameId, long classPK, java.lang.String name, int ownerType,
795                    int endPeriod) {
796                    return getPersistence()
797                                       .fetchByG_C_C_N_O_E(groupId, classNameId, classPK, name,
798                            ownerType, endPeriod);
799            }
800    
801            /**
802            * Returns the social activity counter where groupId = &#63; and classNameId = &#63; and classPK = &#63; and name = &#63; and ownerType = &#63; and endPeriod = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
803            *
804            * @param groupId the group ID
805            * @param classNameId the class name ID
806            * @param classPK the class p k
807            * @param name the name
808            * @param ownerType the owner type
809            * @param endPeriod the end period
810            * @param retrieveFromCache whether to retrieve from the finder cache
811            * @return the matching social activity counter, or <code>null</code> if a matching social activity counter could not be found
812            */
813            public static SocialActivityCounter fetchByG_C_C_N_O_E(long groupId,
814                    long classNameId, long classPK, java.lang.String name, int ownerType,
815                    int endPeriod, boolean retrieveFromCache) {
816                    return getPersistence()
817                                       .fetchByG_C_C_N_O_E(groupId, classNameId, classPK, name,
818                            ownerType, endPeriod, retrieveFromCache);
819            }
820    
821            /**
822            * Removes the social activity counter where groupId = &#63; and classNameId = &#63; and classPK = &#63; and name = &#63; and ownerType = &#63; and endPeriod = &#63; from the database.
823            *
824            * @param groupId the group ID
825            * @param classNameId the class name ID
826            * @param classPK the class p k
827            * @param name the name
828            * @param ownerType the owner type
829            * @param endPeriod the end period
830            * @return the social activity counter that was removed
831            */
832            public static SocialActivityCounter removeByG_C_C_N_O_E(long groupId,
833                    long classNameId, long classPK, java.lang.String name, int ownerType,
834                    int endPeriod)
835                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
836                    return getPersistence()
837                                       .removeByG_C_C_N_O_E(groupId, classNameId, classPK, name,
838                            ownerType, endPeriod);
839            }
840    
841            /**
842            * Returns the number of social activity counters where groupId = &#63; and classNameId = &#63; and classPK = &#63; and name = &#63; and ownerType = &#63; and endPeriod = &#63;.
843            *
844            * @param groupId the group ID
845            * @param classNameId the class name ID
846            * @param classPK the class p k
847            * @param name the name
848            * @param ownerType the owner type
849            * @param endPeriod the end period
850            * @return the number of matching social activity counters
851            */
852            public static int countByG_C_C_N_O_E(long groupId, long classNameId,
853                    long classPK, java.lang.String name, int ownerType, int endPeriod) {
854                    return getPersistence()
855                                       .countByG_C_C_N_O_E(groupId, classNameId, classPK, name,
856                            ownerType, endPeriod);
857            }
858    
859            /**
860            * Caches the social activity counter in the entity cache if it is enabled.
861            *
862            * @param socialActivityCounter the social activity counter
863            */
864            public static void cacheResult(SocialActivityCounter socialActivityCounter) {
865                    getPersistence().cacheResult(socialActivityCounter);
866            }
867    
868            /**
869            * Caches the social activity counters in the entity cache if it is enabled.
870            *
871            * @param socialActivityCounters the social activity counters
872            */
873            public static void cacheResult(
874                    List<SocialActivityCounter> socialActivityCounters) {
875                    getPersistence().cacheResult(socialActivityCounters);
876            }
877    
878            /**
879            * Creates a new social activity counter with the primary key. Does not add the social activity counter to the database.
880            *
881            * @param activityCounterId the primary key for the new social activity counter
882            * @return the new social activity counter
883            */
884            public static SocialActivityCounter create(long activityCounterId) {
885                    return getPersistence().create(activityCounterId);
886            }
887    
888            /**
889            * Removes the social activity counter with the primary key from the database. Also notifies the appropriate model listeners.
890            *
891            * @param activityCounterId the primary key of the social activity counter
892            * @return the social activity counter that was removed
893            * @throws NoSuchActivityCounterException if a social activity counter with the primary key could not be found
894            */
895            public static SocialActivityCounter remove(long activityCounterId)
896                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
897                    return getPersistence().remove(activityCounterId);
898            }
899    
900            public static SocialActivityCounter updateImpl(
901                    SocialActivityCounter socialActivityCounter) {
902                    return getPersistence().updateImpl(socialActivityCounter);
903            }
904    
905            /**
906            * Returns the social activity counter with the primary key or throws a {@link NoSuchActivityCounterException} if it could not be found.
907            *
908            * @param activityCounterId the primary key of the social activity counter
909            * @return the social activity counter
910            * @throws NoSuchActivityCounterException if a social activity counter with the primary key could not be found
911            */
912            public static SocialActivityCounter findByPrimaryKey(long activityCounterId)
913                    throws com.liferay.portlet.social.exception.NoSuchActivityCounterException {
914                    return getPersistence().findByPrimaryKey(activityCounterId);
915            }
916    
917            /**
918            * Returns the social activity counter with the primary key or returns <code>null</code> if it could not be found.
919            *
920            * @param activityCounterId the primary key of the social activity counter
921            * @return the social activity counter, or <code>null</code> if a social activity counter with the primary key could not be found
922            */
923            public static SocialActivityCounter fetchByPrimaryKey(
924                    long activityCounterId) {
925                    return getPersistence().fetchByPrimaryKey(activityCounterId);
926            }
927    
928            public static java.util.Map<java.io.Serializable, SocialActivityCounter> fetchByPrimaryKeys(
929                    java.util.Set<java.io.Serializable> primaryKeys) {
930                    return getPersistence().fetchByPrimaryKeys(primaryKeys);
931            }
932    
933            /**
934            * Returns all the social activity counters.
935            *
936            * @return the social activity counters
937            */
938            public static List<SocialActivityCounter> findAll() {
939                    return getPersistence().findAll();
940            }
941    
942            /**
943            * Returns a range of all the social activity counters.
944            *
945            * <p>
946            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
947            * </p>
948            *
949            * @param start the lower bound of the range of social activity counters
950            * @param end the upper bound of the range of social activity counters (not inclusive)
951            * @return the range of social activity counters
952            */
953            public static List<SocialActivityCounter> findAll(int start, int end) {
954                    return getPersistence().findAll(start, end);
955            }
956    
957            /**
958            * Returns an ordered range of all the social activity counters.
959            *
960            * <p>
961            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
962            * </p>
963            *
964            * @param start the lower bound of the range of social activity counters
965            * @param end the upper bound of the range of social activity counters (not inclusive)
966            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
967            * @return the ordered range of social activity counters
968            */
969            public static List<SocialActivityCounter> findAll(int start, int end,
970                    OrderByComparator<SocialActivityCounter> orderByComparator) {
971                    return getPersistence().findAll(start, end, orderByComparator);
972            }
973    
974            /**
975            * Returns an ordered range of all the social activity counters.
976            *
977            * <p>
978            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link SocialActivityCounterModelImpl}. 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.
979            * </p>
980            *
981            * @param start the lower bound of the range of social activity counters
982            * @param end the upper bound of the range of social activity counters (not inclusive)
983            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
984            * @param retrieveFromCache whether to retrieve from the finder cache
985            * @return the ordered range of social activity counters
986            */
987            public static List<SocialActivityCounter> findAll(int start, int end,
988                    OrderByComparator<SocialActivityCounter> orderByComparator,
989                    boolean retrieveFromCache) {
990                    return getPersistence()
991                                       .findAll(start, end, orderByComparator, retrieveFromCache);
992            }
993    
994            /**
995            * Removes all the social activity counters from the database.
996            */
997            public static void removeAll() {
998                    getPersistence().removeAll();
999            }
1000    
1001            /**
1002            * Returns the number of social activity counters.
1003            *
1004            * @return the number of social activity counters
1005            */
1006            public static int countAll() {
1007                    return getPersistence().countAll();
1008            }
1009    
1010            public static java.util.Set<java.lang.String> getBadColumnNames() {
1011                    return getPersistence().getBadColumnNames();
1012            }
1013    
1014            public static SocialActivityCounterPersistence getPersistence() {
1015                    if (_persistence == null) {
1016                            _persistence = (SocialActivityCounterPersistence)PortalBeanLocatorUtil.locate(SocialActivityCounterPersistence.class.getName());
1017    
1018                            ReferenceRegistry.registerReference(SocialActivityCounterUtil.class,
1019                                    "_persistence");
1020                    }
1021    
1022                    return _persistence;
1023            }
1024    
1025            private static SocialActivityCounterPersistence _persistence;
1026    }