001    /**
002     * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portlet.social.service.persistence;
016    
017    import com.liferay.portal.kernel.exception.SystemException;
018    import com.liferay.portal.service.persistence.BasePersistence;
019    
020    import com.liferay.portlet.social.model.SocialActivityLimit;
021    
022    /**
023     * The persistence interface for the social activity limit service.
024     *
025     * <p>
026     * Caching information and settings can be found in <code>portal.properties</code>
027     * </p>
028     *
029     * @author Brian Wing Shun Chan
030     * @see SocialActivityLimitPersistenceImpl
031     * @see SocialActivityLimitUtil
032     * @generated
033     */
034    public interface SocialActivityLimitPersistence extends BasePersistence<SocialActivityLimit> {
035            /*
036             * NOTE FOR DEVELOPERS:
037             *
038             * Never modify or reference this interface directly. Always use {@link SocialActivityLimitUtil} to access the social activity limit persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
039             */
040    
041            /**
042            * Caches the social activity limit in the entity cache if it is enabled.
043            *
044            * @param socialActivityLimit the social activity limit
045            */
046            public void cacheResult(
047                    com.liferay.portlet.social.model.SocialActivityLimit socialActivityLimit);
048    
049            /**
050            * Caches the social activity limits in the entity cache if it is enabled.
051            *
052            * @param socialActivityLimits the social activity limits
053            */
054            public void cacheResult(
055                    java.util.List<com.liferay.portlet.social.model.SocialActivityLimit> socialActivityLimits);
056    
057            /**
058            * Creates a new social activity limit with the primary key. Does not add the social activity limit to the database.
059            *
060            * @param activityLimitId the primary key for the new social activity limit
061            * @return the new social activity limit
062            */
063            public com.liferay.portlet.social.model.SocialActivityLimit create(
064                    long activityLimitId);
065    
066            /**
067            * Removes the social activity limit with the primary key from the database. Also notifies the appropriate model listeners.
068            *
069            * @param activityLimitId the primary key of the social activity limit
070            * @return the social activity limit that was removed
071            * @throws com.liferay.portlet.social.NoSuchActivityLimitException if a social activity limit with the primary key could not be found
072            * @throws SystemException if a system exception occurred
073            */
074            public com.liferay.portlet.social.model.SocialActivityLimit remove(
075                    long activityLimitId)
076                    throws com.liferay.portal.kernel.exception.SystemException,
077                            com.liferay.portlet.social.NoSuchActivityLimitException;
078    
079            public com.liferay.portlet.social.model.SocialActivityLimit updateImpl(
080                    com.liferay.portlet.social.model.SocialActivityLimit socialActivityLimit,
081                    boolean merge)
082                    throws com.liferay.portal.kernel.exception.SystemException;
083    
084            /**
085            * Returns the social activity limit with the primary key or throws a {@link com.liferay.portlet.social.NoSuchActivityLimitException} if it could not be found.
086            *
087            * @param activityLimitId the primary key of the social activity limit
088            * @return the social activity limit
089            * @throws com.liferay.portlet.social.NoSuchActivityLimitException if a social activity limit with the primary key could not be found
090            * @throws SystemException if a system exception occurred
091            */
092            public com.liferay.portlet.social.model.SocialActivityLimit findByPrimaryKey(
093                    long activityLimitId)
094                    throws com.liferay.portal.kernel.exception.SystemException,
095                            com.liferay.portlet.social.NoSuchActivityLimitException;
096    
097            /**
098            * Returns the social activity limit with the primary key or returns <code>null</code> if it could not be found.
099            *
100            * @param activityLimitId the primary key of the social activity limit
101            * @return the social activity limit, or <code>null</code> if a social activity limit with the primary key could not be found
102            * @throws SystemException if a system exception occurred
103            */
104            public com.liferay.portlet.social.model.SocialActivityLimit fetchByPrimaryKey(
105                    long activityLimitId)
106                    throws com.liferay.portal.kernel.exception.SystemException;
107    
108            /**
109            * Returns all the social activity limits where classNameId = &#63; and classPK = &#63;.
110            *
111            * @param classNameId the class name ID
112            * @param classPK the class p k
113            * @return the matching social activity limits
114            * @throws SystemException if a system exception occurred
115            */
116            public java.util.List<com.liferay.portlet.social.model.SocialActivityLimit> findByC_C(
117                    long classNameId, long classPK)
118                    throws com.liferay.portal.kernel.exception.SystemException;
119    
120            /**
121            * Returns a range of all the social activity limits where classNameId = &#63; and classPK = &#63;.
122            *
123            * <p>
124            * 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.
125            * </p>
126            *
127            * @param classNameId the class name ID
128            * @param classPK the class p k
129            * @param start the lower bound of the range of social activity limits
130            * @param end the upper bound of the range of social activity limits (not inclusive)
131            * @return the range of matching social activity limits
132            * @throws SystemException if a system exception occurred
133            */
134            public java.util.List<com.liferay.portlet.social.model.SocialActivityLimit> findByC_C(
135                    long classNameId, long classPK, int start, int end)
136                    throws com.liferay.portal.kernel.exception.SystemException;
137    
138            /**
139            * Returns an ordered range of all the social activity limits where classNameId = &#63; and classPK = &#63;.
140            *
141            * <p>
142            * 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.
143            * </p>
144            *
145            * @param classNameId the class name ID
146            * @param classPK the class p k
147            * @param start the lower bound of the range of social activity limits
148            * @param end the upper bound of the range of social activity limits (not inclusive)
149            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
150            * @return the ordered range of matching social activity limits
151            * @throws SystemException if a system exception occurred
152            */
153            public java.util.List<com.liferay.portlet.social.model.SocialActivityLimit> findByC_C(
154                    long classNameId, long classPK, int start, int end,
155                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
156                    throws com.liferay.portal.kernel.exception.SystemException;
157    
158            /**
159            * Returns the first social activity limit in the ordered set where classNameId = &#63; and classPK = &#63;.
160            *
161            * <p>
162            * 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.
163            * </p>
164            *
165            * @param classNameId the class name ID
166            * @param classPK the class p k
167            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
168            * @return the first matching social activity limit
169            * @throws com.liferay.portlet.social.NoSuchActivityLimitException if a matching social activity limit could not be found
170            * @throws SystemException if a system exception occurred
171            */
172            public com.liferay.portlet.social.model.SocialActivityLimit findByC_C_First(
173                    long classNameId, long classPK,
174                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
175                    throws com.liferay.portal.kernel.exception.SystemException,
176                            com.liferay.portlet.social.NoSuchActivityLimitException;
177    
178            /**
179            * Returns the last social activity limit in the ordered set where classNameId = &#63; and classPK = &#63;.
180            *
181            * <p>
182            * 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.
183            * </p>
184            *
185            * @param classNameId the class name ID
186            * @param classPK the class p k
187            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
188            * @return the last matching social activity limit
189            * @throws com.liferay.portlet.social.NoSuchActivityLimitException if a matching social activity limit could not be found
190            * @throws SystemException if a system exception occurred
191            */
192            public com.liferay.portlet.social.model.SocialActivityLimit findByC_C_Last(
193                    long classNameId, long classPK,
194                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
195                    throws com.liferay.portal.kernel.exception.SystemException,
196                            com.liferay.portlet.social.NoSuchActivityLimitException;
197    
198            /**
199            * Returns the social activity limits before and after the current social activity limit in the ordered set where classNameId = &#63; and classPK = &#63;.
200            *
201            * <p>
202            * 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.
203            * </p>
204            *
205            * @param activityLimitId the primary key of the current social activity limit
206            * @param classNameId the class name ID
207            * @param classPK the class p k
208            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
209            * @return the previous, current, and next social activity limit
210            * @throws com.liferay.portlet.social.NoSuchActivityLimitException if a social activity limit with the primary key could not be found
211            * @throws SystemException if a system exception occurred
212            */
213            public com.liferay.portlet.social.model.SocialActivityLimit[] findByC_C_PrevAndNext(
214                    long activityLimitId, long classNameId, long classPK,
215                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
216                    throws com.liferay.portal.kernel.exception.SystemException,
217                            com.liferay.portlet.social.NoSuchActivityLimitException;
218    
219            /**
220            * Returns the social activity limit where groupId = &#63; and userId = &#63; and classNameId = &#63; and classPK = &#63; and activityType = &#63; and activityCounterName = &#63; or throws a {@link com.liferay.portlet.social.NoSuchActivityLimitException} if it could not be found.
221            *
222            * @param groupId the group ID
223            * @param userId the user ID
224            * @param classNameId the class name ID
225            * @param classPK the class p k
226            * @param activityType the activity type
227            * @param activityCounterName the activity counter name
228            * @return the matching social activity limit
229            * @throws com.liferay.portlet.social.NoSuchActivityLimitException if a matching social activity limit could not be found
230            * @throws SystemException if a system exception occurred
231            */
232            public com.liferay.portlet.social.model.SocialActivityLimit findByG_U_C_C_A_A(
233                    long groupId, long userId, long classNameId, long classPK,
234                    int activityType, java.lang.String activityCounterName)
235                    throws com.liferay.portal.kernel.exception.SystemException,
236                            com.liferay.portlet.social.NoSuchActivityLimitException;
237    
238            /**
239            * Returns the social activity limit where groupId = &#63; and userId = &#63; and classNameId = &#63; and classPK = &#63; and activityType = &#63; and activityCounterName = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
240            *
241            * @param groupId the group ID
242            * @param userId the user ID
243            * @param classNameId the class name ID
244            * @param classPK the class p k
245            * @param activityType the activity type
246            * @param activityCounterName the activity counter name
247            * @return the matching social activity limit, or <code>null</code> if a matching social activity limit could not be found
248            * @throws SystemException if a system exception occurred
249            */
250            public com.liferay.portlet.social.model.SocialActivityLimit fetchByG_U_C_C_A_A(
251                    long groupId, long userId, long classNameId, long classPK,
252                    int activityType, java.lang.String activityCounterName)
253                    throws com.liferay.portal.kernel.exception.SystemException;
254    
255            /**
256            * Returns the social activity limit where groupId = &#63; and userId = &#63; and classNameId = &#63; and classPK = &#63; and activityType = &#63; and activityCounterName = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
257            *
258            * @param groupId the group ID
259            * @param userId the user ID
260            * @param classNameId the class name ID
261            * @param classPK the class p k
262            * @param activityType the activity type
263            * @param activityCounterName the activity counter name
264            * @param retrieveFromCache whether to use the finder cache
265            * @return the matching social activity limit, or <code>null</code> if a matching social activity limit could not be found
266            * @throws SystemException if a system exception occurred
267            */
268            public com.liferay.portlet.social.model.SocialActivityLimit fetchByG_U_C_C_A_A(
269                    long groupId, long userId, long classNameId, long classPK,
270                    int activityType, java.lang.String activityCounterName,
271                    boolean retrieveFromCache)
272                    throws com.liferay.portal.kernel.exception.SystemException;
273    
274            /**
275            * Returns all the social activity limits.
276            *
277            * @return the social activity limits
278            * @throws SystemException if a system exception occurred
279            */
280            public java.util.List<com.liferay.portlet.social.model.SocialActivityLimit> findAll()
281                    throws com.liferay.portal.kernel.exception.SystemException;
282    
283            /**
284            * Returns a range of all the social activity limits.
285            *
286            * <p>
287            * 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.
288            * </p>
289            *
290            * @param start the lower bound of the range of social activity limits
291            * @param end the upper bound of the range of social activity limits (not inclusive)
292            * @return the range of social activity limits
293            * @throws SystemException if a system exception occurred
294            */
295            public java.util.List<com.liferay.portlet.social.model.SocialActivityLimit> findAll(
296                    int start, int end)
297                    throws com.liferay.portal.kernel.exception.SystemException;
298    
299            /**
300            * Returns an ordered range of all the social activity limits.
301            *
302            * <p>
303            * 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.
304            * </p>
305            *
306            * @param start the lower bound of the range of social activity limits
307            * @param end the upper bound of the range of social activity limits (not inclusive)
308            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
309            * @return the ordered range of social activity limits
310            * @throws SystemException if a system exception occurred
311            */
312            public java.util.List<com.liferay.portlet.social.model.SocialActivityLimit> findAll(
313                    int start, int end,
314                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
315                    throws com.liferay.portal.kernel.exception.SystemException;
316    
317            /**
318            * Removes all the social activity limits where classNameId = &#63; and classPK = &#63; from the database.
319            *
320            * @param classNameId the class name ID
321            * @param classPK the class p k
322            * @throws SystemException if a system exception occurred
323            */
324            public void removeByC_C(long classNameId, long classPK)
325                    throws com.liferay.portal.kernel.exception.SystemException;
326    
327            /**
328            * Removes the social activity limit where groupId = &#63; and userId = &#63; and classNameId = &#63; and classPK = &#63; and activityType = &#63; and activityCounterName = &#63; from the database.
329            *
330            * @param groupId the group ID
331            * @param userId the user ID
332            * @param classNameId the class name ID
333            * @param classPK the class p k
334            * @param activityType the activity type
335            * @param activityCounterName the activity counter name
336            * @throws SystemException if a system exception occurred
337            */
338            public void removeByG_U_C_C_A_A(long groupId, long userId,
339                    long classNameId, long classPK, int activityType,
340                    java.lang.String activityCounterName)
341                    throws com.liferay.portal.kernel.exception.SystemException,
342                            com.liferay.portlet.social.NoSuchActivityLimitException;
343    
344            /**
345            * Removes all the social activity limits from the database.
346            *
347            * @throws SystemException if a system exception occurred
348            */
349            public void removeAll()
350                    throws com.liferay.portal.kernel.exception.SystemException;
351    
352            /**
353            * Returns the number of social activity limits where classNameId = &#63; and classPK = &#63;.
354            *
355            * @param classNameId the class name ID
356            * @param classPK the class p k
357            * @return the number of matching social activity limits
358            * @throws SystemException if a system exception occurred
359            */
360            public int countByC_C(long classNameId, long classPK)
361                    throws com.liferay.portal.kernel.exception.SystemException;
362    
363            /**
364            * Returns the number of social activity limits where groupId = &#63; and userId = &#63; and classNameId = &#63; and classPK = &#63; and activityType = &#63; and activityCounterName = &#63;.
365            *
366            * @param groupId the group ID
367            * @param userId the user ID
368            * @param classNameId the class name ID
369            * @param classPK the class p k
370            * @param activityType the activity type
371            * @param activityCounterName the activity counter name
372            * @return the number of matching social activity limits
373            * @throws SystemException if a system exception occurred
374            */
375            public int countByG_U_C_C_A_A(long groupId, long userId, long classNameId,
376                    long classPK, int activityType, java.lang.String activityCounterName)
377                    throws com.liferay.portal.kernel.exception.SystemException;
378    
379            /**
380            * Returns the number of social activity limits.
381            *
382            * @return the number of social activity limits
383            * @throws SystemException if a system exception occurred
384            */
385            public int countAll()
386                    throws com.liferay.portal.kernel.exception.SystemException;
387    
388            public SocialActivityLimit remove(SocialActivityLimit socialActivityLimit)
389                    throws SystemException;
390    }