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.http;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.log.Log;
020    import com.liferay.portal.kernel.log.LogFactoryUtil;
021    
022    import com.liferay.portlet.social.service.SocialActivityServiceUtil;
023    
024    import java.rmi.RemoteException;
025    
026    /**
027     * Provides the SOAP utility for the
028     * {@link com.liferay.portlet.social.service.SocialActivityServiceUtil} service utility. The
029     * static methods of this class calls the same methods of the service utility.
030     * However, the signatures are different because it is difficult for SOAP to
031     * support certain types.
032     *
033     * <p>
034     * ServiceBuilder follows certain rules in translating the methods. For example,
035     * if the method in the service utility returns a {@link java.util.List}, that
036     * is translated to an array of {@link com.liferay.portlet.social.model.SocialActivitySoap}.
037     * If the method in the service utility returns a
038     * {@link com.liferay.portlet.social.model.SocialActivity}, that is translated to a
039     * {@link com.liferay.portlet.social.model.SocialActivitySoap}. Methods that SOAP cannot
040     * safely wire are skipped.
041     * </p>
042     *
043     * <p>
044     * The benefits of using the SOAP utility is that it is cross platform
045     * compatible. SOAP allows different languages like Java, .NET, C++, PHP, and
046     * even Perl, to call the generated services. One drawback of SOAP is that it is
047     * slow because it needs to serialize all calls into a text format (XML).
048     * </p>
049     *
050     * <p>
051     * You can see a list of services at http://localhost:8080/api/axis. Set the
052     * property <b>axis.servlet.hosts.allowed</b> in portal.properties to configure
053     * security.
054     * </p>
055     *
056     * <p>
057     * The SOAP utility is only generated for remote services.
058     * </p>
059     *
060     * @author Brian Wing Shun Chan
061     * @see SocialActivityServiceHttp
062     * @see com.liferay.portlet.social.model.SocialActivitySoap
063     * @see com.liferay.portlet.social.service.SocialActivityServiceUtil
064     * @generated
065     */
066    @ProviderType
067    public class SocialActivityServiceSoap {
068            /**
069            * Returns a range of all the activities done on assets identified by the
070            * class name ID.
071            *
072            * <p>
073            * Useful when paginating results. Returns a maximum of <code>end -
074            * start</code> instances. <code>start</code> and <code>end</code> are not
075            * primary keys, they are indexes in the result set. Thus, <code>0</code>
076            * refers to the first result in the set. Setting both <code>start</code>
077            * and <code>end</code> to {@link
078            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
079            * result set.
080            * </p>
081            *
082            * @param classNameId the target asset's class name ID
083            * @param start the lower bound of the range of results
084            * @param end the upper bound of the range of results (not inclusive)
085            * @return the range of matching activities
086            * @throws PortalException if a permission checker was not initialized
087            */
088            public static com.liferay.portlet.social.model.SocialActivitySoap[] getActivities(
089                    long classNameId, int start, int end) throws RemoteException {
090                    try {
091                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
092                                    SocialActivityServiceUtil.getActivities(classNameId, start, end);
093    
094                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
095                    }
096                    catch (Exception e) {
097                            _log.error(e, e);
098    
099                            throw new RemoteException(e.getMessage());
100                    }
101            }
102    
103            /**
104            * Returns a range of all the activities done on the asset identified by the
105            * class name ID and class primary key that are mirrors of the activity
106            * identified by the mirror activity ID.
107            *
108            * <p>
109            * Useful when paginating results. Returns a maximum of <code>end -
110            * start</code> instances. <code>start</code> and <code>end</code> are not
111            * primary keys, they are indexes in the result set. Thus, <code>0</code>
112            * refers to the first result in the set. Setting both <code>start</code>
113            * and <code>end</code> to {@link
114            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
115            * result set.
116            * </p>
117            *
118            * @param mirrorActivityId the primary key of the mirror activity
119            * @param classNameId the target asset's class name ID
120            * @param classPK the primary key of the target asset
121            * @param start the lower bound of the range of results
122            * @param end the upper bound of the range of results (not inclusive)
123            * @return the range of matching activities
124            * @throws PortalException if a permission checker was not initialized
125            */
126            public static com.liferay.portlet.social.model.SocialActivitySoap[] getActivities(
127                    long mirrorActivityId, long classNameId, long classPK, int start,
128                    int end) throws RemoteException {
129                    try {
130                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
131                                    SocialActivityServiceUtil.getActivities(mirrorActivityId,
132                                            classNameId, classPK, start, end);
133    
134                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
135                    }
136                    catch (Exception e) {
137                            _log.error(e, e);
138    
139                            throw new RemoteException(e.getMessage());
140                    }
141            }
142    
143            /**
144            * Returns a range of all the activities done on the asset identified by the
145            * class name and the class primary key that are mirrors of the activity
146            * identified by the mirror activity ID.
147            *
148            * <p>
149            * Useful when paginating results. Returns a maximum of <code>end -
150            * start</code> instances. <code>start</code> and <code>end</code> are not
151            * primary keys, they are indexes in the result set. Thus, <code>0</code>
152            * refers to the first result in the set. Setting both <code>start</code>
153            * and <code>end</code> to {@link
154            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
155            * result set.
156            * </p>
157            *
158            * @param mirrorActivityId the primary key of the mirror activity
159            * @param className the target asset's class name
160            * @param classPK the primary key of the target asset
161            * @param start the lower bound of the range of results
162            * @param end the upper bound of the range of results (not inclusive)
163            * @return the range of matching activities
164            * @throws PortalException if a permission checker was not initialized
165            */
166            public static com.liferay.portlet.social.model.SocialActivitySoap[] getActivities(
167                    long mirrorActivityId, java.lang.String className, long classPK,
168                    int start, int end) throws RemoteException {
169                    try {
170                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
171                                    SocialActivityServiceUtil.getActivities(mirrorActivityId,
172                                            className, classPK, start, end);
173    
174                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
175                    }
176                    catch (Exception e) {
177                            _log.error(e, e);
178    
179                            throw new RemoteException(e.getMessage());
180                    }
181            }
182    
183            /**
184            * Returns a range of all the activities done on assets identified by the
185            * class name.
186            *
187            * <p>
188            * Useful when paginating results. Returns a maximum of <code>end -
189            * start</code> instances. <code>start</code> and <code>end</code> are not
190            * primary keys, they are indexes in the result set. Thus, <code>0</code>
191            * refers to the first result in the set. Setting both <code>start</code>
192            * and <code>end</code> to {@link
193            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
194            * result set.
195            * </p>
196            *
197            * @param className the target asset's class name
198            * @param start the lower bound of the range of results
199            * @param end the upper bound of the range of results (not inclusive)
200            * @return the range of matching activities
201            * @throws PortalException if a permission checker was not initialized
202            */
203            public static com.liferay.portlet.social.model.SocialActivitySoap[] getActivities(
204                    java.lang.String className, int start, int end)
205                    throws RemoteException {
206                    try {
207                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
208                                    SocialActivityServiceUtil.getActivities(className, start, end);
209    
210                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
211                    }
212                    catch (Exception e) {
213                            _log.error(e, e);
214    
215                            throw new RemoteException(e.getMessage());
216                    }
217            }
218    
219            /**
220            * Returns the number of activities done on assets identified by the class
221            * name ID.
222            *
223            * @param classNameId the target asset's class name ID
224            * @return the number of matching activities
225            */
226            public static int getActivitiesCount(long classNameId)
227                    throws RemoteException {
228                    try {
229                            int returnValue = SocialActivityServiceUtil.getActivitiesCount(classNameId);
230    
231                            return returnValue;
232                    }
233                    catch (Exception e) {
234                            _log.error(e, e);
235    
236                            throw new RemoteException(e.getMessage());
237                    }
238            }
239    
240            /**
241            * Returns the number of activities done on the asset identified by the
242            * class name ID and class primary key that are mirrors of the activity
243            * identified by the mirror activity ID.
244            *
245            * @param mirrorActivityId the primary key of the mirror activity
246            * @param classNameId the target asset's class name ID
247            * @param classPK the primary key of the target asset
248            * @return the number of matching activities
249            */
250            public static int getActivitiesCount(long mirrorActivityId,
251                    long classNameId, long classPK) throws RemoteException {
252                    try {
253                            int returnValue = SocialActivityServiceUtil.getActivitiesCount(mirrorActivityId,
254                                            classNameId, classPK);
255    
256                            return returnValue;
257                    }
258                    catch (Exception e) {
259                            _log.error(e, e);
260    
261                            throw new RemoteException(e.getMessage());
262                    }
263            }
264    
265            /**
266            * Returns the number of activities done on the asset identified by the
267            * class name and class primary key that are mirrors of the activity
268            * identified by the mirror activity ID.
269            *
270            * @param mirrorActivityId the primary key of the mirror activity
271            * @param className the target asset's class name
272            * @param classPK the primary key of the target asset
273            * @return the number of matching activities
274            */
275            public static int getActivitiesCount(long mirrorActivityId,
276                    java.lang.String className, long classPK) throws RemoteException {
277                    try {
278                            int returnValue = SocialActivityServiceUtil.getActivitiesCount(mirrorActivityId,
279                                            className, classPK);
280    
281                            return returnValue;
282                    }
283                    catch (Exception e) {
284                            _log.error(e, e);
285    
286                            throw new RemoteException(e.getMessage());
287                    }
288            }
289    
290            /**
291            * Returns the number of activities done on assets identified by class name.
292            *
293            * @param className the target asset's class name
294            * @return the number of matching activities
295            */
296            public static int getActivitiesCount(java.lang.String className)
297                    throws RemoteException {
298                    try {
299                            int returnValue = SocialActivityServiceUtil.getActivitiesCount(className);
300    
301                            return returnValue;
302                    }
303                    catch (Exception e) {
304                            _log.error(e, e);
305    
306                            throw new RemoteException(e.getMessage());
307                    }
308            }
309    
310            /**
311            * Returns the activity identified by its primary key.
312            *
313            * @param activityId the primary key of the activity
314            * @return Returns the activity
315            * @throws PortalException if the activity could not be found
316            */
317            public static com.liferay.portlet.social.model.SocialActivitySoap getActivity(
318                    long activityId) throws RemoteException {
319                    try {
320                            com.liferay.portlet.social.model.SocialActivity returnValue = SocialActivityServiceUtil.getActivity(activityId);
321    
322                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModel(returnValue);
323                    }
324                    catch (Exception e) {
325                            _log.error(e, e);
326    
327                            throw new RemoteException(e.getMessage());
328                    }
329            }
330    
331            public static com.liferay.portlet.social.model.SocialActivitySoap[] getActivitySetActivities(
332                    long activitySetId, int start, int end) throws RemoteException {
333                    try {
334                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
335                                    SocialActivityServiceUtil.getActivitySetActivities(activitySetId,
336                                            start, end);
337    
338                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
339                    }
340                    catch (Exception e) {
341                            _log.error(e, e);
342    
343                            throw new RemoteException(e.getMessage());
344                    }
345            }
346    
347            /**
348            * Returns a range of all the activities done in the group.
349            *
350            * <p>
351            * This method only finds activities without mirrors.
352            * </p>
353            *
354            * <p>
355            * Useful when paginating results. Returns a maximum of <code>end -
356            * start</code> instances. <code>start</code> and <code>end</code> are not
357            * primary keys, they are indexes in the result set. Thus, <code>0</code>
358            * refers to the first result in the set. Setting both <code>start</code>
359            * and <code>end</code> to {@link
360            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
361            * result set.
362            * </p>
363            *
364            * @param groupId the primary key of the group
365            * @param start the lower bound of the range of results
366            * @param end the upper bound of the range of results (not inclusive)
367            * @return the range of matching activities
368            * @throws PortalException if a permission checker was not initialized
369            */
370            public static com.liferay.portlet.social.model.SocialActivitySoap[] getGroupActivities(
371                    long groupId, int start, int end) throws RemoteException {
372                    try {
373                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
374                                    SocialActivityServiceUtil.getGroupActivities(groupId, start, end);
375    
376                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
377                    }
378                    catch (Exception e) {
379                            _log.error(e, e);
380    
381                            throw new RemoteException(e.getMessage());
382                    }
383            }
384    
385            /**
386            * Returns the number of activities done in the group.
387            *
388            * <p>
389            * This method only counts activities without mirrors.
390            * </p>
391            *
392            * @param groupId the primary key of the group
393            * @return the number of matching activities
394            */
395            public static int getGroupActivitiesCount(long groupId)
396                    throws RemoteException {
397                    try {
398                            int returnValue = SocialActivityServiceUtil.getGroupActivitiesCount(groupId);
399    
400                            return returnValue;
401                    }
402                    catch (Exception e) {
403                            _log.error(e, e);
404    
405                            throw new RemoteException(e.getMessage());
406                    }
407            }
408    
409            /**
410            * Returns a range of activities done by users that are members of the
411            * group.
412            *
413            * <p>
414            * This method only finds activities without mirrors.
415            * </p>
416            *
417            * <p>
418            * Useful when paginating results. Returns a maximum of <code>end -
419            * start</code> instances. <code>start</code> and <code>end</code> are not
420            * primary keys, they are indexes in the result set. Thus, <code>0</code>
421            * refers to the first result in the set. Setting both <code>start</code>
422            * and <code>end</code> to {@link
423            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
424            * result set.
425            * </p>
426            *
427            * @param groupId the primary key of the group
428            * @param start the lower bound of the range of results
429            * @param end the upper bound of the range of results (not inclusive)
430            * @return the range of matching activities
431            * @throws PortalException if a permission checker was not initialized
432            */
433            public static com.liferay.portlet.social.model.SocialActivitySoap[] getGroupUsersActivities(
434                    long groupId, int start, int end) throws RemoteException {
435                    try {
436                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
437                                    SocialActivityServiceUtil.getGroupUsersActivities(groupId,
438                                            start, end);
439    
440                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
441                    }
442                    catch (Exception e) {
443                            _log.error(e, e);
444    
445                            throw new RemoteException(e.getMessage());
446                    }
447            }
448    
449            /**
450            * Returns the number of activities done by users that are members of the
451            * group.
452            *
453            * <p>
454            * This method only counts activities without mirrors.
455            * </p>
456            *
457            * @param groupId the primary key of the group
458            * @return the number of matching activities
459            */
460            public static int getGroupUsersActivitiesCount(long groupId)
461                    throws RemoteException {
462                    try {
463                            int returnValue = SocialActivityServiceUtil.getGroupUsersActivitiesCount(groupId);
464    
465                            return returnValue;
466                    }
467                    catch (Exception e) {
468                            _log.error(e, e);
469    
470                            throw new RemoteException(e.getMessage());
471                    }
472            }
473    
474            /**
475            * Returns the activity that has the mirror activity.
476            *
477            * @param mirrorActivityId the primary key of the mirror activity
478            * @return Returns the mirror activity
479            * @throws PortalException if the mirror activity could not be found
480            */
481            public static com.liferay.portlet.social.model.SocialActivitySoap getMirrorActivity(
482                    long mirrorActivityId) throws RemoteException {
483                    try {
484                            com.liferay.portlet.social.model.SocialActivity returnValue = SocialActivityServiceUtil.getMirrorActivity(mirrorActivityId);
485    
486                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModel(returnValue);
487                    }
488                    catch (Exception e) {
489                            _log.error(e, e);
490    
491                            throw new RemoteException(e.getMessage());
492                    }
493            }
494    
495            /**
496            * Returns a range of all the activities done in the organization. This
497            * method only finds activities without mirrors.
498            *
499            * <p>
500            * Useful when paginating results. Returns a maximum of <code>end -
501            * start</code> instances. <code>start</code> and <code>end</code> are not
502            * primary keys, they are indexes in the result set. Thus, <code>0</code>
503            * refers to the first result in the set. Setting both <code>start</code>
504            * and <code>end</code> to {@link
505            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
506            * result set.
507            * </p>
508            *
509            * @param organizationId the primary key of the organization
510            * @param start the lower bound of the range of results
511            * @param end the upper bound of the range of results (not inclusive)
512            * @return the range of matching activities
513            * @throws PortalException if a permission checker was not initialized
514            */
515            public static com.liferay.portlet.social.model.SocialActivitySoap[] getOrganizationActivities(
516                    long organizationId, int start, int end) throws RemoteException {
517                    try {
518                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
519                                    SocialActivityServiceUtil.getOrganizationActivities(organizationId,
520                                            start, end);
521    
522                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
523                    }
524                    catch (Exception e) {
525                            _log.error(e, e);
526    
527                            throw new RemoteException(e.getMessage());
528                    }
529            }
530    
531            /**
532            * Returns the number of activities done in the organization. This method
533            * only counts activities without mirrors.
534            *
535            * @param organizationId the primary key of the organization
536            * @return the number of matching activities
537            */
538            public static int getOrganizationActivitiesCount(long organizationId)
539                    throws RemoteException {
540                    try {
541                            int returnValue = SocialActivityServiceUtil.getOrganizationActivitiesCount(organizationId);
542    
543                            return returnValue;
544                    }
545                    catch (Exception e) {
546                            _log.error(e, e);
547    
548                            throw new RemoteException(e.getMessage());
549                    }
550            }
551    
552            /**
553            * Returns a range of all the activities done by users of the organization.
554            * This method only finds activities without mirrors.
555            *
556            * <p>
557            * Useful when paginating results. Returns a maximum of <code>end -
558            * start</code> instances. <code>start</code> and <code>end</code> are not
559            * primary keys, they are indexes in the result set. Thus, <code>0</code>
560            * refers to the first result in the set. Setting both <code>start</code>
561            * and <code>end</code> to {@link
562            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
563            * result set.
564            * </p>
565            *
566            * @param organizationId the primary key of the organization
567            * @param start the lower bound of the range of results
568            * @param end the upper bound of the range of results (not inclusive)
569            * @return the range of matching activities
570            * @throws PortalException if a permission checker was not initialized
571            */
572            public static com.liferay.portlet.social.model.SocialActivitySoap[] getOrganizationUsersActivities(
573                    long organizationId, int start, int end) throws RemoteException {
574                    try {
575                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
576                                    SocialActivityServiceUtil.getOrganizationUsersActivities(organizationId,
577                                            start, end);
578    
579                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
580                    }
581                    catch (Exception e) {
582                            _log.error(e, e);
583    
584                            throw new RemoteException(e.getMessage());
585                    }
586            }
587    
588            /**
589            * Returns the number of activities done by users of the organization. This
590            * method only counts activities without mirrors.
591            *
592            * @param organizationId the primary key of the organization
593            * @return the number of matching activities
594            */
595            public static int getOrganizationUsersActivitiesCount(long organizationId)
596                    throws RemoteException {
597                    try {
598                            int returnValue = SocialActivityServiceUtil.getOrganizationUsersActivitiesCount(organizationId);
599    
600                            return returnValue;
601                    }
602                    catch (Exception e) {
603                            _log.error(e, e);
604    
605                            throw new RemoteException(e.getMessage());
606                    }
607            }
608    
609            /**
610            * Returns a range of all the activities done by users in a relationship
611            * with the user identified by the user ID.
612            *
613            * <p>
614            * Useful when paginating results. Returns a maximum of <code>end -
615            * start</code> instances. <code>start</code> and <code>end</code> are not
616            * primary keys, they are indexes in the result set. Thus, <>0</code> refers
617            * to the first result in the set. Setting both <code>start</code> and
618            * <code>end</code> to {@link
619            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
620            * result set.
621            * </p>
622            *
623            * @param userId the primary key of the user
624            * @param start the lower bound of the range of results
625            * @param end the upper bound of the range of results (not inclusive)
626            * @return the range of matching activities
627            * @throws PortalException if a permission checker was not initialized
628            */
629            public static com.liferay.portlet.social.model.SocialActivitySoap[] getRelationActivities(
630                    long userId, int start, int end) throws RemoteException {
631                    try {
632                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
633                                    SocialActivityServiceUtil.getRelationActivities(userId, start,
634                                            end);
635    
636                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
637                    }
638                    catch (Exception e) {
639                            _log.error(e, e);
640    
641                            throw new RemoteException(e.getMessage());
642                    }
643            }
644    
645            /**
646            * Returns a range of all the activities done by users in a relationship of
647            * type <code>type</code> with the user identified by <code>userId</code>.
648            * This method only finds activities without mirrors.
649            *
650            * <p>
651            * Useful when paginating results. Returns a maximum of <code>end -
652            * start</code> instances. <code>start</code> and <code>end</code> are not
653            * primary keys, they are indexes in the result set. Thus, <code>0</code>
654            * refers to the first result in the set. Setting both <code>start</code>
655            * and <code>end</code> to {@link
656            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
657            * result set.
658            * </p>
659            *
660            * @param userId the primary key of the user
661            * @param type the relationship type
662            * @param start the lower bound of the range of results
663            * @param end the upper bound of the range of results (not inclusive)
664            * @return the range of matching activities
665            * @throws PortalException if a permission checker was not initialized
666            */
667            public static com.liferay.portlet.social.model.SocialActivitySoap[] getRelationActivities(
668                    long userId, int type, int start, int end) throws RemoteException {
669                    try {
670                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
671                                    SocialActivityServiceUtil.getRelationActivities(userId, type,
672                                            start, end);
673    
674                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
675                    }
676                    catch (Exception e) {
677                            _log.error(e, e);
678    
679                            throw new RemoteException(e.getMessage());
680                    }
681            }
682    
683            /**
684            * Returns the number of activities done by users in a relationship with the
685            * user identified by userId.
686            *
687            * @param userId the primary key of the user
688            * @return the number of matching activities
689            */
690            public static int getRelationActivitiesCount(long userId)
691                    throws RemoteException {
692                    try {
693                            int returnValue = SocialActivityServiceUtil.getRelationActivitiesCount(userId);
694    
695                            return returnValue;
696                    }
697                    catch (Exception e) {
698                            _log.error(e, e);
699    
700                            throw new RemoteException(e.getMessage());
701                    }
702            }
703    
704            /**
705            * Returns the number of activities done by users in a relationship of type
706            * <code>type</code> with the user identified by <code>userId</code>. This
707            * method only counts activities without mirrors.
708            *
709            * @param userId the primary key of the user
710            * @param type the relationship type
711            * @return the number of matching activities
712            */
713            public static int getRelationActivitiesCount(long userId, int type)
714                    throws RemoteException {
715                    try {
716                            int returnValue = SocialActivityServiceUtil.getRelationActivitiesCount(userId,
717                                            type);
718    
719                            return returnValue;
720                    }
721                    catch (Exception e) {
722                            _log.error(e, e);
723    
724                            throw new RemoteException(e.getMessage());
725                    }
726            }
727    
728            /**
729            * Returns a range of all the activities done by the user.
730            *
731            * <p>
732            * Useful when paginating results. Returns a maximum of <code>end -
733            * start</code> instances. <code>start</code> and <code>end</code> are not
734            * primary keys, they are indexes in the result set. Thus, <code>0</code>
735            * refers to the first result in the set. Setting both <code>start</code>
736            * and <code>end</code> to {@link
737            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
738            * result set.
739            * </p>
740            *
741            * @param userId the primary key of the user
742            * @param start the lower bound of the range of results
743            * @param end the upper bound of the range of results (not inclusive)
744            * @return the range of matching activities
745            * @throws PortalException if a permission checker was not initialized
746            */
747            public static com.liferay.portlet.social.model.SocialActivitySoap[] getUserActivities(
748                    long userId, int start, int end) throws RemoteException {
749                    try {
750                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
751                                    SocialActivityServiceUtil.getUserActivities(userId, start, end);
752    
753                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
754                    }
755                    catch (Exception e) {
756                            _log.error(e, e);
757    
758                            throw new RemoteException(e.getMessage());
759                    }
760            }
761    
762            /**
763            * Returns the number of activities done by the user.
764            *
765            * @param userId the primary key of the user
766            * @return the number of matching activities
767            */
768            public static int getUserActivitiesCount(long userId)
769                    throws RemoteException {
770                    try {
771                            int returnValue = SocialActivityServiceUtil.getUserActivitiesCount(userId);
772    
773                            return returnValue;
774                    }
775                    catch (Exception e) {
776                            _log.error(e, e);
777    
778                            throw new RemoteException(e.getMessage());
779                    }
780            }
781    
782            /**
783            * Returns a range of all the activities done in the user's groups. This
784            * method only finds activities without mirrors.
785            *
786            * <p>
787            * Useful when paginating results. Returns a maximum of <code>end -
788            * start</code> instances. <code>start</code> and <code>end</code> are not
789            * primary keys, they are indexes in the result set. Thus, <code>0</code>
790            * refers to the first result in the set. Setting both <code>start</code>
791            * and <code>end</code> to {@link
792            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
793            * result set.
794            * </p>
795            *
796            * @param userId the primary key of the user
797            * @param start the lower bound of the range of results
798            * @param end the upper bound of the range of results (not inclusive)
799            * @return the range of matching activities
800            * @throws PortalException if a permission checker was not initialized
801            */
802            public static com.liferay.portlet.social.model.SocialActivitySoap[] getUserGroupsActivities(
803                    long userId, int start, int end) throws RemoteException {
804                    try {
805                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
806                                    SocialActivityServiceUtil.getUserGroupsActivities(userId,
807                                            start, end);
808    
809                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
810                    }
811                    catch (Exception e) {
812                            _log.error(e, e);
813    
814                            throw new RemoteException(e.getMessage());
815                    }
816            }
817    
818            /**
819            * Returns the number of activities done in user's groups. This method only
820            * counts activities without mirrors.
821            *
822            * @param userId the primary key of the user
823            * @return the number of matching activities
824            */
825            public static int getUserGroupsActivitiesCount(long userId)
826                    throws RemoteException {
827                    try {
828                            int returnValue = SocialActivityServiceUtil.getUserGroupsActivitiesCount(userId);
829    
830                            return returnValue;
831                    }
832                    catch (Exception e) {
833                            _log.error(e, e);
834    
835                            throw new RemoteException(e.getMessage());
836                    }
837            }
838    
839            /**
840            * Returns a range of all the activities done in the user's groups and
841            * organizations. This method only finds activities without mirrors.
842            *
843            * <p>
844            * Useful when paginating results. Returns a maximum of <code>end -
845            * start</code> instances. <code>start</code> and <code>end</code> are not
846            * primary keys, they are indexes in the result set. Thus, <code>0</code>
847            * refers to the first result in the set. Setting both <code>start</code>
848            * and <code>end</code> to {@link
849            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
850            * result set.
851            * </p>
852            *
853            * @param userId the primary key of the user
854            * @param start the lower bound of the range of results
855            * @param end the upper bound of the range of results (not inclusive)
856            * @return the range of matching activities
857            * @throws PortalException if a permission checker was not initialized
858            */
859            public static com.liferay.portlet.social.model.SocialActivitySoap[] getUserGroupsAndOrganizationsActivities(
860                    long userId, int start, int end) throws RemoteException {
861                    try {
862                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
863                                    SocialActivityServiceUtil.getUserGroupsAndOrganizationsActivities(userId,
864                                            start, end);
865    
866                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
867                    }
868                    catch (Exception e) {
869                            _log.error(e, e);
870    
871                            throw new RemoteException(e.getMessage());
872                    }
873            }
874    
875            /**
876            * Returns the number of activities done in user's groups and organizations.
877            * This method only counts activities without mirrors.
878            *
879            * @param userId the primary key of the user
880            * @return the number of matching activities
881            */
882            public static int getUserGroupsAndOrganizationsActivitiesCount(long userId)
883                    throws RemoteException {
884                    try {
885                            int returnValue = SocialActivityServiceUtil.getUserGroupsAndOrganizationsActivitiesCount(userId);
886    
887                            return returnValue;
888                    }
889                    catch (Exception e) {
890                            _log.error(e, e);
891    
892                            throw new RemoteException(e.getMessage());
893                    }
894            }
895    
896            /**
897            * Returns a range of all activities done in the user's organizations. This
898            * method only finds activities without mirrors.
899            *
900            * <p>
901            * Useful when paginating results. Returns a maximum of <code>end -
902            * start</code> instances. <code>start</code> and <code>end</code> are not
903            * primary keys, they are indexes in the result set. Thus, <code>0</code>
904            * refers to the first result in the set. Setting both <code>start</code>
905            * and <code>end</code> to {@link
906            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
907            * result set.
908            * </p>
909            *
910            * @param userId the primary key of the user
911            * @param start the lower bound of the range of results
912            * @param end the upper bound of the range of results (not inclusive)
913            * @return the range of matching activities
914            * @throws PortalException if a permission checker was not initialized
915            */
916            public static com.liferay.portlet.social.model.SocialActivitySoap[] getUserOrganizationsActivities(
917                    long userId, int start, int end) throws RemoteException {
918                    try {
919                            java.util.List<com.liferay.portlet.social.model.SocialActivity> returnValue =
920                                    SocialActivityServiceUtil.getUserOrganizationsActivities(userId,
921                                            start, end);
922    
923                            return com.liferay.portlet.social.model.SocialActivitySoap.toSoapModels(returnValue);
924                    }
925                    catch (Exception e) {
926                            _log.error(e, e);
927    
928                            throw new RemoteException(e.getMessage());
929                    }
930            }
931    
932            /**
933            * Returns the number of activities done in the user's organizations. This
934            * method only counts activities without mirrors.
935            *
936            * @param userId the primary key of the user
937            * @return the number of matching activities
938            */
939            public static int getUserOrganizationsActivitiesCount(long userId)
940                    throws RemoteException {
941                    try {
942                            int returnValue = SocialActivityServiceUtil.getUserOrganizationsActivitiesCount(userId);
943    
944                            return returnValue;
945                    }
946                    catch (Exception e) {
947                            _log.error(e, e);
948    
949                            throw new RemoteException(e.getMessage());
950                    }
951            }
952    
953            private static Log _log = LogFactoryUtil.getLog(SocialActivityServiceSoap.class);
954    }