001    /**
002     * Copyright (c) 2000-2011 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.portal.service;
016    
017    /**
018     * <p>
019     * This class is a wrapper for {@link LockLocalService}.
020     * </p>
021     *
022     * @author    Brian Wing Shun Chan
023     * @see       LockLocalService
024     * @generated
025     */
026    public class LockLocalServiceWrapper implements LockLocalService {
027            public LockLocalServiceWrapper(LockLocalService lockLocalService) {
028                    _lockLocalService = lockLocalService;
029            }
030    
031            /**
032            * Adds the lock to the database. Also notifies the appropriate model listeners.
033            *
034            * @param lock the lock
035            * @return the lock that was added
036            * @throws SystemException if a system exception occurred
037            */
038            public com.liferay.portal.model.Lock addLock(
039                    com.liferay.portal.model.Lock lock)
040                    throws com.liferay.portal.kernel.exception.SystemException {
041                    return _lockLocalService.addLock(lock);
042            }
043    
044            /**
045            * Creates a new lock with the primary key. Does not add the lock to the database.
046            *
047            * @param lockId the primary key for the new lock
048            * @return the new lock
049            */
050            public com.liferay.portal.model.Lock createLock(long lockId) {
051                    return _lockLocalService.createLock(lockId);
052            }
053    
054            /**
055            * Deletes the lock with the primary key from the database. Also notifies the appropriate model listeners.
056            *
057            * @param lockId the primary key of the lock
058            * @throws PortalException if a lock with the primary key could not be found
059            * @throws SystemException if a system exception occurred
060            */
061            public void deleteLock(long lockId)
062                    throws com.liferay.portal.kernel.exception.PortalException,
063                            com.liferay.portal.kernel.exception.SystemException {
064                    _lockLocalService.deleteLock(lockId);
065            }
066    
067            /**
068            * Deletes the lock from the database. Also notifies the appropriate model listeners.
069            *
070            * @param lock the lock
071            * @throws SystemException if a system exception occurred
072            */
073            public void deleteLock(com.liferay.portal.model.Lock lock)
074                    throws com.liferay.portal.kernel.exception.SystemException {
075                    _lockLocalService.deleteLock(lock);
076            }
077    
078            /**
079            * Performs a dynamic query on the database and returns the matching rows.
080            *
081            * @param dynamicQuery the dynamic query
082            * @return the matching rows
083            * @throws SystemException if a system exception occurred
084            */
085            @SuppressWarnings("rawtypes")
086            public java.util.List dynamicQuery(
087                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
088                    throws com.liferay.portal.kernel.exception.SystemException {
089                    return _lockLocalService.dynamicQuery(dynamicQuery);
090            }
091    
092            /**
093            * Performs a dynamic query on the database and returns a range of the matching rows.
094            *
095            * <p>
096            * 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.
097            * </p>
098            *
099            * @param dynamicQuery the dynamic query
100            * @param start the lower bound of the range of model instances
101            * @param end the upper bound of the range of model instances (not inclusive)
102            * @return the range of matching rows
103            * @throws SystemException if a system exception occurred
104            */
105            @SuppressWarnings("rawtypes")
106            public java.util.List dynamicQuery(
107                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
108                    int end) throws com.liferay.portal.kernel.exception.SystemException {
109                    return _lockLocalService.dynamicQuery(dynamicQuery, start, end);
110            }
111    
112            /**
113            * Performs a dynamic query on the database and returns an ordered range of the matching rows.
114            *
115            * <p>
116            * 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.
117            * </p>
118            *
119            * @param dynamicQuery the dynamic query
120            * @param start the lower bound of the range of model instances
121            * @param end the upper bound of the range of model instances (not inclusive)
122            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
123            * @return the ordered range of matching rows
124            * @throws SystemException if a system exception occurred
125            */
126            @SuppressWarnings("rawtypes")
127            public java.util.List dynamicQuery(
128                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
129                    int end,
130                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
131                    throws com.liferay.portal.kernel.exception.SystemException {
132                    return _lockLocalService.dynamicQuery(dynamicQuery, start, end,
133                            orderByComparator);
134            }
135    
136            /**
137            * Returns the number of rows that match the dynamic query.
138            *
139            * @param dynamicQuery the dynamic query
140            * @return the number of rows that match the dynamic query
141            * @throws SystemException if a system exception occurred
142            */
143            public long dynamicQueryCount(
144                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
145                    throws com.liferay.portal.kernel.exception.SystemException {
146                    return _lockLocalService.dynamicQueryCount(dynamicQuery);
147            }
148    
149            /**
150            * Returns the lock with the primary key.
151            *
152            * @param lockId the primary key of the lock
153            * @return the lock
154            * @throws PortalException if a lock with the primary key could not be found
155            * @throws SystemException if a system exception occurred
156            */
157            public com.liferay.portal.model.Lock getLock(long lockId)
158                    throws com.liferay.portal.kernel.exception.PortalException,
159                            com.liferay.portal.kernel.exception.SystemException {
160                    return _lockLocalService.getLock(lockId);
161            }
162    
163            public com.liferay.portal.model.PersistedModel getPersistedModel(
164                    java.io.Serializable primaryKeyObj)
165                    throws com.liferay.portal.kernel.exception.PortalException,
166                            com.liferay.portal.kernel.exception.SystemException {
167                    return _lockLocalService.getPersistedModel(primaryKeyObj);
168            }
169    
170            /**
171            * Returns a range of all the locks.
172            *
173            * <p>
174            * 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.
175            * </p>
176            *
177            * @param start the lower bound of the range of locks
178            * @param end the upper bound of the range of locks (not inclusive)
179            * @return the range of locks
180            * @throws SystemException if a system exception occurred
181            */
182            public java.util.List<com.liferay.portal.model.Lock> getLocks(int start,
183                    int end) throws com.liferay.portal.kernel.exception.SystemException {
184                    return _lockLocalService.getLocks(start, end);
185            }
186    
187            /**
188            * Returns the number of locks.
189            *
190            * @return the number of locks
191            * @throws SystemException if a system exception occurred
192            */
193            public int getLocksCount()
194                    throws com.liferay.portal.kernel.exception.SystemException {
195                    return _lockLocalService.getLocksCount();
196            }
197    
198            /**
199            * Updates the lock in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
200            *
201            * @param lock the lock
202            * @return the lock that was updated
203            * @throws SystemException if a system exception occurred
204            */
205            public com.liferay.portal.model.Lock updateLock(
206                    com.liferay.portal.model.Lock lock)
207                    throws com.liferay.portal.kernel.exception.SystemException {
208                    return _lockLocalService.updateLock(lock);
209            }
210    
211            /**
212            * Updates the lock in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
213            *
214            * @param lock the lock
215            * @param merge whether to merge the lock 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.
216            * @return the lock that was updated
217            * @throws SystemException if a system exception occurred
218            */
219            public com.liferay.portal.model.Lock updateLock(
220                    com.liferay.portal.model.Lock lock, boolean merge)
221                    throws com.liferay.portal.kernel.exception.SystemException {
222                    return _lockLocalService.updateLock(lock, merge);
223            }
224    
225            /**
226            * Returns the Spring bean ID for this bean.
227            *
228            * @return the Spring bean ID for this bean
229            */
230            public java.lang.String getBeanIdentifier() {
231                    return _lockLocalService.getBeanIdentifier();
232            }
233    
234            /**
235            * Sets the Spring bean ID for this bean.
236            *
237            * @param beanIdentifier the Spring bean ID for this bean
238            */
239            public void setBeanIdentifier(java.lang.String beanIdentifier) {
240                    _lockLocalService.setBeanIdentifier(beanIdentifier);
241            }
242    
243            public void clear()
244                    throws com.liferay.portal.kernel.exception.SystemException {
245                    _lockLocalService.clear();
246            }
247    
248            public com.liferay.portal.model.Lock getLock(java.lang.String className,
249                    long key)
250                    throws com.liferay.portal.kernel.exception.PortalException,
251                            com.liferay.portal.kernel.exception.SystemException {
252                    return _lockLocalService.getLock(className, key);
253            }
254    
255            public com.liferay.portal.model.Lock getLock(java.lang.String className,
256                    java.lang.String key)
257                    throws com.liferay.portal.kernel.exception.PortalException,
258                            com.liferay.portal.kernel.exception.SystemException {
259                    return _lockLocalService.getLock(className, key);
260            }
261    
262            public com.liferay.portal.model.Lock getLockByUuid(java.lang.String uuid)
263                    throws com.liferay.portal.kernel.exception.PortalException,
264                            com.liferay.portal.kernel.exception.SystemException {
265                    return _lockLocalService.getLockByUuid(uuid);
266            }
267    
268            public boolean hasLock(long userId, java.lang.String className, long key)
269                    throws com.liferay.portal.kernel.exception.SystemException {
270                    return _lockLocalService.hasLock(userId, className, key);
271            }
272    
273            public boolean hasLock(long userId, java.lang.String className,
274                    java.lang.String key)
275                    throws com.liferay.portal.kernel.exception.SystemException {
276                    return _lockLocalService.hasLock(userId, className, key);
277            }
278    
279            public boolean isLocked(java.lang.String className, long key)
280                    throws com.liferay.portal.kernel.exception.SystemException {
281                    return _lockLocalService.isLocked(className, key);
282            }
283    
284            public boolean isLocked(java.lang.String className, java.lang.String key)
285                    throws com.liferay.portal.kernel.exception.SystemException {
286                    return _lockLocalService.isLocked(className, key);
287            }
288    
289            public com.liferay.portal.model.Lock lock(long userId,
290                    java.lang.String className, long key, java.lang.String owner,
291                    boolean inheritable, long expirationTime)
292                    throws com.liferay.portal.kernel.exception.PortalException,
293                            com.liferay.portal.kernel.exception.SystemException {
294                    return _lockLocalService.lock(userId, className, key, owner,
295                            inheritable, expirationTime);
296            }
297    
298            public com.liferay.portal.model.Lock lock(long userId,
299                    java.lang.String className, java.lang.String key,
300                    java.lang.String owner, boolean inheritable, long expirationTime)
301                    throws com.liferay.portal.kernel.exception.PortalException,
302                            com.liferay.portal.kernel.exception.SystemException {
303                    return _lockLocalService.lock(userId, className, key, owner,
304                            inheritable, expirationTime);
305            }
306    
307            public com.liferay.portal.model.Lock lock(java.lang.String className,
308                    java.lang.String key, java.lang.String owner, boolean retrieveFromCache)
309                    throws com.liferay.portal.kernel.exception.SystemException {
310                    return _lockLocalService.lock(className, key, owner, retrieveFromCache);
311            }
312    
313            public com.liferay.portal.model.Lock lock(java.lang.String className,
314                    java.lang.String key, java.lang.String expectedOwner,
315                    java.lang.String updatedOwner, boolean retrieveFromCache)
316                    throws com.liferay.portal.kernel.exception.SystemException {
317                    return _lockLocalService.lock(className, key, expectedOwner,
318                            updatedOwner, retrieveFromCache);
319            }
320    
321            public com.liferay.portal.model.Lock refresh(java.lang.String uuid,
322                    long expirationTime)
323                    throws com.liferay.portal.kernel.exception.PortalException,
324                            com.liferay.portal.kernel.exception.SystemException {
325                    return _lockLocalService.refresh(uuid, expirationTime);
326            }
327    
328            public void unlock(java.lang.String className, long key)
329                    throws com.liferay.portal.kernel.exception.SystemException {
330                    _lockLocalService.unlock(className, key);
331            }
332    
333            public void unlock(java.lang.String className, java.lang.String key)
334                    throws com.liferay.portal.kernel.exception.SystemException {
335                    _lockLocalService.unlock(className, key);
336            }
337    
338            public void unlock(java.lang.String className, java.lang.String key,
339                    java.lang.String owner, boolean retrieveFromCache)
340                    throws com.liferay.portal.kernel.exception.SystemException {
341                    _lockLocalService.unlock(className, key, owner, retrieveFromCache);
342            }
343    
344            public LockLocalService getWrappedLockLocalService() {
345                    return _lockLocalService;
346            }
347    
348            public void setWrappedLockLocalService(LockLocalService lockLocalService) {
349                    _lockLocalService = lockLocalService;
350            }
351    
352            private LockLocalService _lockLocalService;
353    }