001
014
015 package com.liferay.portlet.social.service;
016
017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018 import com.liferay.portal.kernel.util.MethodCache;
019 import com.liferay.portal.kernel.util.ReferenceRegistry;
020
021
034 public class SocialActivityCounterLocalServiceUtil {
035
040
041
048 public static com.liferay.portlet.social.model.SocialActivityCounter addSocialActivityCounter(
049 com.liferay.portlet.social.model.SocialActivityCounter socialActivityCounter)
050 throws com.liferay.portal.kernel.exception.SystemException {
051 return getService().addSocialActivityCounter(socialActivityCounter);
052 }
053
054
060 public static com.liferay.portlet.social.model.SocialActivityCounter createSocialActivityCounter(
061 long activityCounterId) {
062 return getService().createSocialActivityCounter(activityCounterId);
063 }
064
065
072 public static void deleteSocialActivityCounter(long activityCounterId)
073 throws com.liferay.portal.kernel.exception.PortalException,
074 com.liferay.portal.kernel.exception.SystemException {
075 getService().deleteSocialActivityCounter(activityCounterId);
076 }
077
078
084 public static void deleteSocialActivityCounter(
085 com.liferay.portlet.social.model.SocialActivityCounter socialActivityCounter)
086 throws com.liferay.portal.kernel.exception.SystemException {
087 getService().deleteSocialActivityCounter(socialActivityCounter);
088 }
089
090
097 @SuppressWarnings("rawtypes")
098 public static java.util.List dynamicQuery(
099 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
100 throws com.liferay.portal.kernel.exception.SystemException {
101 return getService().dynamicQuery(dynamicQuery);
102 }
103
104
117 @SuppressWarnings("rawtypes")
118 public static java.util.List dynamicQuery(
119 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
120 int end) throws com.liferay.portal.kernel.exception.SystemException {
121 return getService().dynamicQuery(dynamicQuery, start, end);
122 }
123
124
138 @SuppressWarnings("rawtypes")
139 public static java.util.List dynamicQuery(
140 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
141 int end,
142 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
143 throws com.liferay.portal.kernel.exception.SystemException {
144 return getService()
145 .dynamicQuery(dynamicQuery, start, end, orderByComparator);
146 }
147
148
155 public static long dynamicQueryCount(
156 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
157 throws com.liferay.portal.kernel.exception.SystemException {
158 return getService().dynamicQueryCount(dynamicQuery);
159 }
160
161 public static com.liferay.portlet.social.model.SocialActivityCounter fetchSocialActivityCounter(
162 long activityCounterId)
163 throws com.liferay.portal.kernel.exception.SystemException {
164 return getService().fetchSocialActivityCounter(activityCounterId);
165 }
166
167
175 public static com.liferay.portlet.social.model.SocialActivityCounter getSocialActivityCounter(
176 long activityCounterId)
177 throws com.liferay.portal.kernel.exception.PortalException,
178 com.liferay.portal.kernel.exception.SystemException {
179 return getService().getSocialActivityCounter(activityCounterId);
180 }
181
182 public static com.liferay.portal.model.PersistedModel getPersistedModel(
183 java.io.Serializable primaryKeyObj)
184 throws com.liferay.portal.kernel.exception.PortalException,
185 com.liferay.portal.kernel.exception.SystemException {
186 return getService().getPersistedModel(primaryKeyObj);
187 }
188
189
201 public static java.util.List<com.liferay.portlet.social.model.SocialActivityCounter> getSocialActivityCounters(
202 int start, int end)
203 throws com.liferay.portal.kernel.exception.SystemException {
204 return getService().getSocialActivityCounters(start, end);
205 }
206
207
213 public static int getSocialActivityCountersCount()
214 throws com.liferay.portal.kernel.exception.SystemException {
215 return getService().getSocialActivityCountersCount();
216 }
217
218
225 public static com.liferay.portlet.social.model.SocialActivityCounter updateSocialActivityCounter(
226 com.liferay.portlet.social.model.SocialActivityCounter socialActivityCounter)
227 throws com.liferay.portal.kernel.exception.SystemException {
228 return getService().updateSocialActivityCounter(socialActivityCounter);
229 }
230
231
239 public static com.liferay.portlet.social.model.SocialActivityCounter updateSocialActivityCounter(
240 com.liferay.portlet.social.model.SocialActivityCounter socialActivityCounter,
241 boolean merge)
242 throws com.liferay.portal.kernel.exception.SystemException {
243 return getService()
244 .updateSocialActivityCounter(socialActivityCounter, merge);
245 }
246
247
252 public static java.lang.String getBeanIdentifier() {
253 return getService().getBeanIdentifier();
254 }
255
256
261 public static void setBeanIdentifier(java.lang.String beanIdentifier) {
262 getService().setBeanIdentifier(beanIdentifier);
263 }
264
265 public static com.liferay.portlet.social.model.SocialActivityCounter addActivityCounter(
266 long groupId, long classNameId, long classPK, java.lang.String name,
267 int ownerType, int currentValue, int totalValue, int startPeriod,
268 int endPeriod)
269 throws com.liferay.portal.kernel.exception.PortalException,
270 com.liferay.portal.kernel.exception.SystemException {
271 return getService()
272 .addActivityCounter(groupId, classNameId, classPK, name,
273 ownerType, currentValue, totalValue, startPeriod, endPeriod);
274 }
275
276 public static void addActivityCounters(
277 com.liferay.portlet.social.model.SocialActivity activity)
278 throws com.liferay.portal.kernel.exception.PortalException,
279 com.liferay.portal.kernel.exception.SystemException {
280 getService().addActivityCounters(activity);
281 }
282
283 public static com.liferay.portlet.social.model.SocialActivityCounter createActivityCounter(
284 long groupId, long classNameId, long classPK, java.lang.String name,
285 int ownerType, int currentValue, int totalValue, int startPeriod,
286 int endPeriod)
287 throws com.liferay.portal.kernel.exception.PortalException,
288 com.liferay.portal.kernel.exception.SystemException {
289 return getService()
290 .createActivityCounter(groupId, classNameId, classPK, name,
291 ownerType, currentValue, totalValue, startPeriod, endPeriod);
292 }
293
294 public static void deleteActivityCounters(
295 com.liferay.portlet.asset.model.AssetEntry assetEntry)
296 throws com.liferay.portal.kernel.exception.PortalException,
297 com.liferay.portal.kernel.exception.SystemException {
298 getService().deleteActivityCounters(assetEntry);
299 }
300
301 public static void deleteActivityCounters(long classNameId, long classPK)
302 throws com.liferay.portal.kernel.exception.SystemException {
303 getService().deleteActivityCounters(classNameId, classPK);
304 }
305
306 public static com.liferay.portlet.social.model.SocialActivityCounter fetchActivityCounterByEndPeriod(
307 long groupId, long classNameId, long classPK, java.lang.String name,
308 int ownerType, int endPeriod)
309 throws com.liferay.portal.kernel.exception.SystemException {
310 return getService()
311 .fetchActivityCounterByEndPeriod(groupId, classNameId,
312 classPK, name, ownerType, endPeriod);
313 }
314
315 public static com.liferay.portlet.social.model.SocialActivityCounter fetchActivityCounterByStartPeriod(
316 long groupId, long classNameId, long classPK, java.lang.String name,
317 int ownerType, int startPeriod)
318 throws com.liferay.portal.kernel.exception.SystemException {
319 return getService()
320 .fetchActivityCounterByStartPeriod(groupId, classNameId,
321 classPK, name, ownerType, startPeriod);
322 }
323
324 public static com.liferay.portlet.social.model.SocialActivityCounter fetchLatestActivityCounter(
325 long groupId, long classNameId, long classPK, java.lang.String name,
326 int ownerType)
327 throws com.liferay.portal.kernel.exception.SystemException {
328 return getService()
329 .fetchLatestActivityCounter(groupId, classNameId, classPK,
330 name, ownerType);
331 }
332
333 public static java.util.List<com.liferay.portlet.social.model.SocialActivityCounter> getOffsetActivityCounters(
334 long groupId, java.lang.String name, int startOffset, int endOffset)
335 throws com.liferay.portal.kernel.exception.SystemException {
336 return getService()
337 .getOffsetActivityCounters(groupId, name, startOffset,
338 endOffset);
339 }
340
341 public static java.util.List<com.liferay.portlet.social.model.SocialActivityCounter> getOffsetDistributionActivityCounters(
342 long groupId, java.lang.String name, int startOffset, int endOffset)
343 throws com.liferay.portal.kernel.exception.SystemException {
344 return getService()
345 .getOffsetDistributionActivityCounters(groupId, name,
346 startOffset, endOffset);
347 }
348
349 public static java.util.List<com.liferay.portlet.social.model.SocialActivityCounter> getPeriodActivityCounters(
350 long groupId, java.lang.String name, int startPeriod, int endPeriod)
351 throws com.liferay.portal.kernel.exception.SystemException {
352 return getService()
353 .getPeriodActivityCounters(groupId, name, startPeriod,
354 endPeriod);
355 }
356
357 public static java.util.List<com.liferay.portlet.social.model.SocialActivityCounter> getPeriodDistributionActivityCounters(
358 long groupId, java.lang.String name, int startPeriod, int endPeriod)
359 throws com.liferay.portal.kernel.exception.SystemException {
360 return getService()
361 .getPeriodDistributionActivityCounters(groupId, name,
362 startPeriod, endPeriod);
363 }
364
365 public static java.util.List<com.liferay.portal.kernel.util.Tuple> getUserActivityCounters(
366 long groupId, java.lang.String[] rankingNames,
367 java.lang.String[] selectedNames, int start, int end)
368 throws com.liferay.portal.kernel.exception.SystemException {
369 return getService()
370 .getUserActivityCounters(groupId, rankingNames,
371 selectedNames, start, end);
372 }
373
374 public static int getUserActivityCountersCount(long groupId,
375 java.lang.String[] rankingNames)
376 throws com.liferay.portal.kernel.exception.SystemException {
377 return getService().getUserActivityCountersCount(groupId, rankingNames);
378 }
379
380 public static void incrementUserAchievementCounter(long userId, long groupId)
381 throws com.liferay.portal.kernel.exception.PortalException,
382 com.liferay.portal.kernel.exception.SystemException {
383 getService().incrementUserAchievementCounter(userId, groupId);
384 }
385
386 public static SocialActivityCounterLocalService getService() {
387 if (_service == null) {
388 _service = (SocialActivityCounterLocalService)PortalBeanLocatorUtil.locate(SocialActivityCounterLocalService.class.getName());
389
390 ReferenceRegistry.registerReference(SocialActivityCounterLocalServiceUtil.class,
391 "_service");
392 MethodCache.remove(SocialActivityCounterLocalService.class);
393 }
394
395 return _service;
396 }
397
398 public void setService(SocialActivityCounterLocalService service) {
399 MethodCache.remove(SocialActivityCounterLocalService.class);
400
401 _service = service;
402
403 ReferenceRegistry.registerReference(SocialActivityCounterLocalServiceUtil.class,
404 "_service");
405 MethodCache.remove(SocialActivityCounterLocalService.class);
406 }
407
408 private static SocialActivityCounterLocalService _service;
409 }