001    /**
002     * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portal.service;
016    
017    /**
018     * <p>
019     * This class is a wrapper for {@link ResourceLocalService}.
020     * </p>
021     *
022     * @author    Brian Wing Shun Chan
023     * @see       ResourceLocalService
024     * @generated
025     */
026    public class ResourceLocalServiceWrapper implements ResourceLocalService {
027            public ResourceLocalServiceWrapper(
028                    ResourceLocalService resourceLocalService) {
029                    _resourceLocalService = resourceLocalService;
030            }
031    
032            /**
033            * Adds the resource to the database. Also notifies the appropriate model listeners.
034            *
035            * @param resource the resource
036            * @return the resource that was added
037            * @throws SystemException if a system exception occurred
038            */
039            public com.liferay.portal.model.Resource addResource(
040                    com.liferay.portal.model.Resource resource)
041                    throws com.liferay.portal.kernel.exception.SystemException {
042                    return _resourceLocalService.addResource(resource);
043            }
044    
045            /**
046            * Creates a new resource with the primary key. Does not add the resource to the database.
047            *
048            * @param resourceId the primary key for the new resource
049            * @return the new resource
050            */
051            public com.liferay.portal.model.Resource createResource(long resourceId) {
052                    return _resourceLocalService.createResource(resourceId);
053            }
054    
055            /**
056            * Deletes the resource with the primary key from the database. Also notifies the appropriate model listeners.
057            *
058            * @param resourceId the primary key of the resource
059            * @throws PortalException if a resource with the primary key could not be found
060            * @throws SystemException if a system exception occurred
061            */
062            public void deleteResource(long resourceId)
063                    throws com.liferay.portal.kernel.exception.PortalException,
064                            com.liferay.portal.kernel.exception.SystemException {
065                    _resourceLocalService.deleteResource(resourceId);
066            }
067    
068            /**
069            * Deletes the resource from the database. Also notifies the appropriate model listeners.
070            *
071            * @param resource the resource
072            * @throws SystemException if a system exception occurred
073            */
074            public void deleteResource(com.liferay.portal.model.Resource resource)
075                    throws com.liferay.portal.kernel.exception.SystemException {
076                    _resourceLocalService.deleteResource(resource);
077            }
078    
079            /**
080            * Performs a dynamic query on the database and returns the matching rows.
081            *
082            * @param dynamicQuery the dynamic query
083            * @return the matching rows
084            * @throws SystemException if a system exception occurred
085            */
086            @SuppressWarnings("rawtypes")
087            public java.util.List dynamicQuery(
088                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
089                    throws com.liferay.portal.kernel.exception.SystemException {
090                    return _resourceLocalService.dynamicQuery(dynamicQuery);
091            }
092    
093            /**
094            * Performs a dynamic query on the database and returns a range of the matching rows.
095            *
096            * <p>
097            * 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.
098            * </p>
099            *
100            * @param dynamicQuery the dynamic query
101            * @param start the lower bound of the range of model instances
102            * @param end the upper bound of the range of model instances (not inclusive)
103            * @return the range of matching rows
104            * @throws SystemException if a system exception occurred
105            */
106            @SuppressWarnings("rawtypes")
107            public java.util.List dynamicQuery(
108                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
109                    int end) throws com.liferay.portal.kernel.exception.SystemException {
110                    return _resourceLocalService.dynamicQuery(dynamicQuery, start, end);
111            }
112    
113            /**
114            * Performs a dynamic query on the database and returns an ordered range of the matching rows.
115            *
116            * <p>
117            * 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.
118            * </p>
119            *
120            * @param dynamicQuery the dynamic query
121            * @param start the lower bound of the range of model instances
122            * @param end the upper bound of the range of model instances (not inclusive)
123            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
124            * @return the ordered range of matching rows
125            * @throws SystemException if a system exception occurred
126            */
127            @SuppressWarnings("rawtypes")
128            public java.util.List dynamicQuery(
129                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
130                    int end,
131                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
132                    throws com.liferay.portal.kernel.exception.SystemException {
133                    return _resourceLocalService.dynamicQuery(dynamicQuery, start, end,
134                            orderByComparator);
135            }
136    
137            /**
138            * Returns the number of rows that match the dynamic query.
139            *
140            * @param dynamicQuery the dynamic query
141            * @return the number of rows that match the dynamic query
142            * @throws SystemException if a system exception occurred
143            */
144            public long dynamicQueryCount(
145                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
146                    throws com.liferay.portal.kernel.exception.SystemException {
147                    return _resourceLocalService.dynamicQueryCount(dynamicQuery);
148            }
149    
150            /**
151            * Returns the resource with the primary key.
152            *
153            * @param resourceId the primary key of the resource
154            * @return the resource
155            * @throws PortalException if a resource with the primary key could not be found
156            * @throws SystemException if a system exception occurred
157            */
158            public com.liferay.portal.model.Resource getResource(long resourceId)
159                    throws com.liferay.portal.kernel.exception.PortalException,
160                            com.liferay.portal.kernel.exception.SystemException {
161                    return _resourceLocalService.getResource(resourceId);
162            }
163    
164            public com.liferay.portal.model.PersistedModel getPersistedModel(
165                    java.io.Serializable primaryKeyObj)
166                    throws com.liferay.portal.kernel.exception.PortalException,
167                            com.liferay.portal.kernel.exception.SystemException {
168                    return _resourceLocalService.getPersistedModel(primaryKeyObj);
169            }
170    
171            /**
172            * Returns a range of all the resources.
173            *
174            * <p>
175            * 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.
176            * </p>
177            *
178            * @param start the lower bound of the range of resources
179            * @param end the upper bound of the range of resources (not inclusive)
180            * @return the range of resources
181            * @throws SystemException if a system exception occurred
182            */
183            public java.util.List<com.liferay.portal.model.Resource> getResources(
184                    int start, int end)
185                    throws com.liferay.portal.kernel.exception.SystemException {
186                    return _resourceLocalService.getResources(start, end);
187            }
188    
189            /**
190            * Returns the number of resources.
191            *
192            * @return the number of resources
193            * @throws SystemException if a system exception occurred
194            */
195            public int getResourcesCount()
196                    throws com.liferay.portal.kernel.exception.SystemException {
197                    return _resourceLocalService.getResourcesCount();
198            }
199    
200            /**
201            * Updates the resource in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
202            *
203            * @param resource the resource
204            * @return the resource that was updated
205            * @throws SystemException if a system exception occurred
206            */
207            public com.liferay.portal.model.Resource updateResource(
208                    com.liferay.portal.model.Resource resource)
209                    throws com.liferay.portal.kernel.exception.SystemException {
210                    return _resourceLocalService.updateResource(resource);
211            }
212    
213            /**
214            * Updates the resource in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
215            *
216            * @param resource the resource
217            * @param merge whether to merge the resource with the current session. See {@link com.liferay.portal.service.persistence.BatchSession#update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean)} for an explanation.
218            * @return the resource that was updated
219            * @throws SystemException if a system exception occurred
220            */
221            public com.liferay.portal.model.Resource updateResource(
222                    com.liferay.portal.model.Resource resource, boolean merge)
223                    throws com.liferay.portal.kernel.exception.SystemException {
224                    return _resourceLocalService.updateResource(resource, merge);
225            }
226    
227            /**
228            * Returns the Spring bean ID for this bean.
229            *
230            * @return the Spring bean ID for this bean
231            */
232            public java.lang.String getBeanIdentifier() {
233                    return _resourceLocalService.getBeanIdentifier();
234            }
235    
236            /**
237            * Sets the Spring bean ID for this bean.
238            *
239            * @param beanIdentifier the Spring bean ID for this bean
240            */
241            public void setBeanIdentifier(java.lang.String beanIdentifier) {
242                    _resourceLocalService.setBeanIdentifier(beanIdentifier);
243            }
244    
245            public void addModelResources(long companyId, long groupId, long userId,
246                    java.lang.String name, long primKey,
247                    java.lang.String[] communityPermissions,
248                    java.lang.String[] guestPermissions)
249                    throws com.liferay.portal.kernel.exception.PortalException,
250                            com.liferay.portal.kernel.exception.SystemException {
251                    _resourceLocalService.addModelResources(companyId, groupId, userId,
252                            name, primKey, communityPermissions, guestPermissions);
253            }
254    
255            public void addModelResources(long companyId, long groupId, long userId,
256                    java.lang.String name, java.lang.String primKey,
257                    java.lang.String[] communityPermissions,
258                    java.lang.String[] guestPermissions)
259                    throws com.liferay.portal.kernel.exception.PortalException,
260                            com.liferay.portal.kernel.exception.SystemException {
261                    _resourceLocalService.addModelResources(companyId, groupId, userId,
262                            name, primKey, communityPermissions, guestPermissions);
263            }
264    
265            public com.liferay.portal.model.Resource addResource(long companyId,
266                    java.lang.String name, int scope, java.lang.String primKey)
267                    throws com.liferay.portal.kernel.exception.SystemException {
268                    return _resourceLocalService.addResource(companyId, name, scope, primKey);
269            }
270    
271            public void addResources(long companyId, long groupId,
272                    java.lang.String name, boolean portletActions)
273                    throws com.liferay.portal.kernel.exception.PortalException,
274                            com.liferay.portal.kernel.exception.SystemException {
275                    _resourceLocalService.addResources(companyId, groupId, name,
276                            portletActions);
277            }
278    
279            public void addResources(long companyId, long groupId, long userId,
280                    java.lang.String name, long primKey, boolean portletActions,
281                    boolean addCommunityPermissions, boolean addGuestPermissions)
282                    throws com.liferay.portal.kernel.exception.PortalException,
283                            com.liferay.portal.kernel.exception.SystemException {
284                    _resourceLocalService.addResources(companyId, groupId, userId, name,
285                            primKey, portletActions, addCommunityPermissions,
286                            addGuestPermissions);
287            }
288    
289            public void addResources(long companyId, long groupId, long userId,
290                    java.lang.String name, java.lang.String primKey,
291                    boolean portletActions, boolean addCommunityPermissions,
292                    boolean addGuestPermissions)
293                    throws com.liferay.portal.kernel.exception.PortalException,
294                            com.liferay.portal.kernel.exception.SystemException {
295                    _resourceLocalService.addResources(companyId, groupId, userId, name,
296                            primKey, portletActions, addCommunityPermissions,
297                            addGuestPermissions);
298            }
299    
300            public void deleteResource(long companyId, java.lang.String name,
301                    int scope, long primKey)
302                    throws com.liferay.portal.kernel.exception.PortalException,
303                            com.liferay.portal.kernel.exception.SystemException {
304                    _resourceLocalService.deleteResource(companyId, name, scope, primKey);
305            }
306    
307            public void deleteResource(long companyId, java.lang.String name,
308                    int scope, java.lang.String primKey)
309                    throws com.liferay.portal.kernel.exception.PortalException,
310                            com.liferay.portal.kernel.exception.SystemException {
311                    _resourceLocalService.deleteResource(companyId, name, scope, primKey);
312            }
313    
314            public void deleteResources(java.lang.String name)
315                    throws com.liferay.portal.kernel.exception.SystemException {
316                    _resourceLocalService.deleteResources(name);
317            }
318    
319            public long getLatestResourceId()
320                    throws com.liferay.portal.kernel.exception.SystemException {
321                    return _resourceLocalService.getLatestResourceId();
322            }
323    
324            public com.liferay.portal.model.Resource getResource(long companyId,
325                    java.lang.String name, int scope, java.lang.String primKey)
326                    throws com.liferay.portal.kernel.exception.PortalException,
327                            com.liferay.portal.kernel.exception.SystemException {
328                    return _resourceLocalService.getResource(companyId, name, scope, primKey);
329            }
330    
331            public java.util.List<com.liferay.portal.model.Resource> getResources()
332                    throws com.liferay.portal.kernel.exception.SystemException {
333                    return _resourceLocalService.getResources();
334            }
335    
336            public void updateResources(long companyId, java.lang.String name,
337                    int scope, java.lang.String primKey, java.lang.String newPrimKey)
338                    throws com.liferay.portal.kernel.exception.PortalException,
339                            com.liferay.portal.kernel.exception.SystemException {
340                    _resourceLocalService.updateResources(companyId, name, scope, primKey,
341                            newPrimKey);
342            }
343    
344            public void updateResources(long companyId, long groupId,
345                    java.lang.String name, long primKey,
346                    java.lang.String[] communityPermissions,
347                    java.lang.String[] guestPermissions)
348                    throws com.liferay.portal.kernel.exception.PortalException,
349                            com.liferay.portal.kernel.exception.SystemException {
350                    _resourceLocalService.updateResources(companyId, groupId, name,
351                            primKey, communityPermissions, guestPermissions);
352            }
353    
354            public void updateResources(long companyId, long groupId,
355                    java.lang.String name, java.lang.String primKey,
356                    java.lang.String[] communityPermissions,
357                    java.lang.String[] guestPermissions)
358                    throws com.liferay.portal.kernel.exception.PortalException,
359                            com.liferay.portal.kernel.exception.SystemException {
360                    _resourceLocalService.updateResources(companyId, groupId, name,
361                            primKey, communityPermissions, guestPermissions);
362            }
363    
364            public ResourceLocalService getWrappedResourceLocalService() {
365                    return _resourceLocalService;
366            }
367    
368            public void setWrappedResourceLocalService(
369                    ResourceLocalService resourceLocalService) {
370                    _resourceLocalService = resourceLocalService;
371            }
372    
373            private ResourceLocalService _resourceLocalService;
374    }