001    /**
002     * Copyright (c) 2000-2012 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;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    import com.liferay.portal.kernel.util.ReferenceRegistry;
019    
020    /**
021     * The utility for the social request local service. This utility wraps {@link com.liferay.portlet.social.service.impl.SocialRequestLocalServiceImpl} and is the primary access point for service operations in application layer code running on the local server.
022     *
023     * <p>
024     * This is a local service. Methods of this service will not have security checks based on the propagated JAAS credentials because this service can only be accessed from within the same VM.
025     * </p>
026     *
027     * @author Brian Wing Shun Chan
028     * @see SocialRequestLocalService
029     * @see com.liferay.portlet.social.service.base.SocialRequestLocalServiceBaseImpl
030     * @see com.liferay.portlet.social.service.impl.SocialRequestLocalServiceImpl
031     * @generated
032     */
033    public class SocialRequestLocalServiceUtil {
034            /*
035             * NOTE FOR DEVELOPERS:
036             *
037             * Never modify this class directly. Add custom service methods to {@link com.liferay.portlet.social.service.impl.SocialRequestLocalServiceImpl} and rerun ServiceBuilder to regenerate this class.
038             */
039    
040            /**
041            * Adds the social request to the database. Also notifies the appropriate model listeners.
042            *
043            * @param socialRequest the social request
044            * @return the social request that was added
045            * @throws SystemException if a system exception occurred
046            */
047            public static com.liferay.portlet.social.model.SocialRequest addSocialRequest(
048                    com.liferay.portlet.social.model.SocialRequest socialRequest)
049                    throws com.liferay.portal.kernel.exception.SystemException {
050                    return getService().addSocialRequest(socialRequest);
051            }
052    
053            /**
054            * Creates a new social request with the primary key. Does not add the social request to the database.
055            *
056            * @param requestId the primary key for the new social request
057            * @return the new social request
058            */
059            public static com.liferay.portlet.social.model.SocialRequest createSocialRequest(
060                    long requestId) {
061                    return getService().createSocialRequest(requestId);
062            }
063    
064            /**
065            * Deletes the social request with the primary key from the database. Also notifies the appropriate model listeners.
066            *
067            * @param requestId the primary key of the social request
068            * @return the social request that was removed
069            * @throws PortalException if a social request with the primary key could not be found
070            * @throws SystemException if a system exception occurred
071            */
072            public static com.liferay.portlet.social.model.SocialRequest deleteSocialRequest(
073                    long requestId)
074                    throws com.liferay.portal.kernel.exception.PortalException,
075                            com.liferay.portal.kernel.exception.SystemException {
076                    return getService().deleteSocialRequest(requestId);
077            }
078    
079            /**
080            * Deletes the social request from the database. Also notifies the appropriate model listeners.
081            *
082            * @param socialRequest the social request
083            * @return the social request that was removed
084            * @throws SystemException if a system exception occurred
085            */
086            public static com.liferay.portlet.social.model.SocialRequest deleteSocialRequest(
087                    com.liferay.portlet.social.model.SocialRequest socialRequest)
088                    throws com.liferay.portal.kernel.exception.SystemException {
089                    return getService().deleteSocialRequest(socialRequest);
090            }
091    
092            public static com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery() {
093                    return getService().dynamicQuery();
094            }
095    
096            /**
097            * Performs a dynamic query on the database and returns the matching rows.
098            *
099            * @param dynamicQuery the dynamic query
100            * @return the matching rows
101            * @throws SystemException if a system exception occurred
102            */
103            @SuppressWarnings("rawtypes")
104            public static java.util.List dynamicQuery(
105                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
106                    throws com.liferay.portal.kernel.exception.SystemException {
107                    return getService().dynamicQuery(dynamicQuery);
108            }
109    
110            /**
111            * Performs a dynamic query on the database and returns a range of the matching rows.
112            *
113            * <p>
114            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.social.model.impl.SocialRequestModelImpl}. 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.
115            * </p>
116            *
117            * @param dynamicQuery the dynamic query
118            * @param start the lower bound of the range of model instances
119            * @param end the upper bound of the range of model instances (not inclusive)
120            * @return the range of matching rows
121            * @throws SystemException if a system exception occurred
122            */
123            @SuppressWarnings("rawtypes")
124            public static java.util.List dynamicQuery(
125                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
126                    int end) throws com.liferay.portal.kernel.exception.SystemException {
127                    return getService().dynamicQuery(dynamicQuery, start, end);
128            }
129    
130            /**
131            * Performs a dynamic query on the database and returns an ordered range of the matching rows.
132            *
133            * <p>
134            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.social.model.impl.SocialRequestModelImpl}. 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.
135            * </p>
136            *
137            * @param dynamicQuery the dynamic query
138            * @param start the lower bound of the range of model instances
139            * @param end the upper bound of the range of model instances (not inclusive)
140            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
141            * @return the ordered range of matching rows
142            * @throws SystemException if a system exception occurred
143            */
144            @SuppressWarnings("rawtypes")
145            public static java.util.List dynamicQuery(
146                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
147                    int end,
148                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
149                    throws com.liferay.portal.kernel.exception.SystemException {
150                    return getService()
151                                       .dynamicQuery(dynamicQuery, start, end, orderByComparator);
152            }
153    
154            /**
155            * Returns the number of rows that match the dynamic query.
156            *
157            * @param dynamicQuery the dynamic query
158            * @return the number of rows that match the dynamic query
159            * @throws SystemException if a system exception occurred
160            */
161            public static long dynamicQueryCount(
162                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
163                    throws com.liferay.portal.kernel.exception.SystemException {
164                    return getService().dynamicQueryCount(dynamicQuery);
165            }
166    
167            public static com.liferay.portlet.social.model.SocialRequest fetchSocialRequest(
168                    long requestId)
169                    throws com.liferay.portal.kernel.exception.SystemException {
170                    return getService().fetchSocialRequest(requestId);
171            }
172    
173            /**
174            * Returns the social request with the primary key.
175            *
176            * @param requestId the primary key of the social request
177            * @return the social request
178            * @throws PortalException if a social request with the primary key could not be found
179            * @throws SystemException if a system exception occurred
180            */
181            public static com.liferay.portlet.social.model.SocialRequest getSocialRequest(
182                    long requestId)
183                    throws com.liferay.portal.kernel.exception.PortalException,
184                            com.liferay.portal.kernel.exception.SystemException {
185                    return getService().getSocialRequest(requestId);
186            }
187    
188            public static com.liferay.portal.model.PersistedModel getPersistedModel(
189                    java.io.Serializable primaryKeyObj)
190                    throws com.liferay.portal.kernel.exception.PortalException,
191                            com.liferay.portal.kernel.exception.SystemException {
192                    return getService().getPersistedModel(primaryKeyObj);
193            }
194    
195            /**
196            * Returns the social request with the UUID in the group.
197            *
198            * @param uuid the UUID of social request
199            * @param groupId the group id of the social request
200            * @return the social request
201            * @throws PortalException if a social request with the UUID in the group could not be found
202            * @throws SystemException if a system exception occurred
203            */
204            public static com.liferay.portlet.social.model.SocialRequest getSocialRequestByUuidAndGroupId(
205                    java.lang.String uuid, long groupId)
206                    throws com.liferay.portal.kernel.exception.PortalException,
207                            com.liferay.portal.kernel.exception.SystemException {
208                    return getService().getSocialRequestByUuidAndGroupId(uuid, groupId);
209            }
210    
211            /**
212            * Returns a range of all the social requests.
213            *
214            * <p>
215            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.social.model.impl.SocialRequestModelImpl}. 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.
216            * </p>
217            *
218            * @param start the lower bound of the range of social requests
219            * @param end the upper bound of the range of social requests (not inclusive)
220            * @return the range of social requests
221            * @throws SystemException if a system exception occurred
222            */
223            public static java.util.List<com.liferay.portlet.social.model.SocialRequest> getSocialRequests(
224                    int start, int end)
225                    throws com.liferay.portal.kernel.exception.SystemException {
226                    return getService().getSocialRequests(start, end);
227            }
228    
229            /**
230            * Returns the number of social requests.
231            *
232            * @return the number of social requests
233            * @throws SystemException if a system exception occurred
234            */
235            public static int getSocialRequestsCount()
236                    throws com.liferay.portal.kernel.exception.SystemException {
237                    return getService().getSocialRequestsCount();
238            }
239    
240            /**
241            * Updates the social request in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
242            *
243            * @param socialRequest the social request
244            * @return the social request that was updated
245            * @throws SystemException if a system exception occurred
246            */
247            public static com.liferay.portlet.social.model.SocialRequest updateSocialRequest(
248                    com.liferay.portlet.social.model.SocialRequest socialRequest)
249                    throws com.liferay.portal.kernel.exception.SystemException {
250                    return getService().updateSocialRequest(socialRequest);
251            }
252    
253            /**
254            * Returns the Spring bean ID for this bean.
255            *
256            * @return the Spring bean ID for this bean
257            */
258            public static java.lang.String getBeanIdentifier() {
259                    return getService().getBeanIdentifier();
260            }
261    
262            /**
263            * Sets the Spring bean ID for this bean.
264            *
265            * @param beanIdentifier the Spring bean ID for this bean
266            */
267            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
268                    getService().setBeanIdentifier(beanIdentifier);
269            }
270    
271            /**
272            * Adds a social request to the database.
273            *
274            * <p>
275            * In order to add a social request, both the requesting user and the
276            * receiving user must be from the same company and neither of them can be
277            * the default user.
278            * </p>
279            *
280            * @param userId the primary key of the requesting user
281            * @param groupId the primary key of the group
282            * @param className the class name of the asset that is the subject of the
283            request
284            * @param classPK the primary key of the asset that is the subject of the
285            request
286            * @param type the request's type
287            * @param extraData the extra data regarding the request
288            * @param receiverUserId the primary key of the user receiving the request
289            * @return the social request
290            * @throws PortalException if the users could not be found, if the users
291            were not from the same company, or if either of the users was the
292            default user
293            * @throws SystemException if a system exception occurred
294            */
295            public static com.liferay.portlet.social.model.SocialRequest addRequest(
296                    long userId, long groupId, java.lang.String className, long classPK,
297                    int type, java.lang.String extraData, long receiverUserId)
298                    throws com.liferay.portal.kernel.exception.PortalException,
299                            com.liferay.portal.kernel.exception.SystemException {
300                    return getService()
301                                       .addRequest(userId, groupId, className, classPK, type,
302                            extraData, receiverUserId);
303            }
304    
305            /**
306            * Removes all the social requests for the receiving user.
307            *
308            * @param receiverUserId the primary key of the receiving user
309            * @throws SystemException if a system exception occurred
310            */
311            public static void deleteReceiverUserRequests(long receiverUserId)
312                    throws com.liferay.portal.kernel.exception.SystemException {
313                    getService().deleteReceiverUserRequests(receiverUserId);
314            }
315    
316            /**
317            * Removes the social request identified by its primary key from the
318            * database.
319            *
320            * @param requestId the primary key of the social request
321            * @throws PortalException if the social request could not be found
322            * @throws SystemException if a system exception occurred
323            */
324            public static void deleteRequest(long requestId)
325                    throws com.liferay.portal.kernel.exception.PortalException,
326                            com.liferay.portal.kernel.exception.SystemException {
327                    getService().deleteRequest(requestId);
328            }
329    
330            /**
331            * Removes the social request from the database.
332            *
333            * @param request the social request to be removed
334            * @throws SystemException if a system exception occurred
335            */
336            public static void deleteRequest(
337                    com.liferay.portlet.social.model.SocialRequest request)
338                    throws com.liferay.portal.kernel.exception.SystemException {
339                    getService().deleteRequest(request);
340            }
341    
342            /**
343            * Removes all the social requests for the requesting user.
344            *
345            * @param userId the primary key of the requesting user
346            * @throws SystemException if a system exception occurred
347            */
348            public static void deleteUserRequests(long userId)
349                    throws com.liferay.portal.kernel.exception.SystemException {
350                    getService().deleteUserRequests(userId);
351            }
352    
353            /**
354            * Returns a range of all the social requests for the receiving user.
355            *
356            * <p>
357            * Useful when paginating results. Returns a maximum of <code>end -
358            * start</code> instances. <code>start</code> and <code>end</code> are not
359            * primary keys, they are indexes in the result set. Thus, <code>0</code>
360            * refers to the first result in the set. Setting both <code>start</code>
361            * and <code>end</code> to {@link
362            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
363            * result set.
364            * </p>
365            *
366            * @param receiverUserId the primary key of the receiving user
367            * @param start the lower bound of the range of results
368            * @param end the upper bound of the range of results (not inclusive)
369            * @return the range of matching social requests
370            * @throws SystemException if a system exception occurred
371            */
372            public static java.util.List<com.liferay.portlet.social.model.SocialRequest> getReceiverUserRequests(
373                    long receiverUserId, int start, int end)
374                    throws com.liferay.portal.kernel.exception.SystemException {
375                    return getService().getReceiverUserRequests(receiverUserId, start, end);
376            }
377    
378            /**
379            * Returns a range of all the social requests with the given status for the
380            * receiving user.
381            *
382            * <p>
383            * Useful when paginating results. Returns a maximum of <code>end -
384            * start</code> instances. <code>start</code> and <code>end</code> are not
385            * primary keys, they are indexes in the result set. Thus, <code>0</code>
386            * refers to the first result in the set. Setting both <code>start</code>
387            * and <code>end</code> to {@link
388            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
389            * result set.
390            * </p>
391            *
392            * @param receiverUserId the primary key of the receiving user
393            * @param status the social request's status
394            * @param start the lower bound of the range of results
395            * @param end the upper bound of the range of results (not inclusive)
396            * @return the range of matching social requests
397            * @throws SystemException if a system exception occurred
398            */
399            public static java.util.List<com.liferay.portlet.social.model.SocialRequest> getReceiverUserRequests(
400                    long receiverUserId, int status, int start, int end)
401                    throws com.liferay.portal.kernel.exception.SystemException {
402                    return getService()
403                                       .getReceiverUserRequests(receiverUserId, status, start, end);
404            }
405    
406            /**
407            * Returns the number of social requests for the receiving user.
408            *
409            * @param receiverUserId the primary key of the receiving user
410            * @return the number of matching social requests
411            * @throws SystemException if a system exception occurred
412            */
413            public static int getReceiverUserRequestsCount(long receiverUserId)
414                    throws com.liferay.portal.kernel.exception.SystemException {
415                    return getService().getReceiverUserRequestsCount(receiverUserId);
416            }
417    
418            /**
419            * Returns the number of social requests with the given status for the
420            * receiving user.
421            *
422            * @param receiverUserId the primary key of the receiving user
423            * @param status the social request's status
424            * @return the number of matching social requests
425            * @throws SystemException if a system exception occurred
426            */
427            public static int getReceiverUserRequestsCount(long receiverUserId,
428                    int status) throws com.liferay.portal.kernel.exception.SystemException {
429                    return getService().getReceiverUserRequestsCount(receiverUserId, status);
430            }
431    
432            /**
433            * Returns a range of all the social requests for the requesting user.
434            *
435            * <p>
436            * Useful when paginating results. Returns a maximum of <code>end -
437            * start</code> instances. <code>start</code> and <code>end</code> are not
438            * primary keys, they are indexes in the result set. Thus, <code>0</code>
439            * refers to the first result in the set. Setting both <code>start</code>
440            * and <code>end</code> to {@link
441            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
442            * result set.
443            * </p>
444            *
445            * @param userId the primary key of the requesting user
446            * @param start the lower bound of the range of results
447            * @param end the upper bound of the range of results (not inclusive)
448            * @return the range of matching social requests
449            * @throws SystemException if a system exception occurred
450            */
451            public static java.util.List<com.liferay.portlet.social.model.SocialRequest> getUserRequests(
452                    long userId, int start, int end)
453                    throws com.liferay.portal.kernel.exception.SystemException {
454                    return getService().getUserRequests(userId, start, end);
455            }
456    
457            /**
458            * Returns a range of all the social requests with the given status for the
459            * requesting user.
460            *
461            * <p>
462            * Useful when paginating results. Returns a maximum of <code>end -
463            * start</code> instances. <code>start</code> and <code>end</code> are not
464            * primary keys, they are indexes in the result set. Thus, <code>0</code>
465            * refers to the first result in the set. Setting both <code>start</code>
466            * and <code>end</code> to {@link
467            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
468            * result set.
469            * </p>
470            *
471            * @param userId the primary key of the requesting user
472            * @param status the social request's status
473            * @param start the lower bound of the range of results
474            * @param end the upper bound of the range of results (not inclusive)
475            * @return the range of matching social requests
476            * @throws SystemException if a system exception occurred
477            */
478            public static java.util.List<com.liferay.portlet.social.model.SocialRequest> getUserRequests(
479                    long userId, int status, int start, int end)
480                    throws com.liferay.portal.kernel.exception.SystemException {
481                    return getService().getUserRequests(userId, status, start, end);
482            }
483    
484            /**
485            * Returns the number of social requests for the requesting user.
486            *
487            * @param userId the primary key of the requesting user
488            * @return the number of matching social requests
489            * @throws SystemException if a system exception occurred
490            */
491            public static int getUserRequestsCount(long userId)
492                    throws com.liferay.portal.kernel.exception.SystemException {
493                    return getService().getUserRequestsCount(userId);
494            }
495    
496            /**
497            * Returns the number of social requests with the given status for the
498            * requesting user.
499            *
500            * @param userId the primary key of the requesting user
501            * @param status the social request's status
502            * @return the number of matching social request
503            * @throws SystemException if a system exception occurred
504            */
505            public static int getUserRequestsCount(long userId, int status)
506                    throws com.liferay.portal.kernel.exception.SystemException {
507                    return getService().getUserRequestsCount(userId, status);
508            }
509    
510            /**
511            * Returns <code>true</code> if a matching social requests exists in the
512            * database.
513            *
514            * @param userId the primary key of the requesting user
515            * @param className the class name of the asset that is the subject of the
516            request
517            * @param classPK the primary key of the asset that is the subject of the
518            request
519            * @param type the request's type
520            * @param status the social request's status
521            * @return <code>true</code> if the request exists; <code>false</code>
522            otherwise
523            * @throws SystemException if a system exception occurred
524            */
525            public static boolean hasRequest(long userId, java.lang.String className,
526                    long classPK, int type, int status)
527                    throws com.liferay.portal.kernel.exception.SystemException {
528                    return getService().hasRequest(userId, className, classPK, type, status);
529            }
530    
531            /**
532            * Returns <code>true</code> if a matching social request exists in the
533            * database.
534            *
535            * @param userId the primary key of the requesting user
536            * @param className the class name of the asset that is the subject of the
537            request
538            * @param classPK the primary key of the asset that is the subject of the
539            request
540            * @param type the request's type
541            * @param receiverUserId the primary key of the receiving user
542            * @param status the social request's status
543            * @return <code>true</code> if the social request exists;
544            <code>false</code> otherwise
545            * @throws SystemException if a system exception occurred
546            */
547            public static boolean hasRequest(long userId, java.lang.String className,
548                    long classPK, int type, long receiverUserId, int status)
549                    throws com.liferay.portal.kernel.exception.SystemException {
550                    return getService()
551                                       .hasRequest(userId, className, classPK, type,
552                            receiverUserId, status);
553            }
554    
555            /**
556            * Updates the social request replacing its status.
557            *
558            * <p>
559            * If the status is updated to {@link
560            * com.liferay.portlet.social.model.SocialRequestConstants#STATUS_CONFIRM}
561            * then {@link
562            * com.liferay.portlet.social.service.SocialRequestInterpreterLocalService#processConfirmation(
563            * SocialRequest, ThemeDisplay)} is called. If the status is updated to
564            * {@link
565            * com.liferay.portlet.social.model.SocialRequestConstants#STATUS_IGNORE}
566            * then {@link
567            * com.liferay.portlet.social.service.SocialRequestInterpreterLocalService#processRejection(
568            * SocialRequest, ThemeDisplay)} is called.
569            * </p>
570            *
571            * @param requestId the primary key of the social request
572            * @param status the new status
573            * @param themeDisplay the theme display
574            * @return the updated social request
575            * @throws PortalException if the social request could not be found
576            * @throws SystemException if a system exception occurred
577            */
578            public static com.liferay.portlet.social.model.SocialRequest updateRequest(
579                    long requestId, int status,
580                    com.liferay.portal.theme.ThemeDisplay themeDisplay)
581                    throws com.liferay.portal.kernel.exception.PortalException,
582                            com.liferay.portal.kernel.exception.SystemException {
583                    return getService().updateRequest(requestId, status, themeDisplay);
584            }
585    
586            public static SocialRequestLocalService getService() {
587                    if (_service == null) {
588                            _service = (SocialRequestLocalService)PortalBeanLocatorUtil.locate(SocialRequestLocalService.class.getName());
589    
590                            ReferenceRegistry.registerReference(SocialRequestLocalServiceUtil.class,
591                                    "_service");
592                    }
593    
594                    return _service;
595            }
596    
597            /**
598             * @deprecated
599             */
600            public void setService(SocialRequestLocalService service) {
601            }
602    
603            private static SocialRequestLocalService _service;
604    }