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.documentlibrary.service.http;
016    
017    import com.liferay.portal.kernel.log.Log;
018    import com.liferay.portal.kernel.log.LogFactoryUtil;
019    import com.liferay.portal.kernel.util.MethodHandler;
020    import com.liferay.portal.kernel.util.MethodKey;
021    import com.liferay.portal.security.auth.HttpPrincipal;
022    import com.liferay.portal.service.http.TunnelUtil;
023    
024    import com.liferay.portlet.documentlibrary.service.DLFileEntryServiceUtil;
025    
026    /**
027     * <p>
028     * This class provides a HTTP utility for the
029     * {@link com.liferay.portlet.documentlibrary.service.DLFileEntryServiceUtil} service utility. The
030     * static methods of this class calls the same methods of the service utility.
031     * However, the signatures are different because it requires an additional
032     * {@link com.liferay.portal.security.auth.HttpPrincipal} parameter.
033     * </p>
034     *
035     * <p>
036     * The benefits of using the HTTP utility is that it is fast and allows for
037     * tunneling without the cost of serializing to text. The drawback is that it
038     * only works with Java.
039     * </p>
040     *
041     * <p>
042     * Set the property <b>tunnel.servlet.hosts.allowed</b> in portal.properties to
043     * configure security.
044     * </p>
045     *
046     * <p>
047     * The HTTP utility is only generated for remote services.
048     * </p>
049     *
050     * @author    Brian Wing Shun Chan
051     * @see       DLFileEntryServiceSoap
052     * @see       com.liferay.portal.security.auth.HttpPrincipal
053     * @see       com.liferay.portlet.documentlibrary.service.DLFileEntryServiceUtil
054     * @generated
055     */
056    public class DLFileEntryServiceHttp {
057            public static com.liferay.portlet.documentlibrary.model.DLFileEntry addFileEntry(
058                    HttpPrincipal httpPrincipal, long groupId, long repositoryId,
059                    long folderId, java.lang.String sourceFileName,
060                    java.lang.String mimeType, java.lang.String title,
061                    java.lang.String description, java.lang.String changeLog,
062                    long fileEntryTypeId,
063                    java.util.Map<java.lang.String, com.liferay.portlet.dynamicdatamapping.storage.Fields> fieldsMap,
064                    java.io.File file, java.io.InputStream is, long size,
065                    com.liferay.portal.service.ServiceContext serviceContext)
066                    throws com.liferay.portal.kernel.exception.PortalException,
067                            com.liferay.portal.kernel.exception.SystemException {
068                    try {
069                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
070                                            "addFileEntry", _addFileEntryParameterTypes0);
071    
072                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
073                                            repositoryId, folderId, sourceFileName, mimeType, title,
074                                            description, changeLog, fileEntryTypeId, fieldsMap, file,
075                                            is, size, serviceContext);
076    
077                            Object returnObj = null;
078    
079                            try {
080                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
081                            }
082                            catch (Exception e) {
083                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
084                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
085                                    }
086    
087                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
088                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
089                                    }
090    
091                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
092                            }
093    
094                            return (com.liferay.portlet.documentlibrary.model.DLFileEntry)returnObj;
095                    }
096                    catch (com.liferay.portal.kernel.exception.SystemException se) {
097                            _log.error(se, se);
098    
099                            throw se;
100                    }
101            }
102    
103            public static void cancelCheckOut(HttpPrincipal httpPrincipal,
104                    long fileEntryId)
105                    throws com.liferay.portal.kernel.exception.PortalException,
106                            com.liferay.portal.kernel.exception.SystemException {
107                    try {
108                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
109                                            "cancelCheckOut", _cancelCheckOutParameterTypes1);
110    
111                            MethodHandler methodHandler = new MethodHandler(methodKey,
112                                            fileEntryId);
113    
114                            try {
115                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
116                            }
117                            catch (Exception e) {
118                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
119                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
120                                    }
121    
122                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
123                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
124                                    }
125    
126                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
127                            }
128                    }
129                    catch (com.liferay.portal.kernel.exception.SystemException se) {
130                            _log.error(se, se);
131    
132                            throw se;
133                    }
134            }
135    
136            public static void checkInFileEntry(HttpPrincipal httpPrincipal,
137                    long fileEntryId, boolean major, java.lang.String changeLog,
138                    com.liferay.portal.service.ServiceContext serviceContext)
139                    throws com.liferay.portal.kernel.exception.PortalException,
140                            com.liferay.portal.kernel.exception.SystemException {
141                    try {
142                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
143                                            "checkInFileEntry", _checkInFileEntryParameterTypes2);
144    
145                            MethodHandler methodHandler = new MethodHandler(methodKey,
146                                            fileEntryId, major, changeLog, serviceContext);
147    
148                            try {
149                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
150                            }
151                            catch (Exception e) {
152                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
153                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
154                                    }
155    
156                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
157                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
158                                    }
159    
160                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
161                            }
162                    }
163                    catch (com.liferay.portal.kernel.exception.SystemException se) {
164                            _log.error(se, se);
165    
166                            throw se;
167                    }
168            }
169    
170            public static void checkInFileEntry(HttpPrincipal httpPrincipal,
171                    long fileEntryId, java.lang.String lockUuid)
172                    throws com.liferay.portal.kernel.exception.PortalException,
173                            com.liferay.portal.kernel.exception.SystemException {
174                    try {
175                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
176                                            "checkInFileEntry", _checkInFileEntryParameterTypes3);
177    
178                            MethodHandler methodHandler = new MethodHandler(methodKey,
179                                            fileEntryId, lockUuid);
180    
181                            try {
182                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
183                            }
184                            catch (Exception e) {
185                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
186                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
187                                    }
188    
189                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
190                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
191                                    }
192    
193                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
194                            }
195                    }
196                    catch (com.liferay.portal.kernel.exception.SystemException se) {
197                            _log.error(se, se);
198    
199                            throw se;
200                    }
201            }
202    
203            public static com.liferay.portlet.documentlibrary.model.DLFileEntry checkOutFileEntry(
204                    HttpPrincipal httpPrincipal, long fileEntryId)
205                    throws com.liferay.portal.kernel.exception.PortalException,
206                            com.liferay.portal.kernel.exception.SystemException {
207                    try {
208                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
209                                            "checkOutFileEntry", _checkOutFileEntryParameterTypes4);
210    
211                            MethodHandler methodHandler = new MethodHandler(methodKey,
212                                            fileEntryId);
213    
214                            Object returnObj = null;
215    
216                            try {
217                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
218                            }
219                            catch (Exception e) {
220                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
221                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
222                                    }
223    
224                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
225                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
226                                    }
227    
228                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
229                            }
230    
231                            return (com.liferay.portlet.documentlibrary.model.DLFileEntry)returnObj;
232                    }
233                    catch (com.liferay.portal.kernel.exception.SystemException se) {
234                            _log.error(se, se);
235    
236                            throw se;
237                    }
238            }
239    
240            public static com.liferay.portlet.documentlibrary.model.DLFileEntry checkOutFileEntry(
241                    HttpPrincipal httpPrincipal, long fileEntryId, java.lang.String owner,
242                    long expirationTime)
243                    throws com.liferay.portal.kernel.exception.PortalException,
244                            com.liferay.portal.kernel.exception.SystemException {
245                    try {
246                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
247                                            "checkOutFileEntry", _checkOutFileEntryParameterTypes5);
248    
249                            MethodHandler methodHandler = new MethodHandler(methodKey,
250                                            fileEntryId, owner, expirationTime);
251    
252                            Object returnObj = null;
253    
254                            try {
255                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
256                            }
257                            catch (Exception e) {
258                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
259                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
260                                    }
261    
262                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
263                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
264                                    }
265    
266                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
267                            }
268    
269                            return (com.liferay.portlet.documentlibrary.model.DLFileEntry)returnObj;
270                    }
271                    catch (com.liferay.portal.kernel.exception.SystemException se) {
272                            _log.error(se, se);
273    
274                            throw se;
275                    }
276            }
277    
278            public static com.liferay.portlet.documentlibrary.model.DLFileEntry copyFileEntry(
279                    HttpPrincipal httpPrincipal, long groupId, long repositoryId,
280                    long fileEntryId, long destFolderId,
281                    com.liferay.portal.service.ServiceContext serviceContext)
282                    throws com.liferay.portal.kernel.exception.PortalException,
283                            com.liferay.portal.kernel.exception.SystemException {
284                    try {
285                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
286                                            "copyFileEntry", _copyFileEntryParameterTypes6);
287    
288                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
289                                            repositoryId, fileEntryId, destFolderId, serviceContext);
290    
291                            Object returnObj = null;
292    
293                            try {
294                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
295                            }
296                            catch (Exception e) {
297                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
298                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
299                                    }
300    
301                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
302                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
303                                    }
304    
305                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
306                            }
307    
308                            return (com.liferay.portlet.documentlibrary.model.DLFileEntry)returnObj;
309                    }
310                    catch (com.liferay.portal.kernel.exception.SystemException se) {
311                            _log.error(se, se);
312    
313                            throw se;
314                    }
315            }
316    
317            public static void deleteFileEntry(HttpPrincipal httpPrincipal,
318                    long fileEntryId)
319                    throws com.liferay.portal.kernel.exception.PortalException,
320                            com.liferay.portal.kernel.exception.SystemException {
321                    try {
322                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
323                                            "deleteFileEntry", _deleteFileEntryParameterTypes7);
324    
325                            MethodHandler methodHandler = new MethodHandler(methodKey,
326                                            fileEntryId);
327    
328                            try {
329                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
330                            }
331                            catch (Exception e) {
332                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
333                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
334                                    }
335    
336                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
337                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
338                                    }
339    
340                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
341                            }
342                    }
343                    catch (com.liferay.portal.kernel.exception.SystemException se) {
344                            _log.error(se, se);
345    
346                            throw se;
347                    }
348            }
349    
350            public static void deleteFileEntry(HttpPrincipal httpPrincipal,
351                    long groupId, long folderId, java.lang.String title)
352                    throws com.liferay.portal.kernel.exception.PortalException,
353                            com.liferay.portal.kernel.exception.SystemException {
354                    try {
355                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
356                                            "deleteFileEntry", _deleteFileEntryParameterTypes8);
357    
358                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
359                                            folderId, title);
360    
361                            try {
362                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
363                            }
364                            catch (Exception e) {
365                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
366                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
367                                    }
368    
369                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
370                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
371                                    }
372    
373                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
374                            }
375                    }
376                    catch (com.liferay.portal.kernel.exception.SystemException se) {
377                            _log.error(se, se);
378    
379                            throw se;
380                    }
381            }
382    
383            public static com.liferay.portlet.documentlibrary.model.DLFileEntry fetchFileEntryByImageId(
384                    HttpPrincipal httpPrincipal, long imageId)
385                    throws com.liferay.portal.kernel.exception.PortalException,
386                            com.liferay.portal.kernel.exception.SystemException {
387                    try {
388                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
389                                            "fetchFileEntryByImageId",
390                                            _fetchFileEntryByImageIdParameterTypes9);
391    
392                            MethodHandler methodHandler = new MethodHandler(methodKey, imageId);
393    
394                            Object returnObj = null;
395    
396                            try {
397                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
398                            }
399                            catch (Exception e) {
400                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
401                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
402                                    }
403    
404                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
405                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
406                                    }
407    
408                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
409                            }
410    
411                            return (com.liferay.portlet.documentlibrary.model.DLFileEntry)returnObj;
412                    }
413                    catch (com.liferay.portal.kernel.exception.SystemException se) {
414                            _log.error(se, se);
415    
416                            throw se;
417                    }
418            }
419    
420            public static java.io.InputStream getFileAsStream(
421                    HttpPrincipal httpPrincipal, long fileEntryId, java.lang.String version)
422                    throws com.liferay.portal.kernel.exception.PortalException,
423                            com.liferay.portal.kernel.exception.SystemException {
424                    try {
425                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
426                                            "getFileAsStream", _getFileAsStreamParameterTypes10);
427    
428                            MethodHandler methodHandler = new MethodHandler(methodKey,
429                                            fileEntryId, version);
430    
431                            Object returnObj = null;
432    
433                            try {
434                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
435                            }
436                            catch (Exception e) {
437                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
438                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
439                                    }
440    
441                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
442                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
443                                    }
444    
445                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
446                            }
447    
448                            return (java.io.InputStream)returnObj;
449                    }
450                    catch (com.liferay.portal.kernel.exception.SystemException se) {
451                            _log.error(se, se);
452    
453                            throw se;
454                    }
455            }
456    
457            public static java.io.InputStream getFileAsStream(
458                    HttpPrincipal httpPrincipal, long fileEntryId,
459                    java.lang.String version, boolean incrementCounter)
460                    throws com.liferay.portal.kernel.exception.PortalException,
461                            com.liferay.portal.kernel.exception.SystemException {
462                    try {
463                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
464                                            "getFileAsStream", _getFileAsStreamParameterTypes11);
465    
466                            MethodHandler methodHandler = new MethodHandler(methodKey,
467                                            fileEntryId, version, incrementCounter);
468    
469                            Object returnObj = null;
470    
471                            try {
472                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
473                            }
474                            catch (Exception e) {
475                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
476                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
477                                    }
478    
479                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
480                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
481                                    }
482    
483                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
484                            }
485    
486                            return (java.io.InputStream)returnObj;
487                    }
488                    catch (com.liferay.portal.kernel.exception.SystemException se) {
489                            _log.error(se, se);
490    
491                            throw se;
492                    }
493            }
494    
495            public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getFileEntries(
496                    HttpPrincipal httpPrincipal, long groupId, long folderId, int start,
497                    int end, com.liferay.portal.kernel.util.OrderByComparator obc)
498                    throws com.liferay.portal.kernel.exception.SystemException {
499                    try {
500                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
501                                            "getFileEntries", _getFileEntriesParameterTypes12);
502    
503                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
504                                            folderId, start, end, obc);
505    
506                            Object returnObj = null;
507    
508                            try {
509                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
510                            }
511                            catch (Exception e) {
512                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
513                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
514                                    }
515    
516                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
517                            }
518    
519                            return (java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry>)returnObj;
520                    }
521                    catch (com.liferay.portal.kernel.exception.SystemException se) {
522                            _log.error(se, se);
523    
524                            throw se;
525                    }
526            }
527    
528            public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getFileEntries(
529                    HttpPrincipal httpPrincipal, long groupId, long folderId,
530                    long fileEntryTypeId, int start, int end,
531                    com.liferay.portal.kernel.util.OrderByComparator obc)
532                    throws com.liferay.portal.kernel.exception.SystemException {
533                    try {
534                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
535                                            "getFileEntries", _getFileEntriesParameterTypes13);
536    
537                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
538                                            folderId, fileEntryTypeId, start, end, obc);
539    
540                            Object returnObj = null;
541    
542                            try {
543                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
544                            }
545                            catch (Exception e) {
546                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
547                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
548                                    }
549    
550                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
551                            }
552    
553                            return (java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry>)returnObj;
554                    }
555                    catch (com.liferay.portal.kernel.exception.SystemException se) {
556                            _log.error(se, se);
557    
558                            throw se;
559                    }
560            }
561    
562            public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getFileEntries(
563                    HttpPrincipal httpPrincipal, long groupId, long folderId,
564                    java.lang.String[] mimeTypes, int start, int end,
565                    com.liferay.portal.kernel.util.OrderByComparator obc)
566                    throws com.liferay.portal.kernel.exception.SystemException {
567                    try {
568                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
569                                            "getFileEntries", _getFileEntriesParameterTypes14);
570    
571                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
572                                            folderId, mimeTypes, start, end, obc);
573    
574                            Object returnObj = null;
575    
576                            try {
577                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
578                            }
579                            catch (Exception e) {
580                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
581                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
582                                    }
583    
584                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
585                            }
586    
587                            return (java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry>)returnObj;
588                    }
589                    catch (com.liferay.portal.kernel.exception.SystemException se) {
590                            _log.error(se, se);
591    
592                            throw se;
593                    }
594            }
595    
596            public static int getFileEntriesCount(HttpPrincipal httpPrincipal,
597                    long groupId, long folderId)
598                    throws com.liferay.portal.kernel.exception.SystemException {
599                    try {
600                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
601                                            "getFileEntriesCount", _getFileEntriesCountParameterTypes15);
602    
603                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
604                                            folderId);
605    
606                            Object returnObj = null;
607    
608                            try {
609                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
610                            }
611                            catch (Exception e) {
612                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
613                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
614                                    }
615    
616                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
617                            }
618    
619                            return ((Integer)returnObj).intValue();
620                    }
621                    catch (com.liferay.portal.kernel.exception.SystemException se) {
622                            _log.error(se, se);
623    
624                            throw se;
625                    }
626            }
627    
628            public static int getFileEntriesCount(HttpPrincipal httpPrincipal,
629                    long groupId, long folderId, long fileEntryTypeId)
630                    throws com.liferay.portal.kernel.exception.SystemException {
631                    try {
632                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
633                                            "getFileEntriesCount", _getFileEntriesCountParameterTypes16);
634    
635                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
636                                            folderId, fileEntryTypeId);
637    
638                            Object returnObj = null;
639    
640                            try {
641                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
642                            }
643                            catch (Exception e) {
644                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
645                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
646                                    }
647    
648                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
649                            }
650    
651                            return ((Integer)returnObj).intValue();
652                    }
653                    catch (com.liferay.portal.kernel.exception.SystemException se) {
654                            _log.error(se, se);
655    
656                            throw se;
657                    }
658            }
659    
660            public static int getFileEntriesCount(HttpPrincipal httpPrincipal,
661                    long groupId, long folderId, java.lang.String[] mimeTypes)
662                    throws com.liferay.portal.kernel.exception.SystemException {
663                    try {
664                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
665                                            "getFileEntriesCount", _getFileEntriesCountParameterTypes17);
666    
667                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
668                                            folderId, mimeTypes);
669    
670                            Object returnObj = null;
671    
672                            try {
673                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
674                            }
675                            catch (Exception e) {
676                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
677                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
678                                    }
679    
680                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
681                            }
682    
683                            return ((Integer)returnObj).intValue();
684                    }
685                    catch (com.liferay.portal.kernel.exception.SystemException se) {
686                            _log.error(se, se);
687    
688                            throw se;
689                    }
690            }
691    
692            public static com.liferay.portlet.documentlibrary.model.DLFileEntry getFileEntry(
693                    HttpPrincipal httpPrincipal, long fileEntryId)
694                    throws com.liferay.portal.kernel.exception.PortalException,
695                            com.liferay.portal.kernel.exception.SystemException {
696                    try {
697                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
698                                            "getFileEntry", _getFileEntryParameterTypes18);
699    
700                            MethodHandler methodHandler = new MethodHandler(methodKey,
701                                            fileEntryId);
702    
703                            Object returnObj = null;
704    
705                            try {
706                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
707                            }
708                            catch (Exception e) {
709                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
710                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
711                                    }
712    
713                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
714                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
715                                    }
716    
717                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
718                            }
719    
720                            return (com.liferay.portlet.documentlibrary.model.DLFileEntry)returnObj;
721                    }
722                    catch (com.liferay.portal.kernel.exception.SystemException se) {
723                            _log.error(se, se);
724    
725                            throw se;
726                    }
727            }
728    
729            public static com.liferay.portlet.documentlibrary.model.DLFileEntry getFileEntry(
730                    HttpPrincipal httpPrincipal, long groupId, long folderId,
731                    java.lang.String title)
732                    throws com.liferay.portal.kernel.exception.PortalException,
733                            com.liferay.portal.kernel.exception.SystemException {
734                    try {
735                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
736                                            "getFileEntry", _getFileEntryParameterTypes19);
737    
738                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
739                                            folderId, title);
740    
741                            Object returnObj = null;
742    
743                            try {
744                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
745                            }
746                            catch (Exception e) {
747                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
748                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
749                                    }
750    
751                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
752                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
753                                    }
754    
755                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
756                            }
757    
758                            return (com.liferay.portlet.documentlibrary.model.DLFileEntry)returnObj;
759                    }
760                    catch (com.liferay.portal.kernel.exception.SystemException se) {
761                            _log.error(se, se);
762    
763                            throw se;
764                    }
765            }
766    
767            public static com.liferay.portlet.documentlibrary.model.DLFileEntry getFileEntryByUuidAndGroupId(
768                    HttpPrincipal httpPrincipal, java.lang.String uuid, long groupId)
769                    throws com.liferay.portal.kernel.exception.PortalException,
770                            com.liferay.portal.kernel.exception.SystemException {
771                    try {
772                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
773                                            "getFileEntryByUuidAndGroupId",
774                                            _getFileEntryByUuidAndGroupIdParameterTypes20);
775    
776                            MethodHandler methodHandler = new MethodHandler(methodKey, uuid,
777                                            groupId);
778    
779                            Object returnObj = null;
780    
781                            try {
782                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
783                            }
784                            catch (Exception e) {
785                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
786                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
787                                    }
788    
789                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
790                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
791                                    }
792    
793                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
794                            }
795    
796                            return (com.liferay.portlet.documentlibrary.model.DLFileEntry)returnObj;
797                    }
798                    catch (com.liferay.portal.kernel.exception.SystemException se) {
799                            _log.error(se, se);
800    
801                            throw se;
802                    }
803            }
804    
805            public static com.liferay.portal.model.Lock getFileEntryLock(
806                    HttpPrincipal httpPrincipal, long fileEntryId)
807                    throws com.liferay.portal.kernel.exception.SystemException {
808                    try {
809                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
810                                            "getFileEntryLock", _getFileEntryLockParameterTypes21);
811    
812                            MethodHandler methodHandler = new MethodHandler(methodKey,
813                                            fileEntryId);
814    
815                            Object returnObj = null;
816    
817                            try {
818                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
819                            }
820                            catch (Exception e) {
821                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
822                            }
823    
824                            return (com.liferay.portal.model.Lock)returnObj;
825                    }
826                    catch (com.liferay.portal.kernel.exception.SystemException se) {
827                            _log.error(se, se);
828    
829                            throw se;
830                    }
831            }
832    
833            public static int getFoldersFileEntriesCount(HttpPrincipal httpPrincipal,
834                    long groupId, java.util.List<java.lang.Long> folderIds, int status)
835                    throws com.liferay.portal.kernel.exception.SystemException {
836                    try {
837                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
838                                            "getFoldersFileEntriesCount",
839                                            _getFoldersFileEntriesCountParameterTypes22);
840    
841                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
842                                            folderIds, status);
843    
844                            Object returnObj = null;
845    
846                            try {
847                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
848                            }
849                            catch (Exception e) {
850                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
851                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
852                                    }
853    
854                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
855                            }
856    
857                            return ((Integer)returnObj).intValue();
858                    }
859                    catch (com.liferay.portal.kernel.exception.SystemException se) {
860                            _log.error(se, se);
861    
862                            throw se;
863                    }
864            }
865    
866            public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getGroupFileEntries(
867                    HttpPrincipal httpPrincipal, long groupId, long userId,
868                    long rootFolderId, int start, int end,
869                    com.liferay.portal.kernel.util.OrderByComparator obc)
870                    throws com.liferay.portal.kernel.exception.SystemException {
871                    try {
872                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
873                                            "getGroupFileEntries", _getGroupFileEntriesParameterTypes23);
874    
875                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
876                                            userId, rootFolderId, start, end, obc);
877    
878                            Object returnObj = null;
879    
880                            try {
881                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
882                            }
883                            catch (Exception e) {
884                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
885                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
886                                    }
887    
888                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
889                            }
890    
891                            return (java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry>)returnObj;
892                    }
893                    catch (com.liferay.portal.kernel.exception.SystemException se) {
894                            _log.error(se, se);
895    
896                            throw se;
897                    }
898            }
899    
900            public static java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getGroupFileEntries(
901                    HttpPrincipal httpPrincipal, long groupId, long userId,
902                    long rootFolderId, java.lang.String[] mimeTypes, int status, int start,
903                    int end, com.liferay.portal.kernel.util.OrderByComparator obc)
904                    throws com.liferay.portal.kernel.exception.SystemException {
905                    try {
906                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
907                                            "getGroupFileEntries", _getGroupFileEntriesParameterTypes24);
908    
909                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
910                                            userId, rootFolderId, mimeTypes, status, start, end, obc);
911    
912                            Object returnObj = null;
913    
914                            try {
915                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
916                            }
917                            catch (Exception e) {
918                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
919                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
920                                    }
921    
922                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
923                            }
924    
925                            return (java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry>)returnObj;
926                    }
927                    catch (com.liferay.portal.kernel.exception.SystemException se) {
928                            _log.error(se, se);
929    
930                            throw se;
931                    }
932            }
933    
934            public static int getGroupFileEntriesCount(HttpPrincipal httpPrincipal,
935                    long groupId, long userId, long rootFolderId)
936                    throws com.liferay.portal.kernel.exception.SystemException {
937                    try {
938                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
939                                            "getGroupFileEntriesCount",
940                                            _getGroupFileEntriesCountParameterTypes25);
941    
942                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
943                                            userId, rootFolderId);
944    
945                            Object returnObj = null;
946    
947                            try {
948                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
949                            }
950                            catch (Exception e) {
951                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
952                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
953                                    }
954    
955                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
956                            }
957    
958                            return ((Integer)returnObj).intValue();
959                    }
960                    catch (com.liferay.portal.kernel.exception.SystemException se) {
961                            _log.error(se, se);
962    
963                            throw se;
964                    }
965            }
966    
967            public static int getGroupFileEntriesCount(HttpPrincipal httpPrincipal,
968                    long groupId, long userId, long rootFolderId,
969                    java.lang.String[] mimeTypes, int status)
970                    throws com.liferay.portal.kernel.exception.SystemException {
971                    try {
972                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
973                                            "getGroupFileEntriesCount",
974                                            _getGroupFileEntriesCountParameterTypes26);
975    
976                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
977                                            userId, rootFolderId, mimeTypes, status);
978    
979                            Object returnObj = null;
980    
981                            try {
982                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
983                            }
984                            catch (Exception e) {
985                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
986                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
987                                    }
988    
989                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
990                            }
991    
992                            return ((Integer)returnObj).intValue();
993                    }
994                    catch (com.liferay.portal.kernel.exception.SystemException se) {
995                            _log.error(se, se);
996    
997                            throw se;
998                    }
999            }
1000    
1001            public static boolean hasFileEntryLock(HttpPrincipal httpPrincipal,
1002                    long fileEntryId)
1003                    throws com.liferay.portal.kernel.exception.PortalException,
1004                            com.liferay.portal.kernel.exception.SystemException {
1005                    try {
1006                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1007                                            "hasFileEntryLock", _hasFileEntryLockParameterTypes27);
1008    
1009                            MethodHandler methodHandler = new MethodHandler(methodKey,
1010                                            fileEntryId);
1011    
1012                            Object returnObj = null;
1013    
1014                            try {
1015                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1016                            }
1017                            catch (Exception e) {
1018                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1019                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1020                                    }
1021    
1022                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1023                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1024                                    }
1025    
1026                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1027                            }
1028    
1029                            return ((Boolean)returnObj).booleanValue();
1030                    }
1031                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1032                            _log.error(se, se);
1033    
1034                            throw se;
1035                    }
1036            }
1037    
1038            public static boolean isFileEntryCheckedOut(HttpPrincipal httpPrincipal,
1039                    long fileEntryId)
1040                    throws com.liferay.portal.kernel.exception.PortalException,
1041                            com.liferay.portal.kernel.exception.SystemException {
1042                    try {
1043                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1044                                            "isFileEntryCheckedOut",
1045                                            _isFileEntryCheckedOutParameterTypes28);
1046    
1047                            MethodHandler methodHandler = new MethodHandler(methodKey,
1048                                            fileEntryId);
1049    
1050                            Object returnObj = null;
1051    
1052                            try {
1053                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1054                            }
1055                            catch (Exception e) {
1056                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1057                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1058                                    }
1059    
1060                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1061                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1062                                    }
1063    
1064                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1065                            }
1066    
1067                            return ((Boolean)returnObj).booleanValue();
1068                    }
1069                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1070                            _log.error(se, se);
1071    
1072                            throw se;
1073                    }
1074            }
1075    
1076            public static com.liferay.portal.model.Lock lockFileEntry(
1077                    HttpPrincipal httpPrincipal, long fileEntryId)
1078                    throws com.liferay.portal.kernel.exception.PortalException,
1079                            com.liferay.portal.kernel.exception.SystemException {
1080                    try {
1081                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1082                                            "lockFileEntry", _lockFileEntryParameterTypes29);
1083    
1084                            MethodHandler methodHandler = new MethodHandler(methodKey,
1085                                            fileEntryId);
1086    
1087                            Object returnObj = null;
1088    
1089                            try {
1090                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1091                            }
1092                            catch (Exception e) {
1093                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1094                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1095                                    }
1096    
1097                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1098                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1099                                    }
1100    
1101                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1102                            }
1103    
1104                            return (com.liferay.portal.model.Lock)returnObj;
1105                    }
1106                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1107                            _log.error(se, se);
1108    
1109                            throw se;
1110                    }
1111            }
1112    
1113            public static com.liferay.portal.model.Lock lockFileEntry(
1114                    HttpPrincipal httpPrincipal, long fileEntryId, java.lang.String owner,
1115                    long expirationTime)
1116                    throws com.liferay.portal.kernel.exception.PortalException,
1117                            com.liferay.portal.kernel.exception.SystemException {
1118                    try {
1119                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1120                                            "lockFileEntry", _lockFileEntryParameterTypes30);
1121    
1122                            MethodHandler methodHandler = new MethodHandler(methodKey,
1123                                            fileEntryId, owner, expirationTime);
1124    
1125                            Object returnObj = null;
1126    
1127                            try {
1128                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1129                            }
1130                            catch (Exception e) {
1131                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1132                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1133                                    }
1134    
1135                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1136                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1137                                    }
1138    
1139                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1140                            }
1141    
1142                            return (com.liferay.portal.model.Lock)returnObj;
1143                    }
1144                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1145                            _log.error(se, se);
1146    
1147                            throw se;
1148                    }
1149            }
1150    
1151            public static com.liferay.portlet.documentlibrary.model.DLFileEntry moveFileEntry(
1152                    HttpPrincipal httpPrincipal, long fileEntryId, long newFolderId,
1153                    com.liferay.portal.service.ServiceContext serviceContext)
1154                    throws com.liferay.portal.kernel.exception.PortalException,
1155                            com.liferay.portal.kernel.exception.SystemException {
1156                    try {
1157                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1158                                            "moveFileEntry", _moveFileEntryParameterTypes31);
1159    
1160                            MethodHandler methodHandler = new MethodHandler(methodKey,
1161                                            fileEntryId, newFolderId, serviceContext);
1162    
1163                            Object returnObj = null;
1164    
1165                            try {
1166                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1167                            }
1168                            catch (Exception e) {
1169                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1170                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1171                                    }
1172    
1173                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1174                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1175                                    }
1176    
1177                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1178                            }
1179    
1180                            return (com.liferay.portlet.documentlibrary.model.DLFileEntry)returnObj;
1181                    }
1182                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1183                            _log.error(se, se);
1184    
1185                            throw se;
1186                    }
1187            }
1188    
1189            public static com.liferay.portal.model.Lock refreshFileEntryLock(
1190                    HttpPrincipal httpPrincipal, java.lang.String lockUuid,
1191                    long expirationTime)
1192                    throws com.liferay.portal.kernel.exception.PortalException,
1193                            com.liferay.portal.kernel.exception.SystemException {
1194                    try {
1195                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1196                                            "refreshFileEntryLock",
1197                                            _refreshFileEntryLockParameterTypes32);
1198    
1199                            MethodHandler methodHandler = new MethodHandler(methodKey,
1200                                            lockUuid, expirationTime);
1201    
1202                            Object returnObj = null;
1203    
1204                            try {
1205                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1206                            }
1207                            catch (Exception e) {
1208                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1209                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1210                                    }
1211    
1212                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1213                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1214                                    }
1215    
1216                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1217                            }
1218    
1219                            return (com.liferay.portal.model.Lock)returnObj;
1220                    }
1221                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1222                            _log.error(se, se);
1223    
1224                            throw se;
1225                    }
1226            }
1227    
1228            public static void revertFileEntry(HttpPrincipal httpPrincipal,
1229                    long fileEntryId, java.lang.String version,
1230                    com.liferay.portal.service.ServiceContext serviceContext)
1231                    throws com.liferay.portal.kernel.exception.PortalException,
1232                            com.liferay.portal.kernel.exception.SystemException {
1233                    try {
1234                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1235                                            "revertFileEntry", _revertFileEntryParameterTypes33);
1236    
1237                            MethodHandler methodHandler = new MethodHandler(methodKey,
1238                                            fileEntryId, version, serviceContext);
1239    
1240                            try {
1241                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1242                            }
1243                            catch (Exception e) {
1244                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1245                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1246                                    }
1247    
1248                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1249                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1250                                    }
1251    
1252                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1253                            }
1254                    }
1255                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1256                            _log.error(se, se);
1257    
1258                            throw se;
1259                    }
1260            }
1261    
1262            public static void unlockFileEntry(HttpPrincipal httpPrincipal,
1263                    long fileEntryId)
1264                    throws com.liferay.portal.kernel.exception.PortalException,
1265                            com.liferay.portal.kernel.exception.SystemException {
1266                    try {
1267                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1268                                            "unlockFileEntry", _unlockFileEntryParameterTypes34);
1269    
1270                            MethodHandler methodHandler = new MethodHandler(methodKey,
1271                                            fileEntryId);
1272    
1273                            try {
1274                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1275                            }
1276                            catch (Exception e) {
1277                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1278                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1279                                    }
1280    
1281                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1282                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1283                                    }
1284    
1285                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1286                            }
1287                    }
1288                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1289                            _log.error(se, se);
1290    
1291                            throw se;
1292                    }
1293            }
1294    
1295            public static void unlockFileEntry(HttpPrincipal httpPrincipal,
1296                    long fileEntryId, java.lang.String lockUuid)
1297                    throws com.liferay.portal.kernel.exception.PortalException,
1298                            com.liferay.portal.kernel.exception.SystemException {
1299                    try {
1300                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1301                                            "unlockFileEntry", _unlockFileEntryParameterTypes35);
1302    
1303                            MethodHandler methodHandler = new MethodHandler(methodKey,
1304                                            fileEntryId, lockUuid);
1305    
1306                            try {
1307                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1308                            }
1309                            catch (Exception e) {
1310                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1311                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1312                                    }
1313    
1314                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1315                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1316                                    }
1317    
1318                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1319                            }
1320                    }
1321                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1322                            _log.error(se, se);
1323    
1324                            throw se;
1325                    }
1326            }
1327    
1328            public static com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry(
1329                    HttpPrincipal httpPrincipal, long fileEntryId,
1330                    java.lang.String sourceFileName, java.lang.String mimeType,
1331                    java.lang.String title, java.lang.String description,
1332                    java.lang.String changeLog, boolean majorVersion, long fileEntryTypeId,
1333                    java.util.Map<java.lang.String, com.liferay.portlet.dynamicdatamapping.storage.Fields> fieldsMap,
1334                    java.io.File file, java.io.InputStream is, long size,
1335                    com.liferay.portal.service.ServiceContext serviceContext)
1336                    throws com.liferay.portal.kernel.exception.PortalException,
1337                            com.liferay.portal.kernel.exception.SystemException {
1338                    try {
1339                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1340                                            "updateFileEntry", _updateFileEntryParameterTypes36);
1341    
1342                            MethodHandler methodHandler = new MethodHandler(methodKey,
1343                                            fileEntryId, sourceFileName, mimeType, title, description,
1344                                            changeLog, majorVersion, fileEntryTypeId, fieldsMap, file,
1345                                            is, size, serviceContext);
1346    
1347                            Object returnObj = null;
1348    
1349                            try {
1350                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1351                            }
1352                            catch (Exception e) {
1353                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1354                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1355                                    }
1356    
1357                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1358                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1359                                    }
1360    
1361                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1362                            }
1363    
1364                            return (com.liferay.portlet.documentlibrary.model.DLFileEntry)returnObj;
1365                    }
1366                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1367                            _log.error(se, se);
1368    
1369                            throw se;
1370                    }
1371            }
1372    
1373            public static boolean verifyFileEntryCheckOut(HttpPrincipal httpPrincipal,
1374                    long fileEntryId, java.lang.String lockUuid)
1375                    throws com.liferay.portal.kernel.exception.PortalException,
1376                            com.liferay.portal.kernel.exception.SystemException {
1377                    try {
1378                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1379                                            "verifyFileEntryCheckOut",
1380                                            _verifyFileEntryCheckOutParameterTypes37);
1381    
1382                            MethodHandler methodHandler = new MethodHandler(methodKey,
1383                                            fileEntryId, lockUuid);
1384    
1385                            Object returnObj = null;
1386    
1387                            try {
1388                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1389                            }
1390                            catch (Exception e) {
1391                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1392                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1393                                    }
1394    
1395                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1396                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1397                                    }
1398    
1399                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1400                            }
1401    
1402                            return ((Boolean)returnObj).booleanValue();
1403                    }
1404                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1405                            _log.error(se, se);
1406    
1407                            throw se;
1408                    }
1409            }
1410    
1411            public static boolean verifyFileEntryLock(HttpPrincipal httpPrincipal,
1412                    long fileEntryId, java.lang.String lockUuid)
1413                    throws com.liferay.portal.kernel.exception.PortalException,
1414                            com.liferay.portal.kernel.exception.SystemException {
1415                    try {
1416                            MethodKey methodKey = new MethodKey(DLFileEntryServiceUtil.class.getName(),
1417                                            "verifyFileEntryLock", _verifyFileEntryLockParameterTypes38);
1418    
1419                            MethodHandler methodHandler = new MethodHandler(methodKey,
1420                                            fileEntryId, lockUuid);
1421    
1422                            Object returnObj = null;
1423    
1424                            try {
1425                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1426                            }
1427                            catch (Exception e) {
1428                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1429                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1430                                    }
1431    
1432                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1433                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1434                                    }
1435    
1436                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1437                            }
1438    
1439                            return ((Boolean)returnObj).booleanValue();
1440                    }
1441                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1442                            _log.error(se, se);
1443    
1444                            throw se;
1445                    }
1446            }
1447    
1448            private static Log _log = LogFactoryUtil.getLog(DLFileEntryServiceHttp.class);
1449            private static final Class<?>[] _addFileEntryParameterTypes0 = new Class[] {
1450                            long.class, long.class, long.class, java.lang.String.class,
1451                            java.lang.String.class, java.lang.String.class,
1452                            java.lang.String.class, java.lang.String.class, long.class,
1453                            java.util.Map.class, java.io.File.class, java.io.InputStream.class,
1454                            long.class, com.liferay.portal.service.ServiceContext.class
1455                    };
1456            private static final Class<?>[] _cancelCheckOutParameterTypes1 = new Class[] {
1457                            long.class
1458                    };
1459            private static final Class<?>[] _checkInFileEntryParameterTypes2 = new Class[] {
1460                            long.class, boolean.class, java.lang.String.class,
1461                            com.liferay.portal.service.ServiceContext.class
1462                    };
1463            private static final Class<?>[] _checkInFileEntryParameterTypes3 = new Class[] {
1464                            long.class, java.lang.String.class
1465                    };
1466            private static final Class<?>[] _checkOutFileEntryParameterTypes4 = new Class[] {
1467                            long.class
1468                    };
1469            private static final Class<?>[] _checkOutFileEntryParameterTypes5 = new Class[] {
1470                            long.class, java.lang.String.class, long.class
1471                    };
1472            private static final Class<?>[] _copyFileEntryParameterTypes6 = new Class[] {
1473                            long.class, long.class, long.class, long.class,
1474                            com.liferay.portal.service.ServiceContext.class
1475                    };
1476            private static final Class<?>[] _deleteFileEntryParameterTypes7 = new Class[] {
1477                            long.class
1478                    };
1479            private static final Class<?>[] _deleteFileEntryParameterTypes8 = new Class[] {
1480                            long.class, long.class, java.lang.String.class
1481                    };
1482            private static final Class<?>[] _fetchFileEntryByImageIdParameterTypes9 = new Class[] {
1483                            long.class
1484                    };
1485            private static final Class<?>[] _getFileAsStreamParameterTypes10 = new Class[] {
1486                            long.class, java.lang.String.class
1487                    };
1488            private static final Class<?>[] _getFileAsStreamParameterTypes11 = new Class[] {
1489                            long.class, java.lang.String.class, boolean.class
1490                    };
1491            private static final Class<?>[] _getFileEntriesParameterTypes12 = new Class[] {
1492                            long.class, long.class, int.class, int.class,
1493                            com.liferay.portal.kernel.util.OrderByComparator.class
1494                    };
1495            private static final Class<?>[] _getFileEntriesParameterTypes13 = new Class[] {
1496                            long.class, long.class, long.class, int.class, int.class,
1497                            com.liferay.portal.kernel.util.OrderByComparator.class
1498                    };
1499            private static final Class<?>[] _getFileEntriesParameterTypes14 = new Class[] {
1500                            long.class, long.class, java.lang.String[].class, int.class,
1501                            int.class, com.liferay.portal.kernel.util.OrderByComparator.class
1502                    };
1503            private static final Class<?>[] _getFileEntriesCountParameterTypes15 = new Class[] {
1504                            long.class, long.class
1505                    };
1506            private static final Class<?>[] _getFileEntriesCountParameterTypes16 = new Class[] {
1507                            long.class, long.class, long.class
1508                    };
1509            private static final Class<?>[] _getFileEntriesCountParameterTypes17 = new Class[] {
1510                            long.class, long.class, java.lang.String[].class
1511                    };
1512            private static final Class<?>[] _getFileEntryParameterTypes18 = new Class[] {
1513                            long.class
1514                    };
1515            private static final Class<?>[] _getFileEntryParameterTypes19 = new Class[] {
1516                            long.class, long.class, java.lang.String.class
1517                    };
1518            private static final Class<?>[] _getFileEntryByUuidAndGroupIdParameterTypes20 =
1519                    new Class[] { java.lang.String.class, long.class };
1520            private static final Class<?>[] _getFileEntryLockParameterTypes21 = new Class[] {
1521                            long.class
1522                    };
1523            private static final Class<?>[] _getFoldersFileEntriesCountParameterTypes22 = new Class[] {
1524                            long.class, java.util.List.class, int.class
1525                    };
1526            private static final Class<?>[] _getGroupFileEntriesParameterTypes23 = new Class[] {
1527                            long.class, long.class, long.class, int.class, int.class,
1528                            com.liferay.portal.kernel.util.OrderByComparator.class
1529                    };
1530            private static final Class<?>[] _getGroupFileEntriesParameterTypes24 = new Class[] {
1531                            long.class, long.class, long.class, java.lang.String[].class,
1532                            int.class, int.class, int.class,
1533                            com.liferay.portal.kernel.util.OrderByComparator.class
1534                    };
1535            private static final Class<?>[] _getGroupFileEntriesCountParameterTypes25 = new Class[] {
1536                            long.class, long.class, long.class
1537                    };
1538            private static final Class<?>[] _getGroupFileEntriesCountParameterTypes26 = new Class[] {
1539                            long.class, long.class, long.class, java.lang.String[].class,
1540                            int.class
1541                    };
1542            private static final Class<?>[] _hasFileEntryLockParameterTypes27 = new Class[] {
1543                            long.class
1544                    };
1545            private static final Class<?>[] _isFileEntryCheckedOutParameterTypes28 = new Class[] {
1546                            long.class
1547                    };
1548            private static final Class<?>[] _lockFileEntryParameterTypes29 = new Class[] {
1549                            long.class
1550                    };
1551            private static final Class<?>[] _lockFileEntryParameterTypes30 = new Class[] {
1552                            long.class, java.lang.String.class, long.class
1553                    };
1554            private static final Class<?>[] _moveFileEntryParameterTypes31 = new Class[] {
1555                            long.class, long.class,
1556                            com.liferay.portal.service.ServiceContext.class
1557                    };
1558            private static final Class<?>[] _refreshFileEntryLockParameterTypes32 = new Class[] {
1559                            java.lang.String.class, long.class
1560                    };
1561            private static final Class<?>[] _revertFileEntryParameterTypes33 = new Class[] {
1562                            long.class, java.lang.String.class,
1563                            com.liferay.portal.service.ServiceContext.class
1564                    };
1565            private static final Class<?>[] _unlockFileEntryParameterTypes34 = new Class[] {
1566                            long.class
1567                    };
1568            private static final Class<?>[] _unlockFileEntryParameterTypes35 = new Class[] {
1569                            long.class, java.lang.String.class
1570                    };
1571            private static final Class<?>[] _updateFileEntryParameterTypes36 = new Class[] {
1572                            long.class, java.lang.String.class, java.lang.String.class,
1573                            java.lang.String.class, java.lang.String.class,
1574                            java.lang.String.class, boolean.class, long.class,
1575                            java.util.Map.class, java.io.File.class, java.io.InputStream.class,
1576                            long.class, com.liferay.portal.service.ServiceContext.class
1577                    };
1578            private static final Class<?>[] _verifyFileEntryCheckOutParameterTypes37 = new Class[] {
1579                            long.class, java.lang.String.class
1580                    };
1581            private static final Class<?>[] _verifyFileEntryLockParameterTypes38 = new Class[] {
1582                            long.class, java.lang.String.class
1583                    };
1584    }