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;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    import com.liferay.portal.kernel.util.ReferenceRegistry;
019    
020    /**
021     * The utility for the d l app remote service. This utility wraps {@link com.liferay.portlet.documentlibrary.service.impl.DLAppServiceImpl} and is the primary access point for service operations in application layer code running on a remote server.
022     *
023     * <p>
024     * This is a remote service. Methods of this service are expected to have security checks based on the propagated JAAS credentials because this service can be accessed remotely.
025     * </p>
026     *
027     * @author Brian Wing Shun Chan
028     * @see DLAppService
029     * @see com.liferay.portlet.documentlibrary.service.base.DLAppServiceBaseImpl
030     * @see com.liferay.portlet.documentlibrary.service.impl.DLAppServiceImpl
031     * @generated
032     */
033    public class DLAppServiceUtil {
034            /*
035             * NOTE FOR DEVELOPERS:
036             *
037             * Never modify this class directly. Add custom service methods to {@link com.liferay.portlet.documentlibrary.service.impl.DLAppServiceImpl} and rerun ServiceBuilder to regenerate this class.
038             */
039    
040            /**
041            * Returns the Spring bean ID for this bean.
042            *
043            * @return the Spring bean ID for this bean
044            */
045            public static java.lang.String getBeanIdentifier() {
046                    return getService().getBeanIdentifier();
047            }
048    
049            /**
050            * Sets the Spring bean ID for this bean.
051            *
052            * @param beanIdentifier the Spring bean ID for this bean
053            */
054            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
055                    getService().setBeanIdentifier(beanIdentifier);
056            }
057    
058            /**
059            * Adds a file entry and associated metadata. It is created based on a byte
060            * array.
061            *
062            * <p>
063            * This method takes two file names, the <code>sourceFileName</code> and the
064            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
065            * name of the actual file being uploaded. The <code>title</code>
066            * corresponds to a name the client wishes to assign this file after it has
067            * been uploaded to the portal. If it is <code>null</code>, the <code>
068            * sourceFileName</code> will be used.
069            * </p>
070            *
071            * @param repositoryId the primary key of the repository
072            * @param folderId the primary key of the file entry's parent folder
073            * @param sourceFileName the original file's name
074            * @param mimeType the file's MIME type
075            * @param title the name to be assigned to the file (optionally <code>null
076            </code>)
077            * @param description the file's description
078            * @param changeLog the file's version change log
079            * @param bytes the file's data (optionally <code>null</code>)
080            * @param serviceContext the service context to be applied. Can set the
081            asset category IDs, asset tag names, and expando bridge
082            attributes for the file entry. In a Liferay repository, it may
083            include:  <ul> <li> fileEntryTypeId - ID for a custom file entry
084            type </li> <li> fieldsMap - mapping for fields associated with a
085            custom file entry type </li> </ul>
086            * @return the file entry
087            * @throws PortalException if the parent folder could not be found or if the
088            file entry's information was invalid
089            * @throws SystemException if a system exception occurred
090            */
091            public static com.liferay.portal.kernel.repository.model.FileEntry addFileEntry(
092                    long repositoryId, long folderId, java.lang.String sourceFileName,
093                    java.lang.String mimeType, java.lang.String title,
094                    java.lang.String description, java.lang.String changeLog, byte[] bytes,
095                    com.liferay.portal.service.ServiceContext serviceContext)
096                    throws com.liferay.portal.kernel.exception.PortalException,
097                            com.liferay.portal.kernel.exception.SystemException {
098                    return getService()
099                                       .addFileEntry(repositoryId, folderId, sourceFileName,
100                            mimeType, title, description, changeLog, bytes, serviceContext);
101            }
102    
103            /**
104            * Adds a file entry and associated metadata. It is created based on a
105            * {@link java.io.File} object.
106            *
107            * <p>
108            * This method takes two file names, the <code>sourceFileName</code> and the
109            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
110            * name of the actual file being uploaded. The <code>title</code>
111            * corresponds to a name the client wishes to assign this file after it has
112            * been uploaded to the portal. If it is <code>null</code>, the <code>
113            * sourceFileName</code> will be used.
114            * </p>
115            *
116            * @param repositoryId the primary key of the repository
117            * @param folderId the primary key of the file entry's parent folder
118            * @param sourceFileName the original file's name
119            * @param mimeType the file's MIME type
120            * @param title the name to be assigned to the file (optionally <code>null
121            </code>)
122            * @param description the file's description
123            * @param changeLog the file's version change log
124            * @param file the file's data (optionally <code>null</code>)
125            * @param serviceContext the service context to be applied. Can set the
126            asset category IDs, asset tag names, and expando bridge
127            attributes for the file entry. In a Liferay repository, it may
128            include:  <ul> <li> fileEntryTypeId - ID for a custom file entry
129            type </li> <li> fieldsMap - mapping for fields associated with a
130            custom file entry type </li> </ul>
131            * @return the file entry
132            * @throws PortalException if the parent folder could not be found or if the
133            file entry's information was invalid
134            * @throws SystemException if a system exception occurred
135            */
136            public static com.liferay.portal.kernel.repository.model.FileEntry addFileEntry(
137                    long repositoryId, long folderId, java.lang.String sourceFileName,
138                    java.lang.String mimeType, java.lang.String title,
139                    java.lang.String description, java.lang.String changeLog,
140                    java.io.File file,
141                    com.liferay.portal.service.ServiceContext serviceContext)
142                    throws com.liferay.portal.kernel.exception.PortalException,
143                            com.liferay.portal.kernel.exception.SystemException {
144                    return getService()
145                                       .addFileEntry(repositoryId, folderId, sourceFileName,
146                            mimeType, title, description, changeLog, file, serviceContext);
147            }
148    
149            /**
150            * Adds a file entry and associated metadata. It is created based on a
151            * {@link java.io.InputStream} object.
152            *
153            * <p>
154            * This method takes two file names, the <code>sourceFileName</code> and the
155            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
156            * name of the actual file being uploaded. The <code>title</code>
157            * corresponds to a name the client wishes to assign this file after it has
158            * been uploaded to the portal. If it is <code>null</code>, the <code>
159            * sourceFileName</code> will be used.
160            * </p>
161            *
162            * @param repositoryId the primary key of the repository
163            * @param folderId the primary key of the file entry's parent folder
164            * @param sourceFileName the original file's name
165            * @param mimeType the file's MIME type
166            * @param title the name to be assigned to the file (optionally <code>null
167            </code>)
168            * @param description the file's description
169            * @param changeLog the file's version change log
170            * @param is the file's data (optionally <code>null</code>)
171            * @param size the file's size (optionally <code>0</code>)
172            * @param serviceContext the service context to be applied. Can set the
173            asset category IDs, asset tag names, and expando bridge
174            attributes for the file entry. In a Liferay repository, it may
175            include:  <ul> <li> fileEntryTypeId - ID for a custom file entry
176            type </li> <li> fieldsMap - mapping for fields associated with a
177            custom file entry type </li> </ul>
178            * @return the file entry
179            * @throws PortalException if the parent folder could not be found or if the
180            file entry's information was invalid
181            * @throws SystemException if a system exception occurred
182            */
183            public static com.liferay.portal.kernel.repository.model.FileEntry addFileEntry(
184                    long repositoryId, long folderId, java.lang.String sourceFileName,
185                    java.lang.String mimeType, java.lang.String title,
186                    java.lang.String description, java.lang.String changeLog,
187                    java.io.InputStream is, long size,
188                    com.liferay.portal.service.ServiceContext serviceContext)
189                    throws com.liferay.portal.kernel.exception.PortalException,
190                            com.liferay.portal.kernel.exception.SystemException {
191                    return getService()
192                                       .addFileEntry(repositoryId, folderId, sourceFileName,
193                            mimeType, title, description, changeLog, is, size, serviceContext);
194            }
195    
196            /**
197            * Adds a file shortcut to the existing file entry. This method is only
198            * supported by the Liferay repository.
199            *
200            * @param repositoryId the primary key of the repository
201            * @param folderId the primary key of the file shortcut's parent folder
202            * @param toFileEntryId the primary key of the file shortcut's file entry
203            * @param serviceContext the service context to be applied. Can set the
204            asset category IDs, asset tag names, and expando bridge
205            attributes for the file entry.
206            * @return the file shortcut
207            * @throws PortalException if the parent folder or file entry could not be
208            found, or if the file shortcut's information was invalid
209            * @throws SystemException if a system exception occurred
210            */
211            public static com.liferay.portlet.documentlibrary.model.DLFileShortcut addFileShortcut(
212                    long repositoryId, long folderId, long toFileEntryId,
213                    com.liferay.portal.service.ServiceContext serviceContext)
214                    throws com.liferay.portal.kernel.exception.PortalException,
215                            com.liferay.portal.kernel.exception.SystemException {
216                    return getService()
217                                       .addFileShortcut(repositoryId, folderId, toFileEntryId,
218                            serviceContext);
219            }
220    
221            /**
222            * Adds a folder.
223            *
224            * @param repositoryId the primary key of the repository
225            * @param parentFolderId the primary key of the folder's parent folder
226            * @param name the folder's name
227            * @param description the folder's description
228            * @param serviceContext the service context to be applied. In a Liferay
229            repository, it may include boolean mountPoint specifying whether
230            folder is a facade for mounting a third-party repository
231            * @return the folder
232            * @throws PortalException if the parent folder could not be found or if the
233            new folder's information was invalid
234            * @throws SystemException if a system exception occurred
235            */
236            public static com.liferay.portal.kernel.repository.model.Folder addFolder(
237                    long repositoryId, long parentFolderId, java.lang.String name,
238                    java.lang.String description,
239                    com.liferay.portal.service.ServiceContext serviceContext)
240                    throws com.liferay.portal.kernel.exception.PortalException,
241                            com.liferay.portal.kernel.exception.SystemException {
242                    return getService()
243                                       .addFolder(repositoryId, parentFolderId, name, description,
244                            serviceContext);
245            }
246    
247            /**
248            * Adds a temporary file entry.
249            *
250            * <p>
251            * This allows a client to upload a file into a temporary location and
252            * manipulate its metadata prior to making it available for public usage.
253            * This is different from checking in and checking out a file entry.
254            * </p>
255            *
256            * @param groupId the primary key of the group
257            * @param folderId the primary key of the folder where the file entry will
258            eventually reside
259            * @param fileName the file's original name
260            * @param tempFolderName the temporary folder's name
261            * @param file Name the file's original name
262            * @return the file's name
263            * @throws IOException if a problem occurred in the access or storage of the
264            file
265            * @throws PortalException if the file name was invalid
266            * @throws SystemException if a system exception occurred
267            * @see com.liferay.portal.kernel.util.TempFileUtil
268            */
269            public static java.lang.String addTempFileEntry(long groupId,
270                    long folderId, java.lang.String fileName,
271                    java.lang.String tempFolderName, java.io.File file)
272                    throws com.liferay.portal.kernel.exception.PortalException,
273                            com.liferay.portal.kernel.exception.SystemException,
274                            java.io.IOException {
275                    return getService()
276                                       .addTempFileEntry(groupId, folderId, fileName,
277                            tempFolderName, file);
278            }
279    
280            public static java.lang.String addTempFileEntry(long groupId,
281                    long folderId, java.lang.String fileName,
282                    java.lang.String tempFolderName, java.io.InputStream inputStream)
283                    throws com.liferay.portal.kernel.exception.PortalException,
284                            com.liferay.portal.kernel.exception.SystemException {
285                    return getService()
286                                       .addTempFileEntry(groupId, folderId, fileName,
287                            tempFolderName, inputStream);
288            }
289    
290            /**
291            * Cancels the check out of the file entry. If a user has not checked out
292            * the specified file entry, invoking this method will result in no changes.
293            *
294            * <p>
295            * When a file entry is checked out, a PWC (private working copy) is created
296            * and the original file entry is locked. A client can make as many changes
297            * to the PWC as he desires without those changes being visible to other
298            * users. If the user is satisfied with the changes, he may elect to check
299            * in his changes, resulting in a new file version based on the PWC; the PWC
300            * will be removed and the file entry will be unlocked. If the user is not
301            * satisfied with the changes, he may elect to cancel his check out; this
302            * results in the deletion of the PWC and unlocking of the file entry.
303            * </p>
304            *
305            * @param fileEntryId the primary key of the file entry to cancel the
306            checkout
307            * @throws PortalException if the file entry could not be found
308            * @throws SystemException if a system exception occurred
309            * @see #checkInFileEntry(long, boolean, String, ServiceContext)
310            * @see #checkOutFileEntry(long, ServiceContext)
311            */
312            public static void cancelCheckOut(long fileEntryId)
313                    throws com.liferay.portal.kernel.exception.PortalException,
314                            com.liferay.portal.kernel.exception.SystemException {
315                    getService().cancelCheckOut(fileEntryId);
316            }
317    
318            /**
319            * Checks in the file entry. If a user has not checked out the specified
320            * file entry, invoking this method will result in no changes.
321            *
322            * <p>
323            * When a file entry is checked out, a PWC (private working copy) is created
324            * and the original file entry is locked. A client can make as many changes
325            * to the PWC as he desires without those changes being visible to other
326            * users. If the user is satisfied with the changes, he may elect to check
327            * in his changes, resulting in a new file version based on the PWC; the PWC
328            * will be removed and the file entry will be unlocked. If the user is not
329            * satisfied with the changes, he may elect to cancel his check out; this
330            * results in the deletion of the PWC and unlocking of the file entry.
331            * </p>
332            *
333            * @param fileEntryId the primary key of the file entry to check in
334            * @param majorVersion whether the new file version is a major version
335            * @param changeLog the file's version change log
336            * @param serviceContext the service context to be applied
337            * @throws PortalException if the file entry could not be found
338            * @throws SystemException if a system exception occurred
339            * @see #cancelCheckOut(long)
340            * @see #checkOutFileEntry(long, ServiceContext)
341            */
342            public static void checkInFileEntry(long fileEntryId, boolean majorVersion,
343                    java.lang.String changeLog,
344                    com.liferay.portal.service.ServiceContext serviceContext)
345                    throws com.liferay.portal.kernel.exception.PortalException,
346                            com.liferay.portal.kernel.exception.SystemException {
347                    getService()
348                            .checkInFileEntry(fileEntryId, majorVersion, changeLog,
349                            serviceContext);
350            }
351    
352            /**
353            * @deprecated {@link #checkInFileEntry(long, String, ServiceContext)}
354            */
355            public static void checkInFileEntry(long fileEntryId,
356                    java.lang.String lockUuid)
357                    throws com.liferay.portal.kernel.exception.PortalException,
358                            com.liferay.portal.kernel.exception.SystemException {
359                    getService().checkInFileEntry(fileEntryId, lockUuid);
360            }
361    
362            /**
363            * Checks in the file entry using the lock's UUID. If a user has not checked
364            * out the specified file entry, invoking this method will result in no
365            * changes. This method is primarily used by WebDAV.
366            *
367            * <p>
368            * When a file entry is checked out, a PWC (private working copy) is created
369            * and the original file entry is locked. A client can make as many changes
370            * to the PWC as he desires without those changes being visible to other
371            * users. If the user is satisfied with the changes, he may elect to check
372            * in his changes, resulting in a new file version based on the PWC; the PWC
373            * will be removed and the file entry will be unlocked. If the user is not
374            * satisfied with the changes, he may elect to cancel his check out; this
375            * results in the deletion of the PWC and unlocking of the file entry.
376            * </p>
377            *
378            * @param fileEntryId the primary key of the file entry to check in
379            * @param lockUuid the lock's universally unique identifier
380            * @param serviceContext the service context to be applied
381            * @throws PortalException if the file entry could not be found
382            * @throws SystemException if a system exception occurred
383            * @see #cancelCheckOut(long)
384            * @see #checkOutFileEntry(long, String, long, ServiceContext)
385            */
386            public static void checkInFileEntry(long fileEntryId,
387                    java.lang.String lockUuid,
388                    com.liferay.portal.service.ServiceContext serviceContext)
389                    throws com.liferay.portal.kernel.exception.PortalException,
390                            com.liferay.portal.kernel.exception.SystemException {
391                    getService().checkInFileEntry(fileEntryId, lockUuid, serviceContext);
392            }
393    
394            /**
395            * Check out a file entry.
396            *
397            * <p>
398            * When a file entry is checked out, a PWC (private working copy) is created
399            * and the original file entry is locked. A client can make as many changes
400            * to the PWC as he desires without those changes being visible to other
401            * users. If the user is satisfied with the changes, he may elect to check
402            * in his changes, resulting in a new file version based on the PWC; the PWC
403            * will be removed and the file entry will be unlocked. If the user is not
404            * satisfied with the changes, he may elect to cancel his check out; this
405            * results in the deletion of the PWC and unlocking of the file entry.
406            * </p>
407            *
408            * @param fileEntryId the file entry to check out
409            * @param serviceContext the service context to be applied
410            * @throws PortalException if the file entry could not be found
411            * @throws SystemException if a system exception occurred
412            * @see #cancelCheckOut(long)
413            * @see #checkInFileEntry(long, boolean, String, ServiceContext)
414            */
415            public static void checkOutFileEntry(long fileEntryId,
416                    com.liferay.portal.service.ServiceContext serviceContext)
417                    throws com.liferay.portal.kernel.exception.PortalException,
418                            com.liferay.portal.kernel.exception.SystemException {
419                    getService().checkOutFileEntry(fileEntryId, serviceContext);
420            }
421    
422            /**
423            * Checks out the file entry. This method is primarily used by WebDAV.
424            *
425            * <p>
426            * When a file entry is checked out, a PWC (private working copy) is created
427            * and the original file entry is locked. A client can make as many changes
428            * to the PWC as he desires without those changes being visible to other
429            * users. If the user is satisfied with the changes, he may elect to check
430            * in his changes, resulting in a new file version based on the PWC; the PWC
431            * will be removed and the file entry will be unlocked. If the user is not
432            * satisfied with the changes, he may elect to cancel his check out; this
433            * results in the deletion of the PWC and unlocking of the file entry.
434            * </p>
435            *
436            * @param fileEntryId the file entry to check out
437            * @param owner the owner string for the checkout (optionally
438            <code>null</code>)
439            * @param expirationTime the time in milliseconds before the lock expires.
440            If the value is <code>0</code>, the default expiration time will
441            be used from <code>portal.properties>.
442            * @param serviceContext the service context to be applied
443            * @return the file entry
444            * @throws PortalException if the file entry could not be found
445            * @throws SystemException if a system exception occurred
446            * @see #cancelCheckOut(long)
447            * @see #checkInFileEntry(long, String)
448            */
449            public static com.liferay.portal.kernel.repository.model.FileEntry checkOutFileEntry(
450                    long fileEntryId, java.lang.String owner, long expirationTime,
451                    com.liferay.portal.service.ServiceContext serviceContext)
452                    throws com.liferay.portal.kernel.exception.PortalException,
453                            com.liferay.portal.kernel.exception.SystemException {
454                    return getService()
455                                       .checkOutFileEntry(fileEntryId, owner, expirationTime,
456                            serviceContext);
457            }
458    
459            /**
460            * Performs a deep copy of the folder.
461            *
462            * @param repositoryId the primary key of the repository
463            * @param sourceFolderId the primary key of the folder to copy
464            * @param parentFolderId the primary key of the new folder's parent folder
465            * @param name the new folder's name
466            * @param description the new folder's description
467            * @param serviceContext the service context to be applied
468            * @return the folder
469            * @throws PortalException if the source folder or the new parent folder
470            could not be found or if the new folder's information was invalid
471            * @throws SystemException if a system exception occurred
472            */
473            public static com.liferay.portal.kernel.repository.model.Folder copyFolder(
474                    long repositoryId, long sourceFolderId, long parentFolderId,
475                    java.lang.String name, java.lang.String description,
476                    com.liferay.portal.service.ServiceContext serviceContext)
477                    throws com.liferay.portal.kernel.exception.PortalException,
478                            com.liferay.portal.kernel.exception.SystemException {
479                    return getService()
480                                       .copyFolder(repositoryId, sourceFolderId, parentFolderId,
481                            name, description, serviceContext);
482            }
483    
484            /**
485            * Deletes the file entry with the primary key.
486            *
487            * @param fileEntryId the primary key of the file entry
488            * @throws PortalException if the file entry could not be found
489            * @throws SystemException if a system exception occurred
490            */
491            public static void deleteFileEntry(long fileEntryId)
492                    throws com.liferay.portal.kernel.exception.PortalException,
493                            com.liferay.portal.kernel.exception.SystemException {
494                    getService().deleteFileEntry(fileEntryId);
495            }
496    
497            /**
498            * Deletes the file entry with the title in the folder.
499            *
500            * @param repositoryId the primary key of the repository
501            * @param folderId the primary key of the file entry's parent folder
502            * @param title the file entry's title
503            * @throws PortalException if the file entry could not be found
504            * @throws SystemException if a system exception occurred
505            */
506            public static void deleteFileEntryByTitle(long repositoryId, long folderId,
507                    java.lang.String title)
508                    throws com.liferay.portal.kernel.exception.PortalException,
509                            com.liferay.portal.kernel.exception.SystemException {
510                    getService().deleteFileEntryByTitle(repositoryId, folderId, title);
511            }
512    
513            /**
514            * Deletes the file shortcut with the primary key. This method is only
515            * supported by the Liferay repository.
516            *
517            * @param fileShortcutId the primary key of the file shortcut
518            * @throws PortalException if the file shortcut could not be found
519            * @throws SystemException if a system exception occurred
520            */
521            public static void deleteFileShortcut(long fileShortcutId)
522                    throws com.liferay.portal.kernel.exception.PortalException,
523                            com.liferay.portal.kernel.exception.SystemException {
524                    getService().deleteFileShortcut(fileShortcutId);
525            }
526    
527            /**
528            * Deletes the file version. File versions can only be deleted if it is
529            * approved and there are other approved file versions available. This
530            * method is only supported by the Liferay repository.
531            *
532            * @param fileEntryId the primary key of the file entry
533            * @param version the version label of the file version
534            * @throws PortalException if the file version could not be found or invalid
535            * @throws SystemException if a system exception occurred
536            */
537            public static void deleteFileVersion(long fileEntryId,
538                    java.lang.String version)
539                    throws com.liferay.portal.kernel.exception.PortalException,
540                            com.liferay.portal.kernel.exception.SystemException {
541                    getService().deleteFileVersion(fileEntryId, version);
542            }
543    
544            /**
545            * Deletes the folder with the primary key and all of its subfolders and
546            * file entries.
547            *
548            * @param folderId the primary key of the folder
549            * @throws PortalException if the folder could not be found
550            * @throws SystemException if a system exception occurred
551            */
552            public static void deleteFolder(long folderId)
553                    throws com.liferay.portal.kernel.exception.PortalException,
554                            com.liferay.portal.kernel.exception.SystemException {
555                    getService().deleteFolder(folderId);
556            }
557    
558            /**
559            * Deletes the folder with the name in the parent folder and all of its
560            * subfolders and file entries.
561            *
562            * @param repositoryId the primary key of the repository
563            * @param parentFolderId the primary key of the folder's parent folder
564            * @param name the folder's name
565            * @throws PortalException if the folder could not be found
566            * @throws SystemException if a system exception occurred
567            */
568            public static void deleteFolder(long repositoryId, long parentFolderId,
569                    java.lang.String name)
570                    throws com.liferay.portal.kernel.exception.PortalException,
571                            com.liferay.portal.kernel.exception.SystemException {
572                    getService().deleteFolder(repositoryId, parentFolderId, name);
573            }
574    
575            /**
576            * Deletes the temporary file entry.
577            *
578            * @param groupId the primary key of the group
579            * @param folderId the primary key of the folder where the file entry was
580            eventually to reside
581            * @param fileName the file's original name
582            * @param tempFolderName the temporary folder's name
583            * @throws PortalException if the file name was invalid
584            * @throws SystemException if a system exception occurred
585            * @see com.liferay.portal.kernel.util.TempFileUtil
586            */
587            public static void deleteTempFileEntry(long groupId, long folderId,
588                    java.lang.String fileName, java.lang.String tempFolderName)
589                    throws com.liferay.portal.kernel.exception.PortalException,
590                            com.liferay.portal.kernel.exception.SystemException {
591                    getService()
592                            .deleteTempFileEntry(groupId, folderId, fileName, tempFolderName);
593            }
594    
595            /**
596            * Returns all the file entries in the folder.
597            *
598            * @param repositoryId the primary key of the file entry's repository
599            * @param folderId the primary key of the file entry's folder
600            * @return the file entries in the folder
601            * @throws PortalException if the folder could not be found
602            * @throws SystemException if a system exception occurred
603            */
604            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
605                    long repositoryId, long folderId)
606                    throws com.liferay.portal.kernel.exception.PortalException,
607                            com.liferay.portal.kernel.exception.SystemException {
608                    return getService().getFileEntries(repositoryId, folderId);
609            }
610    
611            /**
612            * Returns a range of all the file entries in the folder.
613            *
614            * <p>
615            * Useful when paginating results. Returns a maximum of <code>end -
616            * start</code> instances. <code>start</code> and <code>end</code> are not
617            * primary keys, they are indexes in the result set. Thus, <code>0</code>
618            * refers to the first result in the set. Setting both <code>start</code>
619            * and <code>end</code> to {@link
620            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
621            * result set.
622            * </p>
623            *
624            * @param repositoryId the primary key of the file entry's repository
625            * @param folderId the primary key of the file entry's folder
626            * @param start the lower bound of the range of results
627            * @param end the upper bound of the range of results (not inclusive)
628            * @return the range of file entries in the folder
629            * @throws PortalException if the folder could not be found
630            * @throws SystemException if a system exception occurred
631            */
632            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
633                    long repositoryId, long folderId, int start, int end)
634                    throws com.liferay.portal.kernel.exception.PortalException,
635                            com.liferay.portal.kernel.exception.SystemException {
636                    return getService().getFileEntries(repositoryId, folderId, start, end);
637            }
638    
639            /**
640            * Returns an ordered range of all the file entries in the folder.
641            *
642            * <p>
643            * Useful when paginating results. Returns a maximum of <code>end -
644            * start</code> instances. <code>start</code> and <code>end</code> are not
645            * primary keys, they are indexes in the result set. Thus, <code>0</code>
646            * refers to the first result in the set. Setting both <code>start</code>
647            * and <code>end</code> to {@link
648            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
649            * result set.
650            * </p>
651            *
652            * @param repositoryId the primary key of the file entry's repository
653            * @param folderId the primary key of the file entry's folder
654            * @param start the lower bound of the range of results
655            * @param end the upper bound of the range of results (not inclusive)
656            * @param obc the comparator to order the file entries (optionally
657            <code>null</code>)
658            * @return the range of file entries in the folder ordered by comparator
659            <code>obc</code>
660            * @throws PortalException if the folder could not be found
661            * @throws SystemException if a system exception occurred
662            */
663            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
664                    long repositoryId, long folderId, int start, int end,
665                    com.liferay.portal.kernel.util.OrderByComparator obc)
666                    throws com.liferay.portal.kernel.exception.PortalException,
667                            com.liferay.portal.kernel.exception.SystemException {
668                    return getService()
669                                       .getFileEntries(repositoryId, folderId, start, end, obc);
670            }
671    
672            /**
673            * Returns the file entries with the file entry type in the folder.
674            *
675            * @param repositoryId the primary key of the file entry's repository
676            * @param folderId the primary key of the file entry's folder
677            * @param fileEntryTypeId the primary key of the file entry type
678            * @return the file entries with the file entry type in the folder
679            * @throws PortalException if the folder could not be found
680            * @throws SystemException if a system exception occurred
681            */
682            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
683                    long repositoryId, long folderId, long fileEntryTypeId)
684                    throws com.liferay.portal.kernel.exception.PortalException,
685                            com.liferay.portal.kernel.exception.SystemException {
686                    return getService()
687                                       .getFileEntries(repositoryId, folderId, fileEntryTypeId);
688            }
689    
690            /**
691            * Returns a range of all the file entries with the file entry type in the
692            * folder.
693            *
694            * @param repositoryId the primary key of the file entry's repository
695            * @param folderId the primary key of the file entry's folder
696            * @param fileEntryTypeId the primary key of the file entry type
697            * @param start the lower bound of the range of results
698            * @param end the upper bound of the range of results (not inclusive)
699            * @return the file entries in the folder
700            * @throws PortalException if the folder could not be found
701            * @throws SystemException if a system exception occurred
702            */
703            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
704                    long repositoryId, long folderId, long fileEntryTypeId, int start,
705                    int end)
706                    throws com.liferay.portal.kernel.exception.PortalException,
707                            com.liferay.portal.kernel.exception.SystemException {
708                    return getService()
709                                       .getFileEntries(repositoryId, folderId, fileEntryTypeId,
710                            start, end);
711            }
712    
713            /**
714            * Returns an ordered range of all the file entries with the file entry type
715            * in the folder.
716            *
717            * @param repositoryId the primary key of the repository
718            * @param folderId the primary key of the folder
719            * @param fileEntryTypeId the primary key of the file entry type
720            * @param start the lower bound of the range of results
721            * @param end the upper bound of the range of results (not inclusive)
722            * @param obc the comparator to order the results by (optionally
723            <code>null</code>)
724            * @return the range of file entries with the file entry type in the folder
725            ordered by <code>null</code>
726            * @throws PortalException if the folder could not be found
727            * @throws SystemException if a system exception occurred
728            */
729            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
730                    long repositoryId, long folderId, long fileEntryTypeId, int start,
731                    int end, com.liferay.portal.kernel.util.OrderByComparator obc)
732                    throws com.liferay.portal.kernel.exception.PortalException,
733                            com.liferay.portal.kernel.exception.SystemException {
734                    return getService()
735                                       .getFileEntries(repositoryId, folderId, fileEntryTypeId,
736                            start, end, obc);
737            }
738    
739            /**
740            * Returns a range of all the file entries and shortcuts in the folder.
741            *
742            * <p>
743            * Useful when paginating results. Returns a maximum of <code>end -
744            * start</code> instances. <code>start</code> and <code>end</code> are not
745            * primary keys, they are indexes in the result set. Thus, <code>0</code>
746            * refers to the first result in the set. Setting both <code>start</code>
747            * and <code>end</code> to {@link
748            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
749            * result set.
750            * </p>
751            *
752            * @param repositoryId the primary key of the repository
753            * @param folderId the primary key of the folder
754            * @param status the workflow status
755            * @param start the lower bound of the range of results
756            * @param end the upper bound of the range of results (not inclusive)
757            * @return the range of file entries and shortcuts in the folder
758            * @throws PortalException if the folder could not be found
759            * @throws SystemException if a system exception occurred
760            */
761            public static java.util.List<java.lang.Object> getFileEntriesAndFileShortcuts(
762                    long repositoryId, long folderId, int status, int start, int end)
763                    throws com.liferay.portal.kernel.exception.PortalException,
764                            com.liferay.portal.kernel.exception.SystemException {
765                    return getService()
766                                       .getFileEntriesAndFileShortcuts(repositoryId, folderId,
767                            status, start, end);
768            }
769    
770            /**
771            * Returns the number of file entries and shortcuts in the folder.
772            *
773            * @param repositoryId the primary key of the repository
774            * @param folderId the primary key of the folder
775            * @param status the workflow status
776            * @return the number of file entries and shortcuts in the folder
777            * @throws PortalException if the folder ould not be found
778            * @throws SystemException if a system exception occurred
779            */
780            public static int getFileEntriesAndFileShortcutsCount(long repositoryId,
781                    long folderId, int status)
782                    throws com.liferay.portal.kernel.exception.PortalException,
783                            com.liferay.portal.kernel.exception.SystemException {
784                    return getService()
785                                       .getFileEntriesAndFileShortcutsCount(repositoryId, folderId,
786                            status);
787            }
788    
789            /**
790            * Returns the number of file entries and shortcuts in the folder.
791            *
792            * @param repositoryId the primary key of the repository
793            * @param folderId the primary key of the folder
794            * @param status the workflow status
795            * @param mimeTypes allowed media types
796            * @return the number of file entries and shortcuts in the folder
797            * @throws PortalException if the folder ould not be found
798            * @throws SystemException if a system exception occurred
799            */
800            public static int getFileEntriesAndFileShortcutsCount(long repositoryId,
801                    long folderId, int status, java.lang.String[] mimeTypes)
802                    throws com.liferay.portal.kernel.exception.PortalException,
803                            com.liferay.portal.kernel.exception.SystemException {
804                    return getService()
805                                       .getFileEntriesAndFileShortcutsCount(repositoryId, folderId,
806                            status, mimeTypes);
807            }
808    
809            /**
810            * Returns the number of file entries in the folder.
811            *
812            * @param repositoryId the primary key of the file entry's repository
813            * @param folderId the primary key of the file entry's folder
814            * @return the number of file entries in the folder
815            * @throws PortalException if the folder could not be found
816            * @throws SystemException if a system exception occurred
817            */
818            public static int getFileEntriesCount(long repositoryId, long folderId)
819                    throws com.liferay.portal.kernel.exception.PortalException,
820                            com.liferay.portal.kernel.exception.SystemException {
821                    return getService().getFileEntriesCount(repositoryId, folderId);
822            }
823    
824            /**
825            * Returns the number of file entries with the file entry type in the
826            * folder.
827            *
828            * @param repositoryId the primary key of the file entry's repository
829            * @param folderId the primary key of the file entry's folder
830            * @param fileEntryTypeId the primary key of the file entry type
831            * @return the number of file entries with the file entry type in the folder
832            * @throws PortalException if the folder could not be found
833            * @throws SystemException if a system exception occurred
834            */
835            public static int getFileEntriesCount(long repositoryId, long folderId,
836                    long fileEntryTypeId)
837                    throws com.liferay.portal.kernel.exception.PortalException,
838                            com.liferay.portal.kernel.exception.SystemException {
839                    return getService()
840                                       .getFileEntriesCount(repositoryId, folderId, fileEntryTypeId);
841            }
842    
843            /**
844            * Returns the file entry with the primary key.
845            *
846            * @param fileEntryId the primary key of the file entry
847            * @return the file entry with the primary key
848            * @throws PortalException if the file entry could not be found
849            * @throws SystemException if a system exception occurred
850            */
851            public static com.liferay.portal.kernel.repository.model.FileEntry getFileEntry(
852                    long fileEntryId)
853                    throws com.liferay.portal.kernel.exception.PortalException,
854                            com.liferay.portal.kernel.exception.SystemException {
855                    return getService().getFileEntry(fileEntryId);
856            }
857    
858            /**
859            * Returns the file entry with the title in the folder.
860            *
861            * @param groupId the primary key of the file entry's group
862            * @param folderId the primary key of the file entry's folder
863            * @param title the file entry's title
864            * @return the file entry with the title in the folder
865            * @throws PortalException if the file entry could not be found
866            * @throws SystemException if a system exception occurred
867            */
868            public static com.liferay.portal.kernel.repository.model.FileEntry getFileEntry(
869                    long groupId, long folderId, java.lang.String title)
870                    throws com.liferay.portal.kernel.exception.PortalException,
871                            com.liferay.portal.kernel.exception.SystemException {
872                    return getService().getFileEntry(groupId, folderId, title);
873            }
874    
875            /**
876            * Returns the file entry with the UUID and group.
877            *
878            * @param uuid the file entry's universally unique identifier
879            * @param groupId the primary key of the file entry's group
880            * @return the file entry with the UUID and group
881            * @throws PortalException if the file entry could not be found
882            * @throws SystemException if a system exception occurred
883            */
884            public static com.liferay.portal.kernel.repository.model.FileEntry getFileEntryByUuidAndGroupId(
885                    java.lang.String uuid, long groupId)
886                    throws com.liferay.portal.kernel.exception.PortalException,
887                            com.liferay.portal.kernel.exception.SystemException {
888                    return getService().getFileEntryByUuidAndGroupId(uuid, groupId);
889            }
890    
891            /**
892            * Returns the file shortcut with the primary key. This method is only
893            * supported by the Liferay repository.
894            *
895            * @param fileShortcutId the primary key of the file shortcut
896            * @return the file shortcut with the primary key
897            * @throws PortalException if the file shortcut could not be found
898            * @throws SystemException if a system exception occurred
899            */
900            public static com.liferay.portlet.documentlibrary.model.DLFileShortcut getFileShortcut(
901                    long fileShortcutId)
902                    throws com.liferay.portal.kernel.exception.PortalException,
903                            com.liferay.portal.kernel.exception.SystemException {
904                    return getService().getFileShortcut(fileShortcutId);
905            }
906    
907            /**
908            * Returns the folder with the primary key.
909            *
910            * @param folderId the primary key of the folder
911            * @return the folder with the primary key
912            * @throws PortalException if the folder could not be found
913            * @throws SystemException if a system exception occurred
914            */
915            public static com.liferay.portal.kernel.repository.model.Folder getFolder(
916                    long folderId)
917                    throws com.liferay.portal.kernel.exception.PortalException,
918                            com.liferay.portal.kernel.exception.SystemException {
919                    return getService().getFolder(folderId);
920            }
921    
922            /**
923            * Returns the folder with the name in the parent folder.
924            *
925            * @param repositoryId the primary key of the folder's repository
926            * @param parentFolderId the primary key of the folder's parent folder
927            * @param name the folder's name
928            * @return the folder with the name in the parent folder
929            * @throws PortalException if the folder could not be found
930            * @throws SystemException if a system exception occurred
931            */
932            public static com.liferay.portal.kernel.repository.model.Folder getFolder(
933                    long repositoryId, long parentFolderId, java.lang.String name)
934                    throws com.liferay.portal.kernel.exception.PortalException,
935                            com.liferay.portal.kernel.exception.SystemException {
936                    return getService().getFolder(repositoryId, parentFolderId, name);
937            }
938    
939            /**
940            * Returns all immediate subfolders of the parent folder.
941            *
942            * @param repositoryId the primary key of the folder's repository
943            * @param parentFolderId the primary key of the folder's parent folder
944            * @return the immediate subfolders of the parent folder
945            * @throws PortalException if the parent folder could not be found
946            * @throws SystemException if a system exception occurred
947            */
948            public static java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
949                    long repositoryId, long parentFolderId)
950                    throws com.liferay.portal.kernel.exception.PortalException,
951                            com.liferay.portal.kernel.exception.SystemException {
952                    return getService().getFolders(repositoryId, parentFolderId);
953            }
954    
955            /**
956            * Returns all immediate subfolders of the parent folder, optionally
957            * including mount folders for third-party repositories.
958            *
959            * @param repositoryId the primary key of the folder's repository
960            * @param parentFolderId the primary key of the folder's parent folder
961            * @param includeMountFolders whether to include mount folders for
962            third-party repositories
963            * @return the immediate subfolders of the parent folder
964            * @throws PortalException if the parent folder could not be found
965            * @throws SystemException if a system exception occurred
966            */
967            public static java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
968                    long repositoryId, long parentFolderId, boolean includeMountFolders)
969                    throws com.liferay.portal.kernel.exception.PortalException,
970                            com.liferay.portal.kernel.exception.SystemException {
971                    return getService()
972                                       .getFolders(repositoryId, parentFolderId, includeMountFolders);
973            }
974    
975            /**
976            * Returns a range of all the immediate subfolders of the parent folder,
977            * optionally including mount folders for third-party repositories.
978            *
979            * <p>
980            * Useful when paginating results. Returns a maximum of <code>end -
981            * start</code> instances. <code>start</code> and <code>end</code> are not
982            * primary keys, they are indexes in the result set. Thus, <code>0</code>
983            * refers to the first result in the set. Setting both <code>start</code>
984            * and <code>end</code> to {@link
985            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
986            * result set.
987            * </p>
988            *
989            * @param repositoryId the primary key of the folder's repository
990            * @param parentFolderId the primary key of the folder's parent folder
991            * @param includeMountFolders whether to include mount folders for
992            third-party repositories
993            * @param start the lower bound of the range of results
994            * @param end the upper bound of the range of results (not inclusive)
995            * @return the range of immediate subfolders of the parent folder
996            * @throws PortalException if the parent folder could not be found
997            * @throws SystemException if a system exception occurred
998            */
999            public static java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
1000                    long repositoryId, long parentFolderId, boolean includeMountFolders,
1001                    int start, int end)
1002                    throws com.liferay.portal.kernel.exception.PortalException,
1003                            com.liferay.portal.kernel.exception.SystemException {
1004                    return getService()
1005                                       .getFolders(repositoryId, parentFolderId,
1006                            includeMountFolders, start, end);
1007            }
1008    
1009            /**
1010            * Returns an ordered range of all the immediate subfolders of the parent
1011            * folder.
1012            *
1013            * <p>
1014            * Useful when paginating results. Returns a maximum of <code>end -
1015            * start</code> instances. <code>start</code> and <code>end</code> are not
1016            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1017            * refers to the first result in the set. Setting both <code>start</code>
1018            * and <code>end</code> to {@link
1019            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1020            * result set.
1021            * </p>
1022            *
1023            * @param repositoryId the primary key of the folder's repository
1024            * @param parentFolderId the primary key of the folder's parent folder
1025            * @param includeMountFolders whether to include mount folders for
1026            third-party repositories
1027            * @param start the lower bound of the range of results
1028            * @param end the upper bound of the range of results (not inclusive)
1029            * @param obc the comparator to order the folders (optionally
1030            <code>null</code>)
1031            * @return the range of immediate subfolders of the parent folder ordered by
1032            comparator <code>obc</code>
1033            * @throws PortalException if the parent folder could not be found
1034            * @throws SystemException if a system exception occurred
1035            */
1036            public static java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
1037                    long repositoryId, long parentFolderId, boolean includeMountFolders,
1038                    int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
1039                    throws com.liferay.portal.kernel.exception.PortalException,
1040                            com.liferay.portal.kernel.exception.SystemException {
1041                    return getService()
1042                                       .getFolders(repositoryId, parentFolderId,
1043                            includeMountFolders, start, end, obc);
1044            }
1045    
1046            /**
1047            * Returns an ordered range of all the immediate subfolders of the parent
1048            * folder.
1049            *
1050            * <p>
1051            * Useful when paginating results. Returns a maximum of <code>end -
1052            * start</code> instances. <code>start</code> and <code>end</code> are not
1053            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1054            * refers to the first result in the set. Setting both <code>start</code>
1055            * and <code>end</code> to {@link
1056            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1057            * result set.
1058            * </p>
1059            *
1060            * @param repositoryId the primary key of the folder's repository
1061            * @param parentFolderId the primary key of the folder's parent folder
1062            * @param status the workflow status
1063            * @param includeMountFolders whether to include mount folders for
1064            third-party repositories
1065            * @param start the lower bound of the range of results
1066            * @param end the upper bound of the range of results (not inclusive)
1067            * @param obc the comparator to order the folders (optionally
1068            <code>null</code>)
1069            * @return the range of immediate subfolders of the parent folder ordered by
1070            comparator <code>obc</code>
1071            * @throws PortalException if the parent folder could not be found
1072            * @throws SystemException if a system exception occurred
1073            */
1074            public static java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
1075                    long repositoryId, long parentFolderId, int status,
1076                    boolean includeMountFolders, int start, int end,
1077                    com.liferay.portal.kernel.util.OrderByComparator obc)
1078                    throws com.liferay.portal.kernel.exception.PortalException,
1079                            com.liferay.portal.kernel.exception.SystemException {
1080                    return getService()
1081                                       .getFolders(repositoryId, parentFolderId, status,
1082                            includeMountFolders, start, end, obc);
1083            }
1084    
1085            /**
1086            * Returns a range of all the immediate subfolders of the parent folder.
1087            *
1088            * <p>
1089            * Useful when paginating results. Returns a maximum of <code>end -
1090            * start</code> instances. <code>start</code> and <code>end</code> are not
1091            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1092            * refers to the first result in the set. Setting both <code>start</code>
1093            * and <code>end</code> to {@link
1094            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1095            * result set.
1096            * </p>
1097            *
1098            * @param repositoryId the primary key of the folder's repository
1099            * @param parentFolderId the primary key of the folder's parent folder
1100            * @param start the lower bound of the range of results
1101            * @param end the upper bound of the range of results (not inclusive)
1102            * @return the range of immediate subfolders of the parent folder
1103            * @throws PortalException if the parent folder could not be found
1104            * @throws SystemException if a system exception occurred
1105            */
1106            public static java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
1107                    long repositoryId, long parentFolderId, int start, int end)
1108                    throws com.liferay.portal.kernel.exception.PortalException,
1109                            com.liferay.portal.kernel.exception.SystemException {
1110                    return getService().getFolders(repositoryId, parentFolderId, start, end);
1111            }
1112    
1113            /**
1114            * Returns an ordered range of all the immediate subfolders of the parent
1115            * folder.
1116            *
1117            * <p>
1118            * Useful when paginating results. Returns a maximum of <code>end -
1119            * start</code> instances. <code>start</code> and <code>end</code> are not
1120            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1121            * refers to the first result in the set. Setting both <code>start</code>
1122            * and <code>end</code> to {@link
1123            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1124            * result set.
1125            * </p>
1126            *
1127            * @param repositoryId the primary key of the folder's repository
1128            * @param parentFolderId the primary key of the folder's parent folder
1129            * @param start the lower bound of the range of results
1130            * @param end the upper bound of the range of results (not inclusive)
1131            * @param obc the comparator to order the folders (optionally
1132            <code>null</code>)
1133            * @return the range of immediate subfolders of the parent folder ordered by
1134            comparator <code>obc</code>
1135            * @throws PortalException if the parent folder could not be found
1136            * @throws SystemException if a system exception occurred
1137            */
1138            public static java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
1139                    long repositoryId, long parentFolderId, int start, int end,
1140                    com.liferay.portal.kernel.util.OrderByComparator obc)
1141                    throws com.liferay.portal.kernel.exception.PortalException,
1142                            com.liferay.portal.kernel.exception.SystemException {
1143                    return getService()
1144                                       .getFolders(repositoryId, parentFolderId, start, end, obc);
1145            }
1146    
1147            /**
1148            * Returns a range of all the immediate subfolders, file entries, and file
1149            * shortcuts in the parent folder.
1150            *
1151            * <p>
1152            * Useful when paginating results. Returns a maximum of <code>end -
1153            * start</code> instances. <code>start</code> and <code>end</code> are not
1154            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1155            * refers to the first result in the set. Setting both <code>start</code>
1156            * and <code>end</code> to {@link
1157            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1158            * result set.
1159            * </p>
1160            *
1161            * @param repositoryId the primary key of the repository
1162            * @param folderId the primary key of the parent folder
1163            * @param status the workflow status
1164            * @param includeMountFolders whether to include mount folders for
1165            third-party repositories
1166            * @param start the lower bound of the range of results
1167            * @param end the upper bound of the range of results (not inclusive)
1168            * @return the range of immediate subfolders, file entries, and file
1169            shortcuts in the parent folder ordered by comparator
1170            <code>obc</code>
1171            * @throws PortalException if the parent folder could not be found
1172            * @throws SystemException if a system exception occurred
1173            */
1174            public static java.util.List<java.lang.Object> getFoldersAndFileEntriesAndFileShortcuts(
1175                    long repositoryId, long folderId, int status,
1176                    boolean includeMountFolders, int start, int end)
1177                    throws com.liferay.portal.kernel.exception.PortalException,
1178                            com.liferay.portal.kernel.exception.SystemException {
1179                    return getService()
1180                                       .getFoldersAndFileEntriesAndFileShortcuts(repositoryId,
1181                            folderId, status, includeMountFolders, start, end);
1182            }
1183    
1184            /**
1185            * Returns an ordered range of all the immediate subfolders, file entries,
1186            * and file shortcuts in the parent folder.
1187            *
1188            * <p>
1189            * Useful when paginating results. Returns a maximum of <code>end -
1190            * start</code> instances. <code>start</code> and <code>end</code> are not
1191            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1192            * refers to the first result in the set. Setting both <code>start</code>
1193            * and <code>end</code> to {@link
1194            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1195            * result set.
1196            * </p>
1197            *
1198            * @param repositoryId the primary key of the repository
1199            * @param folderId the primary key of the parent folder
1200            * @param status the workflow status
1201            * @param includeMountFolders whether to include mount folders for
1202            third-party repositories
1203            * @param start the lower bound of the range of results
1204            * @param end the upper bound of the range of results (not inclusive)
1205            * @param obc the comparator to order the results (optionally
1206            <code>null</code>)
1207            * @return the range of immediate subfolders, file entries, and file
1208            shortcuts in the parent folder ordered by comparator
1209            <code>obc</code>
1210            * @throws PortalException if the parent folder could not be found
1211            * @throws SystemException if a system exception occurred
1212            */
1213            public static java.util.List<java.lang.Object> getFoldersAndFileEntriesAndFileShortcuts(
1214                    long repositoryId, long folderId, int status,
1215                    boolean includeMountFolders, int start, int end,
1216                    com.liferay.portal.kernel.util.OrderByComparator obc)
1217                    throws com.liferay.portal.kernel.exception.PortalException,
1218                            com.liferay.portal.kernel.exception.SystemException {
1219                    return getService()
1220                                       .getFoldersAndFileEntriesAndFileShortcuts(repositoryId,
1221                            folderId, status, includeMountFolders, start, end, obc);
1222            }
1223    
1224            public static java.util.List<java.lang.Object> getFoldersAndFileEntriesAndFileShortcuts(
1225                    long repositoryId, long folderId, int status,
1226                    java.lang.String[] mimeTypes, boolean includeMountFolders, int start,
1227                    int end, com.liferay.portal.kernel.util.OrderByComparator obc)
1228                    throws com.liferay.portal.kernel.exception.PortalException,
1229                            com.liferay.portal.kernel.exception.SystemException {
1230                    return getService()
1231                                       .getFoldersAndFileEntriesAndFileShortcuts(repositoryId,
1232                            folderId, status, mimeTypes, includeMountFolders, start, end, obc);
1233            }
1234    
1235            /**
1236            * Returns the number of immediate subfolders, file entries, and file
1237            * shortcuts in the parent folder.
1238            *
1239            * @param repositoryId the primary key of the repository
1240            * @param folderId the primary key of the parent folder
1241            * @param status the workflow status
1242            * @param includeMountFolders whether to include mount folders for
1243            third-party repositories
1244            * @return the number of immediate subfolders, file entries, and file
1245            shortcuts in the parent folder
1246            * @throws PortalException if the folder could not be found
1247            * @throws SystemException if a system exception occurred
1248            */
1249            public static int getFoldersAndFileEntriesAndFileShortcutsCount(
1250                    long repositoryId, long folderId, int status,
1251                    boolean includeMountFolders)
1252                    throws com.liferay.portal.kernel.exception.PortalException,
1253                            com.liferay.portal.kernel.exception.SystemException {
1254                    return getService()
1255                                       .getFoldersAndFileEntriesAndFileShortcutsCount(repositoryId,
1256                            folderId, status, includeMountFolders);
1257            }
1258    
1259            public static int getFoldersAndFileEntriesAndFileShortcutsCount(
1260                    long repositoryId, long folderId, int status,
1261                    java.lang.String[] mimeTypes, boolean includeMountFolders)
1262                    throws com.liferay.portal.kernel.exception.PortalException,
1263                            com.liferay.portal.kernel.exception.SystemException {
1264                    return getService()
1265                                       .getFoldersAndFileEntriesAndFileShortcutsCount(repositoryId,
1266                            folderId, status, mimeTypes, includeMountFolders);
1267            }
1268    
1269            /**
1270            * Returns the number of immediate subfolders of the parent folder.
1271            *
1272            * @param repositoryId the primary key of the folder's repository
1273            * @param parentFolderId the primary key of the folder's parent folder
1274            * @return the number of immediate subfolders of the parent folder
1275            * @throws PortalException if the parent folder could not be found
1276            * @throws SystemException if a system exception occurred
1277            */
1278            public static int getFoldersCount(long repositoryId, long parentFolderId)
1279                    throws com.liferay.portal.kernel.exception.PortalException,
1280                            com.liferay.portal.kernel.exception.SystemException {
1281                    return getService().getFoldersCount(repositoryId, parentFolderId);
1282            }
1283    
1284            /**
1285            * Returns the number of immediate subfolders of the parent folder,
1286            * optionally including mount folders for third-party repositories.
1287            *
1288            * @param repositoryId the primary key of the folder's repository
1289            * @param parentFolderId the primary key of the folder's parent folder
1290            * @param includeMountFolders whether to include mount folders for
1291            third-party repositories
1292            * @return the number of immediate subfolders of the parent folder
1293            * @throws PortalException if the parent folder could not be found
1294            * @throws SystemException if a system exception occurred
1295            */
1296            public static int getFoldersCount(long repositoryId, long parentFolderId,
1297                    boolean includeMountFolders)
1298                    throws com.liferay.portal.kernel.exception.PortalException,
1299                            com.liferay.portal.kernel.exception.SystemException {
1300                    return getService()
1301                                       .getFoldersCount(repositoryId, parentFolderId,
1302                            includeMountFolders);
1303            }
1304    
1305            /**
1306            * Returns the number of immediate subfolders of the parent folder,
1307            * optionally including mount folders for third-party repositories.
1308            *
1309            * @param repositoryId the primary key of the folder's repository
1310            * @param parentFolderId the primary key of the folder's parent folder
1311            * @param status the workflow status
1312            * @param includeMountFolders whether to include mount folders for
1313            third-party repositories
1314            * @return the number of immediate subfolders of the parent folder
1315            * @throws PortalException if the parent folder could not be found
1316            * @throws SystemException if a system exception occurred
1317            */
1318            public static int getFoldersCount(long repositoryId, long parentFolderId,
1319                    int status, boolean includeMountFolders)
1320                    throws com.liferay.portal.kernel.exception.PortalException,
1321                            com.liferay.portal.kernel.exception.SystemException {
1322                    return getService()
1323                                       .getFoldersCount(repositoryId, parentFolderId, status,
1324                            includeMountFolders);
1325            }
1326    
1327            /**
1328            * Returns the number of immediate subfolders and file entries across the
1329            * folders.
1330            *
1331            * @param repositoryId the primary key of the repository
1332            * @param folderIds the primary keys of folders from which to count
1333            immediate subfolders and file entries
1334            * @param status the workflow status
1335            * @return the number of immediate subfolders and file entries across the
1336            folders
1337            * @throws PortalException if the repository could not be found
1338            * @throws SystemException if a system exception occurred
1339            */
1340            public static int getFoldersFileEntriesCount(long repositoryId,
1341                    java.util.List<java.lang.Long> folderIds, int status)
1342                    throws com.liferay.portal.kernel.exception.PortalException,
1343                            com.liferay.portal.kernel.exception.SystemException {
1344                    return getService()
1345                                       .getFoldersFileEntriesCount(repositoryId, folderIds, status);
1346            }
1347    
1348            /**
1349            * Returns an ordered range of all the file entries in the group starting at
1350            * the repository default parent folder that are stored within the Liferay
1351            * repository. This method is primarily used to search for recently modified
1352            * file entries. It can be limited to the file entries modified by a given
1353            * user.
1354            *
1355            * <p>
1356            * Useful when paginating results. Returns a maximum of <code>end -
1357            * start</code> instances. <code>start</code> and <code>end</code> are not
1358            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1359            * refers to the first result in the set. Setting both <code>start</code>
1360            * and <code>end</code> to {@link
1361            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1362            * result set.
1363            * </p>
1364            *
1365            * @param groupId the primary key of the group
1366            * @param userId the primary key of the user who created the file
1367            (optionally <code>0</code>)
1368            * @param start the lower bound of the range of results
1369            * @param end the upper bound of the range of results (not inclusive)
1370            * @return the range of matching file entries ordered by date modified
1371            * @throws PortalException if the group could not be found
1372            * @throws SystemException if a system exception occurred
1373            */
1374            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getGroupFileEntries(
1375                    long groupId, long userId, int start, int end)
1376                    throws com.liferay.portal.kernel.exception.PortalException,
1377                            com.liferay.portal.kernel.exception.SystemException {
1378                    return getService().getGroupFileEntries(groupId, userId, start, end);
1379            }
1380    
1381            /**
1382            * Returns an ordered range of all the file entries in the group that are
1383            * stored within the Liferay repository. This method is primarily used to
1384            * search for recently modified file entries. It can be limited to the file
1385            * entries modified by a given user.
1386            *
1387            * <p>
1388            * Useful when paginating results. Returns a maximum of <code>end -
1389            * start</code> instances. <code>start</code> and <code>end</code> are not
1390            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1391            * refers to the first result in the set. Setting both <code>start</code>
1392            * and <code>end</code> to {@link
1393            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1394            * result set.
1395            * </p>
1396            *
1397            * @param groupId the primary key of the group
1398            * @param userId the primary key of the user who created the file
1399            (optionally <code>0</code>)
1400            * @param start the lower bound of the range of results
1401            * @param end the upper bound of the range of results (not inclusive)
1402            * @param obc the comparator to order the file entries (optionally
1403            <code>null</code>)
1404            * @return the range of matching file entries ordered by comparator
1405            <code>obc</code>
1406            * @throws PortalException if the group could not be found
1407            * @throws SystemException if a system exception occurred
1408            */
1409            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getGroupFileEntries(
1410                    long groupId, long userId, int start, int end,
1411                    com.liferay.portal.kernel.util.OrderByComparator obc)
1412                    throws com.liferay.portal.kernel.exception.PortalException,
1413                            com.liferay.portal.kernel.exception.SystemException {
1414                    return getService().getGroupFileEntries(groupId, userId, start, end, obc);
1415            }
1416    
1417            /**
1418            * Returns an ordered range of all the file entries in the group starting at
1419            * the root folder that are stored within the Liferay repository. This
1420            * method is primarily used to search for recently modified file entries. It
1421            * can be limited to the file entries modified by a given user.
1422            *
1423            * <p>
1424            * Useful when paginating results. Returns a maximum of <code>end -
1425            * start</code> instances. <code>start</code> and <code>end</code> are not
1426            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1427            * refers to the first result in the set. Setting both <code>start</code>
1428            * and <code>end</code> to {@link
1429            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1430            * result set.
1431            * </p>
1432            *
1433            * @param groupId the primary key of the group
1434            * @param userId the primary key of the user who created the file
1435            (optionally <code>0</code>)
1436            * @param rootFolderId the primary key of the root folder to begin the
1437            search
1438            * @param start the lower bound of the range of results
1439            * @param end the upper bound of the range of results (not inclusive)
1440            * @return the range of matching file entries ordered by date modified
1441            * @throws PortalException if the group could not be found
1442            * @throws SystemException if a system exception occurred
1443            */
1444            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getGroupFileEntries(
1445                    long groupId, long userId, long rootFolderId, int start, int end)
1446                    throws com.liferay.portal.kernel.exception.PortalException,
1447                            com.liferay.portal.kernel.exception.SystemException {
1448                    return getService()
1449                                       .getGroupFileEntries(groupId, userId, rootFolderId, start,
1450                            end);
1451            }
1452    
1453            /**
1454            * Returns an ordered range of all the file entries in the group starting at
1455            * the root folder that are stored within the Liferay repository. This
1456            * method is primarily used to search for recently modified file entries. It
1457            * can be limited to the file entries modified by a given user.
1458            *
1459            * <p>
1460            * Useful when paginating results. Returns a maximum of <code>end -
1461            * start</code> instances. <code>start</code> and <code>end</code> are not
1462            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1463            * refers to the first result in the set. Setting both <code>start</code>
1464            * and <code>end</code> to {@link
1465            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1466            * result set.
1467            * </p>
1468            *
1469            * @param groupId the primary key of the group
1470            * @param userId the primary key of the user who created the file
1471            (optionally <code>0</code>)
1472            * @param rootFolderId the primary key of the root folder to begin the
1473            search
1474            * @param start the lower bound of the range of results
1475            * @param end the upper bound of the range of results (not inclusive)
1476            * @param obc the comparator to order the file entries (optionally
1477            <code>null</code>)
1478            * @return the range of matching file entries ordered by comparator
1479            <code>obc</code>
1480            * @throws PortalException if the group could not be found
1481            * @throws SystemException if a system exception occurred
1482            */
1483            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getGroupFileEntries(
1484                    long groupId, long userId, long rootFolderId, int start, int end,
1485                    com.liferay.portal.kernel.util.OrderByComparator obc)
1486                    throws com.liferay.portal.kernel.exception.PortalException,
1487                            com.liferay.portal.kernel.exception.SystemException {
1488                    return getService()
1489                                       .getGroupFileEntries(groupId, userId, rootFolderId, start,
1490                            end, obc);
1491            }
1492    
1493            public static java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getGroupFileEntries(
1494                    long groupId, long userId, long rootFolderId,
1495                    java.lang.String[] mimeTypes, int status, int start, int end,
1496                    com.liferay.portal.kernel.util.OrderByComparator obc)
1497                    throws com.liferay.portal.kernel.exception.PortalException,
1498                            com.liferay.portal.kernel.exception.SystemException {
1499                    return getService()
1500                                       .getGroupFileEntries(groupId, userId, rootFolderId,
1501                            mimeTypes, status, start, end, obc);
1502            }
1503    
1504            /**
1505            * Returns the number of file entries in a group starting at the repository
1506            * default parent folder that are stored within the Liferay repository. This
1507            * method is primarily used to search for recently modified file entries. It
1508            * can be limited to the file entries modified by a given user.
1509            *
1510            * @param groupId the primary key of the group
1511            * @param userId the primary key of the user who created the file
1512            (optionally <code>0</code>)
1513            * @return the number of matching file entries
1514            * @throws PortalException if the group could not be found
1515            * @throws SystemException if a system exception occurred
1516            */
1517            public static int getGroupFileEntriesCount(long groupId, long userId)
1518                    throws com.liferay.portal.kernel.exception.PortalException,
1519                            com.liferay.portal.kernel.exception.SystemException {
1520                    return getService().getGroupFileEntriesCount(groupId, userId);
1521            }
1522    
1523            /**
1524            * Returns the number of file entries in a group starting at the root folder
1525            * that are stored within the Liferay repository. This method is primarily
1526            * used to search for recently modified file entries. It can be limited to
1527            * the file entries modified by a given user.
1528            *
1529            * @param groupId the primary key of the group
1530            * @param userId the primary key of the user who created the file
1531            (optionally <code>0</code>)
1532            * @param rootFolderId the primary key of the root folder to begin the
1533            search
1534            * @return the number of matching file entries
1535            * @throws PortalException if the group could not be found
1536            * @throws SystemException if a system exception occurred
1537            */
1538            public static int getGroupFileEntriesCount(long groupId, long userId,
1539                    long rootFolderId)
1540                    throws com.liferay.portal.kernel.exception.PortalException,
1541                            com.liferay.portal.kernel.exception.SystemException {
1542                    return getService()
1543                                       .getGroupFileEntriesCount(groupId, userId, rootFolderId);
1544            }
1545    
1546            public static int getGroupFileEntriesCount(long groupId, long userId,
1547                    long rootFolderId, java.lang.String[] mimeTypes, int status)
1548                    throws com.liferay.portal.kernel.exception.PortalException,
1549                            com.liferay.portal.kernel.exception.SystemException {
1550                    return getService()
1551                                       .getGroupFileEntriesCount(groupId, userId, rootFolderId,
1552                            mimeTypes, status);
1553            }
1554    
1555            /**
1556            * Returns all immediate subfolders of the parent folder that are used for
1557            * mounting third-party repositories. This method is only supported by the
1558            * Liferay repository.
1559            *
1560            * @param repositoryId the primary key of the folder's repository
1561            * @param parentFolderId the primary key of the folder's parent folder
1562            * @return the immediate subfolders of the parent folder that are used for
1563            mounting third-party repositories
1564            * @throws PortalException if the repository or parent folder could not be
1565            found
1566            * @throws SystemException if a system exception occurred
1567            */
1568            public static java.util.List<com.liferay.portal.kernel.repository.model.Folder> getMountFolders(
1569                    long repositoryId, long parentFolderId)
1570                    throws com.liferay.portal.kernel.exception.PortalException,
1571                            com.liferay.portal.kernel.exception.SystemException {
1572                    return getService().getMountFolders(repositoryId, parentFolderId);
1573            }
1574    
1575            /**
1576            * Returns a range of all the immediate subfolders of the parent folder that
1577            * are used for mounting third-party repositories. This method is only
1578            * supported by the Liferay repository.
1579            *
1580            * <p>
1581            * Useful when paginating results. Returns a maximum of <code>end -
1582            * start</code> instances. <code>start</code> and <code>end</code> are not
1583            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1584            * refers to the first result in the set. Setting both <code>start</code>
1585            * and <code>end</code> to {@link
1586            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1587            * result set.
1588            * </p>
1589            *
1590            * @param repositoryId the primary key of the repository
1591            * @param parentFolderId the primary key of the parent folder
1592            * @param start the lower bound of the range of results
1593            * @param end the upper bound of the range of results (not inclusive)
1594            * @return the range of immediate subfolders of the parent folder that are
1595            used for mounting third-party repositories
1596            * @throws PortalException if the repository or parent folder could not be
1597            found
1598            * @throws SystemException if a system exception occurred
1599            */
1600            public static java.util.List<com.liferay.portal.kernel.repository.model.Folder> getMountFolders(
1601                    long repositoryId, long parentFolderId, int start, int end)
1602                    throws com.liferay.portal.kernel.exception.PortalException,
1603                            com.liferay.portal.kernel.exception.SystemException {
1604                    return getService()
1605                                       .getMountFolders(repositoryId, parentFolderId, start, end);
1606            }
1607    
1608            /**
1609            * Returns an ordered range of all the immediate subfolders of the parent
1610            * folder that are used for mounting third-party repositories. This method
1611            * is only supported by the Liferay repository.
1612            *
1613            * <p>
1614            * Useful when paginating results. Returns a maximum of <code>end -
1615            * start</code> instances. <code>start</code> and <code>end</code> are not
1616            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1617            * refers to the first result in the set. Setting both <code>start</code>
1618            * and <code>end</code> to {@link
1619            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1620            * result set.
1621            * </p>
1622            *
1623            * @param repositoryId the primary key of the folder's repository
1624            * @param parentFolderId the primary key of the folder's parent folder
1625            * @param start the lower bound of the range of results
1626            * @param end the upper bound of the range of results (not inclusive)
1627            * @param obc the comparator to order the folders (optionally
1628            <code>null</code>)
1629            * @return the range of immediate subfolders of the parent folder that are
1630            used for mounting third-party repositories ordered by comparator
1631            <code>obc</code>
1632            * @throws PortalException if the repository or parent folder could not be
1633            found
1634            * @throws SystemException if a system exception occurred
1635            */
1636            public static java.util.List<com.liferay.portal.kernel.repository.model.Folder> getMountFolders(
1637                    long repositoryId, long parentFolderId, int start, int end,
1638                    com.liferay.portal.kernel.util.OrderByComparator obc)
1639                    throws com.liferay.portal.kernel.exception.PortalException,
1640                            com.liferay.portal.kernel.exception.SystemException {
1641                    return getService()
1642                                       .getMountFolders(repositoryId, parentFolderId, start, end,
1643                            obc);
1644            }
1645    
1646            /**
1647            * Returns the number of immediate subfolders of the parent folder that are
1648            * used for mounting third-party repositories. This method is only supported
1649            * by the Liferay repository.
1650            *
1651            * @param repositoryId the primary key of the repository
1652            * @param parentFolderId the primary key of the parent folder
1653            * @return the number of folders of the parent folder that are used for
1654            mounting third-party repositories
1655            * @throws PortalException if the repository or parent folder could not be
1656            found
1657            * @throws SystemException if a system exception occurred
1658            */
1659            public static int getMountFoldersCount(long repositoryId,
1660                    long parentFolderId)
1661                    throws com.liferay.portal.kernel.exception.PortalException,
1662                            com.liferay.portal.kernel.exception.SystemException {
1663                    return getService().getMountFoldersCount(repositoryId, parentFolderId);
1664            }
1665    
1666            public static void getSubfolderIds(long repositoryId,
1667                    java.util.List<java.lang.Long> folderIds, long folderId)
1668                    throws com.liferay.portal.kernel.exception.PortalException,
1669                            com.liferay.portal.kernel.exception.SystemException {
1670                    getService().getSubfolderIds(repositoryId, folderIds, folderId);
1671            }
1672    
1673            /**
1674            * Returns all the descendant folders of the folder with the primary key.
1675            *
1676            * @param repositoryId the primary key of the repository
1677            * @param folderId the primary key of the folder
1678            * @return the descendant folders of the folder with the primary key
1679            * @throws PortalException if the repository or parent folder could not be
1680            found
1681            * @throws SystemException if a system exception occurred
1682            */
1683            public static java.util.List<java.lang.Long> getSubfolderIds(
1684                    long repositoryId, long folderId)
1685                    throws com.liferay.portal.kernel.exception.PortalException,
1686                            com.liferay.portal.kernel.exception.SystemException {
1687                    return getService().getSubfolderIds(repositoryId, folderId);
1688            }
1689    
1690            /**
1691            * Returns descendant folders of the folder with the primary key, optionally
1692            * limiting to one level deep.
1693            *
1694            * @param repositoryId the primary key of the repository
1695            * @param folderId the primary key of the folder
1696            * @param recurse whether to recurse through each subfolder
1697            * @return the descendant folders of the folder with the primary key
1698            * @throws PortalException if the repository or parent folder could not be
1699            found
1700            * @throws SystemException if a system exception occurred
1701            */
1702            public static java.util.List<java.lang.Long> getSubfolderIds(
1703                    long repositoryId, long folderId, boolean recurse)
1704                    throws com.liferay.portal.kernel.exception.PortalException,
1705                            com.liferay.portal.kernel.exception.SystemException {
1706                    return getService().getSubfolderIds(repositoryId, folderId, recurse);
1707            }
1708    
1709            /**
1710            * Returns all the temporary file entry names.
1711            *
1712            * @param groupId the primary key of the group
1713            * @param folderId the primary key of the folder where the file entry will
1714            eventually reside
1715            * @param tempFolderName the temporary folder's name
1716            * @return the temporary file entry names
1717            * @throws PortalException if the folder was invalid
1718            * @throws SystemException if a system exception occurred
1719            * @see com.liferay.portlet.documentlibrary.service.impl.DLAppServiceImpl#addTempFileEntry(
1720            long, long, String, String, File)
1721            * @see com.liferay.portal.kernel.util.TempFileUtil
1722            */
1723            public static java.lang.String[] getTempFileEntryNames(long groupId,
1724                    long folderId, java.lang.String tempFolderName)
1725                    throws com.liferay.portal.kernel.exception.PortalException,
1726                            com.liferay.portal.kernel.exception.SystemException {
1727                    return getService()
1728                                       .getTempFileEntryNames(groupId, folderId, tempFolderName);
1729            }
1730    
1731            /**
1732            * @deprecated {@link #checkOutFileEntry(long, ServiceContext)}
1733            */
1734            public static com.liferay.portal.model.Lock lockFileEntry(long fileEntryId)
1735                    throws com.liferay.portal.kernel.exception.PortalException,
1736                            com.liferay.portal.kernel.exception.SystemException {
1737                    return getService().lockFileEntry(fileEntryId);
1738            }
1739    
1740            /**
1741            * @deprecated {@link #checkOutFileEntry(long, String, long,
1742            ServiceContext)}
1743            */
1744            public static com.liferay.portal.model.Lock lockFileEntry(
1745                    long fileEntryId, java.lang.String owner, long expirationTime)
1746                    throws com.liferay.portal.kernel.exception.PortalException,
1747                            com.liferay.portal.kernel.exception.SystemException {
1748                    return getService().lockFileEntry(fileEntryId, owner, expirationTime);
1749            }
1750    
1751            /**
1752            * Locks the folder. This method is primarily used by WebDAV.
1753            *
1754            * @param repositoryId the primary key of the repository
1755            * @param folderId the primary key of the folder
1756            * @return the lock object
1757            * @throws PortalException if the repository or folder could not be found
1758            * @throws SystemException if a system exception occurred
1759            */
1760            public static com.liferay.portal.model.Lock lockFolder(long repositoryId,
1761                    long folderId)
1762                    throws com.liferay.portal.kernel.exception.PortalException,
1763                            com.liferay.portal.kernel.exception.SystemException {
1764                    return getService().lockFolder(repositoryId, folderId);
1765            }
1766    
1767            /**
1768            * Locks the folder. This method is primarily used by WebDAV.
1769            *
1770            * @param repositoryId the primary key of the repository
1771            * @param folderId the primary key of the folder
1772            * @param owner the owner string for the checkout (optionally
1773            <code>null</code>)
1774            * @param inheritable whether the lock must propagate to descendants
1775            * @param expirationTime the time in milliseconds before the lock expires.
1776            If the value is <code>0</code>, the default expiration time will
1777            be used from <code>portal.properties>.
1778            * @return the lock object
1779            * @throws PortalException if the repository or folder could not be found
1780            * @throws SystemException if a system exception occurred
1781            */
1782            public static com.liferay.portal.model.Lock lockFolder(long repositoryId,
1783                    long folderId, java.lang.String owner, boolean inheritable,
1784                    long expirationTime)
1785                    throws com.liferay.portal.kernel.exception.PortalException,
1786                            com.liferay.portal.kernel.exception.SystemException {
1787                    return getService()
1788                                       .lockFolder(repositoryId, folderId, owner, inheritable,
1789                            expirationTime);
1790            }
1791    
1792            /**
1793            * Moves the file entry to the new folder.
1794            *
1795            * @param fileEntryId the primary key of the file entry
1796            * @param newFolderId the primary key of the new folder
1797            * @param serviceContext the service context to be applied
1798            * @return the file entry
1799            * @throws PortalException if the file entry or the new folder could not be
1800            found
1801            * @throws SystemException if a system exception occurred
1802            */
1803            public static com.liferay.portal.kernel.repository.model.FileEntry moveFileEntry(
1804                    long fileEntryId, long newFolderId,
1805                    com.liferay.portal.service.ServiceContext serviceContext)
1806                    throws com.liferay.portal.kernel.exception.PortalException,
1807                            com.liferay.portal.kernel.exception.SystemException {
1808                    return getService()
1809                                       .moveFileEntry(fileEntryId, newFolderId, serviceContext);
1810            }
1811    
1812            /**
1813            * Moves the file entry from a trashed folder to the new folder.
1814            *
1815            * @param fileEntryId the primary key of the file entry
1816            * @param newFolderId the primary key of the new folder
1817            * @param serviceContext the service context to be applied
1818            * @return the file entry
1819            * @throws PortalException if the file entry or the new folder could not be
1820            found
1821            * @throws SystemException if a system exception occurred
1822            */
1823            public static com.liferay.portal.kernel.repository.model.FileEntry moveFileEntryFromTrash(
1824                    long fileEntryId, long newFolderId,
1825                    com.liferay.portal.service.ServiceContext serviceContext)
1826                    throws com.liferay.portal.kernel.exception.PortalException,
1827                            com.liferay.portal.kernel.exception.SystemException {
1828                    return getService()
1829                                       .moveFileEntryFromTrash(fileEntryId, newFolderId,
1830                            serviceContext);
1831            }
1832    
1833            /**
1834            * Moves the file entry with the primary key to the trash portlet.
1835            *
1836            * @param fileEntryId the primary key of the file entry
1837            * @throws PortalException if the file entry could not be found
1838            * @throws SystemException if a system exception occurred
1839            */
1840            public static com.liferay.portal.kernel.repository.model.FileEntry moveFileEntryToTrash(
1841                    long fileEntryId)
1842                    throws com.liferay.portal.kernel.exception.PortalException,
1843                            com.liferay.portal.kernel.exception.SystemException {
1844                    return getService().moveFileEntryToTrash(fileEntryId);
1845            }
1846    
1847            /**
1848            * Moves the file shortcut from a trashed folder to the new folder.
1849            *
1850            * @param fileShortcutId the primary key of the file shortcut
1851            * @param newFolderId the primary key of the new folder
1852            * @param serviceContext the service context to be applied
1853            * @return the file shortcut
1854            * @throws PortalException if the file entry or the new folder could not be
1855            found
1856            * @throws SystemException if a system exception occurred
1857            */
1858            public static com.liferay.portlet.documentlibrary.model.DLFileShortcut moveFileShortcutFromTrash(
1859                    long fileShortcutId, long newFolderId,
1860                    com.liferay.portal.service.ServiceContext serviceContext)
1861                    throws com.liferay.portal.kernel.exception.PortalException,
1862                            com.liferay.portal.kernel.exception.SystemException {
1863                    return getService()
1864                                       .moveFileShortcutFromTrash(fileShortcutId, newFolderId,
1865                            serviceContext);
1866            }
1867    
1868            /**
1869            * Moves the file shortcut with the primary key to the trash portlet.
1870            *
1871            * @param fileShortcutId the primary key of the file shortcut
1872            * @return the file shortcut
1873            * @throws PortalException if the file shortcut could not be found
1874            * @throws SystemException if a system exception occurred
1875            */
1876            public static com.liferay.portlet.documentlibrary.model.DLFileShortcut moveFileShortcutToTrash(
1877                    long fileShortcutId)
1878                    throws com.liferay.portal.kernel.exception.PortalException,
1879                            com.liferay.portal.kernel.exception.SystemException {
1880                    return getService().moveFileShortcutToTrash(fileShortcutId);
1881            }
1882    
1883            /**
1884            * Moves the folder to the new parent folder with the primary key.
1885            *
1886            * @param folderId the primary key of the folder
1887            * @param parentFolderId the primary key of the new parent folder
1888            * @param serviceContext the service context to be applied
1889            * @return the file entry
1890            * @throws PortalException if the folder could not be found
1891            * @throws SystemException if a system exception occurred
1892            */
1893            public static com.liferay.portal.kernel.repository.model.Folder moveFolder(
1894                    long folderId, long parentFolderId,
1895                    com.liferay.portal.service.ServiceContext serviceContext)
1896                    throws com.liferay.portal.kernel.exception.PortalException,
1897                            com.liferay.portal.kernel.exception.SystemException {
1898                    return getService().moveFolder(folderId, parentFolderId, serviceContext);
1899            }
1900    
1901            /**
1902            * Moves the folder with the primary key from the trash portlet to the new
1903            * parent folder with the primary key.
1904            *
1905            * @param folderId the primary key of the folder
1906            * @param parentFolderId the primary key of the new parent folder
1907            * @param serviceContext the service context to be applied
1908            * @return the file entry
1909            * @throws PortalException if the folder could not be found
1910            * @throws SystemException if a system exception occurred
1911            */
1912            public static com.liferay.portal.kernel.repository.model.Folder moveFolderFromTrash(
1913                    long folderId, long parentFolderId,
1914                    com.liferay.portal.service.ServiceContext serviceContext)
1915                    throws com.liferay.portal.kernel.exception.PortalException,
1916                            com.liferay.portal.kernel.exception.SystemException {
1917                    return getService()
1918                                       .moveFolderFromTrash(folderId, parentFolderId, serviceContext);
1919            }
1920    
1921            /**
1922            * Moves the folder with the primary key to the trash portlet.
1923            *
1924            * @param folderId the primary key of the folder
1925            * @throws PortalException if the folder could not be found
1926            * @throws SystemException if a system exception occurred
1927            */
1928            public static com.liferay.portal.kernel.repository.model.Folder moveFolderToTrash(
1929                    long folderId)
1930                    throws com.liferay.portal.kernel.exception.PortalException,
1931                            com.liferay.portal.kernel.exception.SystemException {
1932                    return getService().moveFolderToTrash(folderId);
1933            }
1934    
1935            /**
1936            * Refreshes the lock for the file entry. This method is primarily used by
1937            * WebDAV.
1938            *
1939            * @param lockUuid the lock's universally unique identifier
1940            * @param companyId the primary key of the file entry's company
1941            * @param expirationTime the time in milliseconds before the lock expires.
1942            If the value is <code>0</code>, the default expiration time will
1943            be used from <code>portal.properties>.
1944            * @return the lock object
1945            * @throws PortalException if the file entry or lock could not be found
1946            * @throws SystemException if a system exception occurred
1947            */
1948            public static com.liferay.portal.model.Lock refreshFileEntryLock(
1949                    java.lang.String lockUuid, long companyId, long expirationTime)
1950                    throws com.liferay.portal.kernel.exception.PortalException,
1951                            com.liferay.portal.kernel.exception.SystemException {
1952                    return getService()
1953                                       .refreshFileEntryLock(lockUuid, companyId, expirationTime);
1954            }
1955    
1956            /**
1957            * Refreshes the lock for the folder. This method is primarily used by
1958            * WebDAV.
1959            *
1960            * @param lockUuid the lock's universally unique identifier
1961            * @param companyId the primary key of the file entry's company
1962            * @param expirationTime the time in milliseconds before the lock expires.
1963            If the value is <code>0</code>, the default expiration time will
1964            be used from <code>portal.properties>.
1965            * @return the lock object
1966            * @throws PortalException if the folder or lock could not be found
1967            * @throws SystemException if a system exception occurred
1968            */
1969            public static com.liferay.portal.model.Lock refreshFolderLock(
1970                    java.lang.String lockUuid, long companyId, long expirationTime)
1971                    throws com.liferay.portal.kernel.exception.PortalException,
1972                            com.liferay.portal.kernel.exception.SystemException {
1973                    return getService()
1974                                       .refreshFolderLock(lockUuid, companyId, expirationTime);
1975            }
1976    
1977            /**
1978            * Restores the file entry with the primary key from the trash portlet.
1979            *
1980            * @param fileEntryId the primary key of the file entry
1981            * @throws PortalException if the file entry could not be found
1982            * @throws SystemException if a system exception occurred
1983            */
1984            public static void restoreFileEntryFromTrash(long fileEntryId)
1985                    throws com.liferay.portal.kernel.exception.PortalException,
1986                            com.liferay.portal.kernel.exception.SystemException {
1987                    getService().restoreFileEntryFromTrash(fileEntryId);
1988            }
1989    
1990            /**
1991            * Restores the file shortcut with the primary key from the trash portlet.
1992            *
1993            * @param fileShortcutId the primary key of the file shortcut
1994            * @throws PortalException if the file shortcut could not be found
1995            * @throws SystemException if a system exception occurred
1996            */
1997            public static void restoreFileShortcutFromTrash(long fileShortcutId)
1998                    throws com.liferay.portal.kernel.exception.PortalException,
1999                            com.liferay.portal.kernel.exception.SystemException {
2000                    getService().restoreFileShortcutFromTrash(fileShortcutId);
2001            }
2002    
2003            /**
2004            * Restores the folder with the primary key from the trash portlet.
2005            *
2006            * @param folderId the primary key of the folder
2007            * @throws PortalException if the folder could not be found
2008            * @throws SystemException if a system exception occurred
2009            */
2010            public static void restoreFolderFromTrash(long folderId)
2011                    throws com.liferay.portal.kernel.exception.PortalException,
2012                            com.liferay.portal.kernel.exception.SystemException {
2013                    getService().restoreFolderFromTrash(folderId);
2014            }
2015    
2016            /**
2017            * Reverts the file entry to a previous version. A new version will be
2018            * created based on the previous version and metadata.
2019            *
2020            * @param fileEntryId the primary key of the file entry
2021            * @param version the version to revert back to
2022            * @param serviceContext the service context to be applied
2023            * @throws PortalException if the file entry or version could not be found
2024            * @throws SystemException if a system exception occurred
2025            */
2026            public static void revertFileEntry(long fileEntryId,
2027                    java.lang.String version,
2028                    com.liferay.portal.service.ServiceContext serviceContext)
2029                    throws com.liferay.portal.kernel.exception.PortalException,
2030                            com.liferay.portal.kernel.exception.SystemException {
2031                    getService().revertFileEntry(fileEntryId, version, serviceContext);
2032            }
2033    
2034            public static com.liferay.portal.kernel.search.Hits search(
2035                    long repositoryId,
2036                    com.liferay.portal.kernel.search.SearchContext searchContext)
2037                    throws com.liferay.portal.kernel.search.SearchException {
2038                    return getService().search(repositoryId, searchContext);
2039            }
2040    
2041            public static com.liferay.portal.kernel.search.Hits search(
2042                    long repositoryId,
2043                    com.liferay.portal.kernel.search.SearchContext searchContext,
2044                    com.liferay.portal.kernel.search.Query query)
2045                    throws com.liferay.portal.kernel.search.SearchException {
2046                    return getService().search(repositoryId, searchContext, query);
2047            }
2048    
2049            /**
2050            * @deprecated Use {@link #checkInFileEntry(long, boolean, String,
2051            ServiceContext)}.
2052            */
2053            public static void unlockFileEntry(long fileEntryId)
2054                    throws com.liferay.portal.kernel.exception.PortalException,
2055                            com.liferay.portal.kernel.exception.SystemException {
2056                    getService().unlockFileEntry(fileEntryId);
2057            }
2058    
2059            /**
2060            * @deprecated Use {@link #checkInFileEntry(long, String)}.
2061            */
2062            public static void unlockFileEntry(long fileEntryId,
2063                    java.lang.String lockUuid)
2064                    throws com.liferay.portal.kernel.exception.PortalException,
2065                            com.liferay.portal.kernel.exception.SystemException {
2066                    getService().unlockFileEntry(fileEntryId, lockUuid);
2067            }
2068    
2069            /**
2070            * Unlocks the folder. This method is primarily used by WebDAV.
2071            *
2072            * @param repositoryId the primary key of the repository
2073            * @param folderId the primary key of the folder
2074            * @param lockUuid the lock's universally unique identifier
2075            * @throws PortalException if the repository or folder could not be found
2076            * @throws SystemException if a system exception occurred
2077            */
2078            public static void unlockFolder(long repositoryId, long folderId,
2079                    java.lang.String lockUuid)
2080                    throws com.liferay.portal.kernel.exception.PortalException,
2081                            com.liferay.portal.kernel.exception.SystemException {
2082                    getService().unlockFolder(repositoryId, folderId, lockUuid);
2083            }
2084    
2085            /**
2086            * Unlocks the folder. This method is primarily used by WebDAV.
2087            *
2088            * @param repositoryId the primary key of the repository
2089            * @param parentFolderId the primary key of the parent folder
2090            * @param name the folder's name
2091            * @param lockUuid the lock's universally unique identifier
2092            * @throws PortalException if the repository or folder could not be found
2093            * @throws SystemException if a system exception occurred
2094            */
2095            public static void unlockFolder(long repositoryId, long parentFolderId,
2096                    java.lang.String name, java.lang.String lockUuid)
2097                    throws com.liferay.portal.kernel.exception.PortalException,
2098                            com.liferay.portal.kernel.exception.SystemException {
2099                    getService().unlockFolder(repositoryId, parentFolderId, name, lockUuid);
2100            }
2101    
2102            /**
2103            * Updates a file entry and associated metadata based on a byte array
2104            * object. If the file data is <code>null</code>, then only the associated
2105            * metadata (i.e., <code>title</code>, <code>description</code>, and
2106            * parameters in the <code>serviceContext</code>) will be updated.
2107            *
2108            * <p>
2109            * This method takes two file names, the <code>sourceFileName</code> and the
2110            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
2111            * name of the actual file being uploaded. The <code>title</code>
2112            * corresponds to a name the client wishes to assign this file after it has
2113            * been uploaded to the portal.
2114            * </p>
2115            *
2116            * @param fileEntryId the primary key of the file entry
2117            * @param sourceFileName the original file's name (optionally
2118            <code>null</code>)
2119            * @param mimeType the file's MIME type (optionally <code>null</code>)
2120            * @param title the new name to be assigned to the file (optionally <code>
2121            <code>null</code></code>)
2122            * @param description the file's new description
2123            * @param changeLog the file's version change log (optionally
2124            <code>null</code>)
2125            * @param majorVersion whether the new file version is a major version
2126            * @param bytes the file's data (optionally <code>null</code>)
2127            * @param serviceContext the service context to be applied. Can set the
2128            asset category IDs, asset tag names, and expando bridge
2129            attributes for the file entry. In a Liferay repository, it may
2130            include:  <ul> <li> fileEntryTypeId - ID for a custom file entry
2131            type </li> <li> fieldsMap - mapping for fields associated with a
2132            custom file entry type </li> </ul>
2133            * @return the file entry
2134            * @throws PortalException if the file entry could not be found
2135            * @throws SystemException if a system exception occurred
2136            */
2137            public static com.liferay.portal.kernel.repository.model.FileEntry updateFileEntry(
2138                    long fileEntryId, java.lang.String sourceFileName,
2139                    java.lang.String mimeType, java.lang.String title,
2140                    java.lang.String description, java.lang.String changeLog,
2141                    boolean majorVersion, byte[] bytes,
2142                    com.liferay.portal.service.ServiceContext serviceContext)
2143                    throws com.liferay.portal.kernel.exception.PortalException,
2144                            com.liferay.portal.kernel.exception.SystemException {
2145                    return getService()
2146                                       .updateFileEntry(fileEntryId, sourceFileName, mimeType,
2147                            title, description, changeLog, majorVersion, bytes, serviceContext);
2148            }
2149    
2150            /**
2151            * Updates a file entry and associated metadata based on a {@link
2152            * java.io.File} object. If the file data is <code>null</code>, then only
2153            * the associated metadata (i.e., <code>title</code>,
2154            * <code>description</code>, and parameters in the
2155            * <code>serviceContext</code>) will be updated.
2156            *
2157            * <p>
2158            * This method takes two file names, the <code>sourceFileName</code> and the
2159            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
2160            * name of the actual file being uploaded. The <code>title</code>
2161            * corresponds to a name the client wishes to assign this file after it has
2162            * been uploaded to the portal.
2163            * </p>
2164            *
2165            * @param fileEntryId the primary key of the file entry
2166            * @param sourceFileName the original file's name (optionally
2167            <code>null</code>)
2168            * @param mimeType the file's MIME type (optionally <code>null</code>)
2169            * @param title the new name to be assigned to the file (optionally <code>
2170            <code>null</code></code>)
2171            * @param description the file's new description
2172            * @param changeLog the file's version change log (optionally
2173            <code>null</code>)
2174            * @param majorVersion whether the new file version is a major version
2175            * @param file EntryId the primary key of the file entry
2176            * @param serviceContext the service context to be applied. Can set the
2177            asset category IDs, asset tag names, and expando bridge
2178            attributes for the file entry. In a Liferay repository, it may
2179            include:  <ul> <li> fileEntryTypeId - ID for a custom file entry
2180            type </li> <li> fieldsMap - mapping for fields associated with a
2181            custom file entry type </li> </ul>
2182            * @return the file entry
2183            * @throws PortalException if the file entry could not be found
2184            * @throws SystemException if a system exception occurred
2185            */
2186            public static com.liferay.portal.kernel.repository.model.FileEntry updateFileEntry(
2187                    long fileEntryId, java.lang.String sourceFileName,
2188                    java.lang.String mimeType, java.lang.String title,
2189                    java.lang.String description, java.lang.String changeLog,
2190                    boolean majorVersion, java.io.File file,
2191                    com.liferay.portal.service.ServiceContext serviceContext)
2192                    throws com.liferay.portal.kernel.exception.PortalException,
2193                            com.liferay.portal.kernel.exception.SystemException {
2194                    return getService()
2195                                       .updateFileEntry(fileEntryId, sourceFileName, mimeType,
2196                            title, description, changeLog, majorVersion, file, serviceContext);
2197            }
2198    
2199            /**
2200            * Updates a file entry and associated metadata based on an {@link java.io.
2201            * InputStream} object. If the file data is <code>null</code>, then only the
2202            * associated metadata (i.e., <code>title</code>, <code>description</code>,
2203            * and parameters in the <code>serviceContext</code>) will be updated.
2204            *
2205            * <p>
2206            * This method takes two file names, the <code>sourceFileName</code> and the
2207            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
2208            * name of the actual file being uploaded. The <code>title</code>
2209            * corresponds to a name the client wishes to assign this file after it has
2210            * been uploaded to the portal.
2211            * </p>
2212            *
2213            * @param fileEntryId the primary key of the file entry
2214            * @param sourceFileName the original file's name (optionally
2215            <code>null</code>)
2216            * @param mimeType the file's MIME type (optionally <code>null</code>)
2217            * @param title the new name to be assigned to the file (optionally <code>
2218            <code>null</code></code>)
2219            * @param description the file's new description
2220            * @param changeLog the file's version change log (optionally
2221            <code>null</code>)
2222            * @param majorVersion whether the new file version is a major version
2223            * @param is the file's data (optionally <code>null</code>)
2224            * @param size the file's size (optionally <code>0</code>)
2225            * @param serviceContext the service context to be applied. Can set the
2226            asset category IDs, asset tag names, and expando bridge
2227            attributes for the file entry. In a Liferay repository, it may
2228            include:  <ul> <li> fileEntryTypeId - ID for a custom file entry
2229            type </li> <li> fieldsMap - mapping for fields associated with a
2230            custom file entry type </li> </ul>
2231            * @return the file entry
2232            * @throws PortalException if the file entry could not be found
2233            * @throws SystemException if a system exception occurred
2234            */
2235            public static com.liferay.portal.kernel.repository.model.FileEntry updateFileEntry(
2236                    long fileEntryId, java.lang.String sourceFileName,
2237                    java.lang.String mimeType, java.lang.String title,
2238                    java.lang.String description, java.lang.String changeLog,
2239                    boolean majorVersion, java.io.InputStream is, long size,
2240                    com.liferay.portal.service.ServiceContext serviceContext)
2241                    throws com.liferay.portal.kernel.exception.PortalException,
2242                            com.liferay.portal.kernel.exception.SystemException {
2243                    return getService()
2244                                       .updateFileEntry(fileEntryId, sourceFileName, mimeType,
2245                            title, description, changeLog, majorVersion, is, size,
2246                            serviceContext);
2247            }
2248    
2249            public static com.liferay.portal.kernel.repository.model.FileEntry updateFileEntryAndCheckIn(
2250                    long fileEntryId, java.lang.String sourceFileName,
2251                    java.lang.String mimeType, java.lang.String title,
2252                    java.lang.String description, java.lang.String changeLog,
2253                    boolean majorVersion, java.io.File file,
2254                    com.liferay.portal.service.ServiceContext serviceContext)
2255                    throws com.liferay.portal.kernel.exception.PortalException,
2256                            com.liferay.portal.kernel.exception.SystemException {
2257                    return getService()
2258                                       .updateFileEntryAndCheckIn(fileEntryId, sourceFileName,
2259                            mimeType, title, description, changeLog, majorVersion, file,
2260                            serviceContext);
2261            }
2262    
2263            public static com.liferay.portal.kernel.repository.model.FileEntry updateFileEntryAndCheckIn(
2264                    long fileEntryId, java.lang.String sourceFileName,
2265                    java.lang.String mimeType, java.lang.String title,
2266                    java.lang.String description, java.lang.String changeLog,
2267                    boolean majorVersion, java.io.InputStream is, long size,
2268                    com.liferay.portal.service.ServiceContext serviceContext)
2269                    throws com.liferay.portal.kernel.exception.PortalException,
2270                            com.liferay.portal.kernel.exception.SystemException {
2271                    return getService()
2272                                       .updateFileEntryAndCheckIn(fileEntryId, sourceFileName,
2273                            mimeType, title, description, changeLog, majorVersion, is, size,
2274                            serviceContext);
2275            }
2276    
2277            /**
2278            * Updates a file shortcut to the existing file entry. This method is only
2279            * supported by the Liferay repository.
2280            *
2281            * @param fileShortcutId the primary key of the file shortcut
2282            * @param folderId the primary key of the file shortcut's parent folder
2283            * @param toFileEntryId the primary key of the file shortcut's file entry
2284            * @param serviceContext the service context to be applied. Can set the
2285            asset category IDs, asset tag names, and expando bridge
2286            attributes for the file entry.
2287            * @return the file shortcut
2288            * @throws PortalException if the file shortcut, folder, or file entry could
2289            not be found
2290            * @throws SystemException if a system exception occurred
2291            */
2292            public static com.liferay.portlet.documentlibrary.model.DLFileShortcut updateFileShortcut(
2293                    long fileShortcutId, long folderId, long toFileEntryId,
2294                    com.liferay.portal.service.ServiceContext serviceContext)
2295                    throws com.liferay.portal.kernel.exception.PortalException,
2296                            com.liferay.portal.kernel.exception.SystemException {
2297                    return getService()
2298                                       .updateFileShortcut(fileShortcutId, folderId, toFileEntryId,
2299                            serviceContext);
2300            }
2301    
2302            /**
2303            * Updates the folder.
2304            *
2305            * @param folderId the primary key of the folder
2306            * @param name the folder's new name
2307            * @param description the folder's new description
2308            * @param serviceContext the service context to be applied. In a Liferay
2309            repository, it may include:  <ul> <li> defaultFileEntryTypeId -
2310            the file entry type to default all Liferay file entries to </li>
2311            <li> dlFileEntryTypesSearchContainerPrimaryKeys - a
2312            comma-delimited list of file entry type primary keys allowed in
2313            the given folder and all descendants </li> <li>
2314            overrideFileEntryTypes - boolean specifying whether to override
2315            ancestral folder's restriction of file entry types allowed </li>
2316            <li> workflowDefinitionXYZ - the workflow definition name
2317            specified per file entry type. The parameter name must be the
2318            string <code>workflowDefinition</code> appended by the <code>
2319            fileEntryTypeId</code> (optionally <code>0</code>). </li> </ul>
2320            * @return the folder
2321            * @throws PortalException if the current or new parent folder could not be
2322            found or if the new parent folder's information was invalid
2323            * @throws SystemException if a system exception occurred
2324            */
2325            public static com.liferay.portal.kernel.repository.model.Folder updateFolder(
2326                    long folderId, java.lang.String name, java.lang.String description,
2327                    com.liferay.portal.service.ServiceContext serviceContext)
2328                    throws com.liferay.portal.kernel.exception.PortalException,
2329                            com.liferay.portal.kernel.exception.SystemException {
2330                    return getService()
2331                                       .updateFolder(folderId, name, description, serviceContext);
2332            }
2333    
2334            /**
2335            * Returns <code>true</code> if the file entry is checked out. This method
2336            * is primarily used by WebDAV.
2337            *
2338            * @param repositoryId the primary key for the repository
2339            * @param fileEntryId the primary key for the file entry
2340            * @param lockUuid the lock's universally unique identifier
2341            * @return <code>true</code> if the file entry is checked out;
2342            <code>false</code> otherwise
2343            * @throws PortalException if the file entry could not be found
2344            * @throws SystemException if a system exception occurred
2345            */
2346            public static boolean verifyFileEntryCheckOut(long repositoryId,
2347                    long fileEntryId, java.lang.String lockUuid)
2348                    throws com.liferay.portal.kernel.exception.PortalException,
2349                            com.liferay.portal.kernel.exception.SystemException {
2350                    return getService()
2351                                       .verifyFileEntryCheckOut(repositoryId, fileEntryId, lockUuid);
2352            }
2353    
2354            public static boolean verifyFileEntryLock(long repositoryId,
2355                    long fileEntryId, java.lang.String lockUuid)
2356                    throws com.liferay.portal.kernel.exception.PortalException,
2357                            com.liferay.portal.kernel.exception.SystemException {
2358                    return getService()
2359                                       .verifyFileEntryLock(repositoryId, fileEntryId, lockUuid);
2360            }
2361    
2362            /**
2363            * Returns <code>true</code> if the inheritable lock exists. This method is
2364            * primarily used by WebDAV.
2365            *
2366            * @param repositoryId the primary key for the repository
2367            * @param folderId the primary key for the folder
2368            * @param lockUuid the lock's universally unique identifier
2369            * @return <code>true</code> if the inheritable lock exists;
2370            <code>false</code> otherwise
2371            * @throws PortalException if the folder could not be found
2372            * @throws SystemException if a system exception occurred
2373            */
2374            public static boolean verifyInheritableLock(long repositoryId,
2375                    long folderId, java.lang.String lockUuid)
2376                    throws com.liferay.portal.kernel.exception.PortalException,
2377                            com.liferay.portal.kernel.exception.SystemException {
2378                    return getService()
2379                                       .verifyInheritableLock(repositoryId, folderId, lockUuid);
2380            }
2381    
2382            public static DLAppService getService() {
2383                    if (_service == null) {
2384                            _service = (DLAppService)PortalBeanLocatorUtil.locate(DLAppService.class.getName());
2385    
2386                            ReferenceRegistry.registerReference(DLAppServiceUtil.class,
2387                                    "_service");
2388                    }
2389    
2390                    return _service;
2391            }
2392    
2393            /**
2394             * @deprecated
2395             */
2396            public void setService(DLAppService service) {
2397            }
2398    
2399            private static DLAppService _service;
2400    }