001    /**
002     * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portlet.documentlibrary.service;
016    
017    import com.liferay.portal.kernel.exception.PortalException;
018    import com.liferay.portal.kernel.exception.SystemException;
019    import com.liferay.portal.kernel.jsonwebservice.JSONWebService;
020    import com.liferay.portal.kernel.transaction.Isolation;
021    import com.liferay.portal.kernel.transaction.Propagation;
022    import com.liferay.portal.kernel.transaction.Transactional;
023    
024    /**
025     * The interface for the d l app remote service.
026     *
027     * <p>
028     * 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.
029     * </p>
030     *
031     * @author Brian Wing Shun Chan
032     * @see DLAppServiceUtil
033     * @see com.liferay.portlet.documentlibrary.service.base.DLAppServiceBaseImpl
034     * @see com.liferay.portlet.documentlibrary.service.impl.DLAppServiceImpl
035     * @generated
036     */
037    @JSONWebService
038    @Transactional(isolation = Isolation.PORTAL, rollbackFor =  {
039            PortalException.class, SystemException.class})
040    public interface DLAppService {
041            /*
042             * NOTE FOR DEVELOPERS:
043             *
044             * Never modify or reference this interface directly. Always use {@link DLAppServiceUtil} to access the d l app remote service. Add custom service methods to {@link com.liferay.portlet.documentlibrary.service.impl.DLAppServiceImpl} and rerun ServiceBuilder to automatically copy the method declarations to this interface.
045             */
046    
047            /**
048            * Adds a file entry and associated metadata. It is created based on a byte
049            * array.
050            *
051            * <p>
052            * This method takes two file names, the <code>sourceFileName</code> and the
053            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
054            * name of the actual file being uploaded. The <code>title</code>
055            * corresponds to a name the client wishes to assign this file after it has
056            * been uploaded to the portal. If it is <code>null</code>, the <code>
057            * sourceFileName</code> will be used.
058            * </p>
059            *
060            * @param repositoryId the primary key of the repository
061            * @param folderId the primary key of the file entry's parent folder
062            * @param sourceFileName the original file's name
063            * @param mimeType the file's MIME type
064            * @param title the name to be assigned to the file (optionally <code>null
065            </code>)
066            * @param description the file's description
067            * @param changeLog the file's version change log
068            * @param bytes the file's data (optionally <code>null</code>)
069            * @param serviceContext the service context to be applied. Can specify the
070            file entry's asset category IDs, asset tag names, and expando
071            bridge attributes. In a Liferay repository, it may include:
072            
073            <ul>
074            <li>
075            fileEntryTypeId - ID for a custom file entry type
076            </li>
077            <li>
078            fieldsMap - mapping for fields associated with a custom file
079            entry type
080            </li>
081            </ul>
082            * @return the file entry
083            * @throws PortalException if the parent folder could not be found or if the
084            file entry's information was invalid
085            * @throws SystemException if a system exception occurred
086            */
087            public com.liferay.portal.kernel.repository.model.FileEntry addFileEntry(
088                    long repositoryId, long folderId, java.lang.String sourceFileName,
089                    java.lang.String mimeType, java.lang.String title,
090                    java.lang.String description, java.lang.String changeLog, byte[] bytes,
091                    com.liferay.portal.service.ServiceContext serviceContext)
092                    throws com.liferay.portal.kernel.exception.PortalException,
093                            com.liferay.portal.kernel.exception.SystemException;
094    
095            /**
096            * Adds a file entry and associated metadata. It is created based on a
097            * {@link File} object.
098            *
099            * <p>
100            * This method takes two file names, the <code>sourceFileName</code> and the
101            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
102            * name of the actual file being uploaded. The <code>title</code>
103            * corresponds to a name the client wishes to assign this file after it has
104            * been uploaded to the portal. If it is <code>null</code>, the <code>
105            * sourceFileName</code> will be used.
106            * </p>
107            *
108            * @param repositoryId the primary key of the repository
109            * @param folderId the primary key of the file entry's parent folder
110            * @param sourceFileName the original file's name
111            * @param mimeType the file's MIME type
112            * @param title the name to be assigned to the file (optionally <code>null
113            </code>)
114            * @param description the file's description
115            * @param changeLog the file's version change log
116            * @param file the file's data (optionally <code>null</code>)
117            * @param serviceContext the service context to be applied. Can specify the
118            file entry's asset category IDs, asset tag names, and expando
119            bridge attributes. In a Liferay repository, it may include:
120            
121            <ul>
122            <li>
123            fileEntryTypeId - ID for a custom file entry type
124            </li>
125            <li>
126            fieldsMap - mapping for fields associated with a custom file
127            entry type
128            </li>
129            </ul>
130            * @return the file entry
131            * @throws PortalException if the parent folder could not be found or if the
132            file entry's information was invalid
133            * @throws SystemException if a system exception occurred
134            */
135            public com.liferay.portal.kernel.repository.model.FileEntry addFileEntry(
136                    long repositoryId, long folderId, java.lang.String sourceFileName,
137                    java.lang.String mimeType, java.lang.String title,
138                    java.lang.String description, java.lang.String changeLog,
139                    java.io.File file,
140                    com.liferay.portal.service.ServiceContext serviceContext)
141                    throws com.liferay.portal.kernel.exception.PortalException,
142                            com.liferay.portal.kernel.exception.SystemException;
143    
144            /**
145            * Adds a file entry and associated metadata. It is created based on a
146            * {@link InputStream} object.
147            *
148            * <p>
149            * This method takes two file names, the <code>sourceFileName</code> and the
150            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
151            * name of the actual file being uploaded. The <code>title</code>
152            * corresponds to a name the client wishes to assign this file after it has
153            * been uploaded to the portal. If it is <code>null</code>, the <code>
154            * sourceFileName</code> will be used.
155            * </p>
156            *
157            * @param repositoryId the primary key of the repository
158            * @param folderId the primary key of the file entry's parent folder
159            * @param sourceFileName the original file's name
160            * @param mimeType the file's MIME type
161            * @param title the name to be assigned to the file (optionally <code>null
162            </code>)
163            * @param description the file's description
164            * @param changeLog the file's version change log
165            * @param is the file's data (optionally <code>null</code>)
166            * @param size the file's size (optionally <code>0</code>)
167            * @param serviceContext the service context to be applied. Can specify the
168            file entry's asset category IDs, asset tag names, and expando
169            bridge attributes. In a Liferay repository, it may include:
170            
171            <ul>
172            <li>
173            fileEntryTypeId - ID for a custom file entry type
174            </li>
175            <li>
176            fieldsMap - mapping for fields associated with a custom file
177            entry type
178            </li>
179            </ul>
180            * @return the file entry
181            * @throws PortalException if the parent folder could not be found or if the
182            file entry's information was invalid
183            * @throws SystemException if a system exception occurred
184            */
185            public com.liferay.portal.kernel.repository.model.FileEntry addFileEntry(
186                    long repositoryId, long folderId, java.lang.String sourceFileName,
187                    java.lang.String mimeType, java.lang.String title,
188                    java.lang.String description, java.lang.String changeLog,
189                    java.io.InputStream is, long size,
190                    com.liferay.portal.service.ServiceContext serviceContext)
191                    throws com.liferay.portal.kernel.exception.PortalException,
192                            com.liferay.portal.kernel.exception.SystemException;
193    
194            /**
195            * Adds a file shortcut to the existing file entry. This method is only
196            * supported by the Liferay repository.
197            *
198            * @param repositoryId the primary key of the repository
199            * @param folderId the primary key of the file shortcut's parent folder
200            * @param toFileEntryId the primary key of the file shortcut's file entry
201            * @param serviceContext the service context to be applied. Can specify the
202            file entry's asset category IDs, asset tag names, and expando
203            bridge attributes.
204            * @return the file shortcut
205            * @throws PortalException if the parent folder or file entry could not be
206            found, or if the file shortcut's information was invalid
207            * @throws SystemException if a system exception occurred
208            */
209            public com.liferay.portlet.documentlibrary.model.DLFileShortcut addFileShortcut(
210                    long repositoryId, long folderId, long toFileEntryId,
211                    com.liferay.portal.service.ServiceContext serviceContext)
212                    throws com.liferay.portal.kernel.exception.PortalException,
213                            com.liferay.portal.kernel.exception.SystemException;
214    
215            /**
216            * Adds a folder.
217            *
218            * @param repositoryId the primary key of the repository
219            * @param parentFolderId the primary key of the folder's parent folder
220            * @param name the folder's name
221            * @param description the folder's description
222            * @param serviceContext the service context to be applied. In a Liferay
223            repository, it may include boolean mountPoint specifying whether
224            folder is a facade for mounting a third-party repository
225            * @return the folder
226            * @throws PortalException if the parent folder could not be found or if the
227            new folder's information was invalid
228            * @throws SystemException if a system exception occurred
229            */
230            public com.liferay.portal.kernel.repository.model.Folder addFolder(
231                    long repositoryId, long parentFolderId, java.lang.String name,
232                    java.lang.String description,
233                    com.liferay.portal.service.ServiceContext serviceContext)
234                    throws com.liferay.portal.kernel.exception.PortalException,
235                            com.liferay.portal.kernel.exception.SystemException;
236    
237            /**
238            * Adds a temporary file entry.
239            *
240            * <p>
241            * This allows a client to upload a file into a temporary location and
242            * manipulate its metadata prior to making it available for public usage.
243            * This is different from checking in and checking out a file entry.
244            * </p>
245            *
246            * @param groupId the primary key of the group
247            * @param folderId the primary key of the folder where the file entry will
248            eventually reside
249            * @param fileName the file's original name
250            * @param tempFolderName the temporary folder's name
251            * @param file the file's data
252            * @return the file's name
253            * @throws IOException if a problem occurred in the access or storage of the
254            file
255            * @throws PortalException if the file name was invalid
256            * @throws SystemException if a system exception occurred
257            * @see com.liferay.portal.kernel.util.TempFileUtil
258            */
259            public java.lang.String addTempFileEntry(long groupId, long folderId,
260                    java.lang.String fileName, java.lang.String tempFolderName,
261                    java.io.File file)
262                    throws com.liferay.portal.kernel.exception.PortalException,
263                            com.liferay.portal.kernel.exception.SystemException,
264                            java.io.IOException;
265    
266            public java.lang.String addTempFileEntry(long groupId, long folderId,
267                    java.lang.String fileName, java.lang.String tempFolderName,
268                    java.io.InputStream inputStream)
269                    throws com.liferay.portal.kernel.exception.PortalException,
270                            com.liferay.portal.kernel.exception.SystemException,
271                            java.io.IOException;
272    
273            /**
274            * Cancels the check out of the file entry. If a user has not checked out
275            * the specified file entry, invoking this method will result in no changes.
276            *
277            * <p>
278            * When a file entry is checked out, a PWC (private working copy) is created
279            * and the original file entry is locked. A client can make as many changes
280            * to the PWC as he desires without those changes being visible to other
281            * users. If the user is satisfied with the changes, he may elect to check
282            * in his changes, resulting in a new file version based on the PWC; the PWC
283            * will be removed and the file entry will be unlocked. If the user is not
284            * satisfied with the changes, he may elect to cancel his check out; this
285            * results in the deletion of the PWC and unlocking of the file entry.
286            * </p>
287            *
288            * @param fileEntryId the primary key of the file entry to cancel the
289            checkout
290            * @throws PortalException if the file entry could not be found
291            * @throws SystemException if a system exception occurred
292            * @see #checkInFileEntry(long, boolean, String, ServiceContext)
293            * @see #checkOutFileEntry(long)
294            */
295            public void cancelCheckOut(long fileEntryId)
296                    throws com.liferay.portal.kernel.exception.PortalException,
297                            com.liferay.portal.kernel.exception.SystemException;
298    
299            /**
300            * Checks in the file entry. If a user has not checked out the specified
301            * file entry, invoking this method will result in no changes.
302            *
303            * <p>
304            * When a file entry is checked out, a PWC (private working copy) is created
305            * and the original file entry is locked. A client can make as many changes
306            * to the PWC as he desires without those changes being visible to other
307            * users. If the user is satisfied with the changes, he may elect to check
308            * in his changes, resulting in a new file version based on the PWC; the PWC
309            * will be removed and the file entry will be unlocked. If the user is not
310            * satisfied with the changes, he may elect to cancel his check out; this
311            * results in the deletion of the PWC and unlocking of the file entry.
312            * </p>
313            *
314            * @param fileEntryId the primary key of the file entry to check in
315            * @param majorVersion whether the new file version is a major version
316            * @param changeLog the file's version change log
317            * @param serviceContext the service context to be applied
318            * @throws PortalException if the file entry could not be found
319            * @throws SystemException if a system exception occurred
320            * @see #cancelCheckOut(long)
321            * @see #checkOutFileEntry(long)
322            */
323            public void checkInFileEntry(long fileEntryId, boolean majorVersion,
324                    java.lang.String changeLog,
325                    com.liferay.portal.service.ServiceContext serviceContext)
326                    throws com.liferay.portal.kernel.exception.PortalException,
327                            com.liferay.portal.kernel.exception.SystemException;
328    
329            /**
330            * Checks in the file entry using the lock's UUID. If a user has not checked
331            * out the specified file entry, invoking this method will result in no
332            * changes. This method is primarily used by WebDAV.
333            *
334            * <p>
335            * When a file entry is checked out, a PWC (private working copy) is created
336            * and the original file entry is locked. A client can make as many changes
337            * to the PWC as he desires without those changes being visible to other
338            * users. If the user is satisfied with the changes, he may elect to check
339            * in his changes, resulting in a new file version based on the PWC; the PWC
340            * will be removed and the file entry will be unlocked. If the user is not
341            * satisfied with the changes, he may elect to cancel his check out; this
342            * results in the deletion of the PWC and unlocking of the file entry.
343            * </p>
344            *
345            * @param fileEntryId the primary key of the file entry to check in
346            * @param lockUuid the lock's universally unique identifier
347            * @throws PortalException if the file entry could not be found
348            * @throws SystemException if a system exception occurred
349            * @see #cancelCheckOut(long)
350            * @see #checkOutFileEntry(long, String, long)
351            */
352            public void checkInFileEntry(long fileEntryId, java.lang.String lockUuid)
353                    throws com.liferay.portal.kernel.exception.PortalException,
354                            com.liferay.portal.kernel.exception.SystemException;
355    
356            /**
357            * Check out a file entry.
358            *
359            * <p>
360            * When a file entry is checked out, a PWC (private working copy) is created
361            * and the original file entry is locked. A client can make as many changes
362            * to the PWC as he desires without those changes being visible to other
363            * users. If the user is satisfied with the changes, he may elect to check
364            * in his changes, resulting in a new file version based on the PWC; the PWC
365            * will be removed and the file entry will be unlocked. If the user is not
366            * satisfied with the changes, he may elect to cancel his check out; this
367            * results in the deletion of the PWC and unlocking of the file entry.
368            * </p>
369            *
370            * @param fileEntryId the file entry to check out
371            * @throws PortalException if the file entry could not be found
372            * @throws SystemException if a system exception occurred
373            * @see #cancelCheckOut(long)
374            * @see #checkInFileEntry(long, boolean, String, ServiceContext)
375            */
376            public void checkOutFileEntry(long fileEntryId)
377                    throws com.liferay.portal.kernel.exception.PortalException,
378                            com.liferay.portal.kernel.exception.SystemException;
379    
380            /**
381            * Checks out the file entry. This method is primarily used by WebDAV.
382            *
383            * <p>
384            * When a file entry is checked out, a PWC (private working copy) is created
385            * and the original file entry is locked. A client can make as many changes
386            * to the PWC as he desires without those changes being visible to other
387            * users. If the user is satisfied with the changes, he may elect to check
388            * in his changes, resulting in a new file version based on the PWC; the PWC
389            * will be removed and the file entry will be unlocked. If the user is not
390            * satisfied with the changes, he may elect to cancel his check out; this
391            * results in the deletion of the PWC and unlocking of the file entry.
392            * </p>
393            *
394            * @param fileEntryId the file entry to check out
395            * @param owner the owner string for the checkout (optionally
396            <code>null</code>)
397            * @param expirationTime the time in milliseconds before the lock expires.
398            If the value is <code>0</code>, the default expiration time will
399            be used from <code>portal.properties>.
400            * @return the file entry
401            * @throws PortalException if the file entry could not be found
402            * @throws SystemException if a system exception occurred
403            * @see #cancelCheckOut(long)
404            * @see #checkInFileEntry(long, String)
405            */
406            public com.liferay.portal.kernel.repository.model.FileEntry checkOutFileEntry(
407                    long fileEntryId, java.lang.String owner, long expirationTime)
408                    throws com.liferay.portal.kernel.exception.PortalException,
409                            com.liferay.portal.kernel.exception.SystemException;
410    
411            /**
412            * Performs a deep copy of the folder.
413            *
414            * @param repositoryId the primary key of the repository
415            * @param sourceFolderId the primary key of the folder to copy
416            * @param parentFolderId the primary key of the new folder's parent folder
417            * @param name the new folder's name
418            * @param description the new folder's description
419            * @param serviceContext the service context to be applied
420            * @return the folder
421            * @throws PortalException if the source folder or the new parent folder
422            could not be found or if the new folder's information was invalid
423            * @throws SystemException if a system exception occurred
424            */
425            public com.liferay.portal.kernel.repository.model.Folder copyFolder(
426                    long repositoryId, long sourceFolderId, long parentFolderId,
427                    java.lang.String name, java.lang.String description,
428                    com.liferay.portal.service.ServiceContext serviceContext)
429                    throws com.liferay.portal.kernel.exception.PortalException,
430                            com.liferay.portal.kernel.exception.SystemException;
431    
432            /**
433            * Deletes the file entry with the primary key.
434            *
435            * @param fileEntryId the primary key of the file entry
436            * @throws PortalException if the file entry could not be found
437            * @throws SystemException if a system exception occurred
438            */
439            public void deleteFileEntry(long fileEntryId)
440                    throws com.liferay.portal.kernel.exception.PortalException,
441                            com.liferay.portal.kernel.exception.SystemException;
442    
443            /**
444            * Deletes the file entry with the title in the folder.
445            *
446            * @param repositoryId the primary key of the repository
447            * @param folderId the primary key of the file entry's parent folder
448            * @param title the file entry's title
449            * @throws PortalException if the file entry could not be found
450            * @throws SystemException if a system exception occurred
451            */
452            public void deleteFileEntryByTitle(long repositoryId, long folderId,
453                    java.lang.String title)
454                    throws com.liferay.portal.kernel.exception.PortalException,
455                            com.liferay.portal.kernel.exception.SystemException;
456    
457            /**
458            * Deletes the file shortcut with the primary key. This method is only
459            * supported by the Liferay repository.
460            *
461            * @param fileShortcutId the primary key of the file shortcut
462            * @throws PortalException if the file shortcut could not be found
463            * @throws SystemException if a system exception occurred
464            */
465            public void deleteFileShortcut(long fileShortcutId)
466                    throws com.liferay.portal.kernel.exception.PortalException,
467                            com.liferay.portal.kernel.exception.SystemException;
468    
469            /**
470            * Deletes the folder with the primary key and all of its subfolders and
471            * file entries.
472            *
473            * @param folderId the primary key of the folder
474            * @throws PortalException if the folder could not be found
475            * @throws SystemException if a system exception occurred
476            */
477            public void deleteFolder(long folderId)
478                    throws com.liferay.portal.kernel.exception.PortalException,
479                            com.liferay.portal.kernel.exception.SystemException;
480    
481            /**
482            * Deletes the folder with the name in the parent folder and all of its
483            * subfolders and file entries.
484            *
485            * @param repositoryId the primary key of the repository
486            * @param parentFolderId the primary key of the folder's parent folder
487            * @param name the folder's name
488            * @throws PortalException if the folder could not be found
489            * @throws SystemException if a system exception occurred
490            */
491            public void deleteFolder(long repositoryId, long parentFolderId,
492                    java.lang.String name)
493                    throws com.liferay.portal.kernel.exception.PortalException,
494                            com.liferay.portal.kernel.exception.SystemException;
495    
496            /**
497            * Deletes the temporary file entry.
498            *
499            * @param groupId the primary key of the group
500            * @param folderId the primary key of the folder where the file entry was
501            eventually to reside
502            * @param fileName the file's original name
503            * @param tempFolderName the temporary folder's name
504            * @throws PortalException if the file name was invalid
505            * @throws SystemException if a system exception occurred
506            * @see com.liferay.portal.kernel.util.TempFileUtil
507            */
508            public void deleteTempFileEntry(long groupId, long folderId,
509                    java.lang.String fileName, java.lang.String tempFolderName)
510                    throws com.liferay.portal.kernel.exception.PortalException,
511                            com.liferay.portal.kernel.exception.SystemException;
512    
513            /**
514            * Returns all the file entries in the folder.
515            *
516            * @param repositoryId the primary key of the file entry's repository
517            * @param folderId the primary key of the file entry's folder
518            * @return the file entries in the folder
519            * @throws PortalException if the folder could not be found
520            * @throws SystemException if a system exception occurred
521            */
522            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
523            public java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
524                    long repositoryId, long folderId)
525                    throws com.liferay.portal.kernel.exception.PortalException,
526                            com.liferay.portal.kernel.exception.SystemException;
527    
528            /**
529            * Returns a range of all the file entries in the folder.
530            *
531            * <p>
532            * Useful when paginating results. Returns a maximum of <code>end -
533            * start</code> instances. <code>start</code> and <code>end</code> are not
534            * primary keys, they are indexes in the result set. Thus, <code>0</code>
535            * refers to the first result in the set. Setting both <code>start</code>
536            * and <code>end</code> to {@link
537            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
538            * result set.
539            * </p>
540            *
541            * @param repositoryId the primary key of the file entry's repository
542            * @param folderId the primary key of the file entry's folder
543            * @param start the lower bound of the range of results
544            * @param end the upper bound of the range of results (not inclusive)
545            * @return the range of file entries in the folder
546            * @throws PortalException if the folder could not be found
547            * @throws SystemException if a system exception occurred
548            */
549            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
550            public java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
551                    long repositoryId, long folderId, int start, int end)
552                    throws com.liferay.portal.kernel.exception.PortalException,
553                            com.liferay.portal.kernel.exception.SystemException;
554    
555            /**
556            * Returns an ordered range of all the file entries in the folder.
557            *
558            * <p>
559            * Useful when paginating results. Returns a maximum of <code>end -
560            * start</code> instances. <code>start</code> and <code>end</code> are not
561            * primary keys, they are indexes in the result set. Thus, <code>0</code>
562            * refers to the first result in the set. Setting both <code>start</code>
563            * and <code>end</code> to {@link
564            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
565            * result set.
566            * </p>
567            *
568            * @param repositoryId the primary key of the file entry's repository
569            * @param folderId the primary key of the file entry's folder
570            * @param start the lower bound of the range of results
571            * @param end the upper bound of the range of results (not inclusive)
572            * @param obc the comparator to order the file entries (optionally
573            <code>null</code>)
574            * @return the range of file entries in the folder ordered by comparator
575            <code>obc</code>
576            * @throws PortalException if the folder could not be found
577            * @throws SystemException if a system exception occurred
578            */
579            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
580            public java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
581                    long repositoryId, long folderId, int start, int end,
582                    com.liferay.portal.kernel.util.OrderByComparator obc)
583                    throws com.liferay.portal.kernel.exception.PortalException,
584                            com.liferay.portal.kernel.exception.SystemException;
585    
586            /**
587            * Returns the file entries with the file entry type in the folder.
588            *
589            * @param repositoryId the primary key of the file entry's repository
590            * @param folderId the primary key of the file entry's folder
591            * @param fileEntryTypeId the primary key of the file entry type
592            * @return the file entries with the file entry type in the folder
593            * @throws PortalException if the folder could not be found
594            * @throws SystemException if a system exception occurred
595            */
596            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
597            public java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
598                    long repositoryId, long folderId, long fileEntryTypeId)
599                    throws com.liferay.portal.kernel.exception.PortalException,
600                            com.liferay.portal.kernel.exception.SystemException;
601    
602            /**
603            * Returns a range of all the file entries with the file entry type in the
604            * folder.
605            *
606            * @param repositoryId the primary key of the file entry's repository
607            * @param folderId the primary key of the file entry's folder
608            * @param fileEntryTypeId the primary key of the file entry type
609            * @param start the lower bound of the range of results
610            * @param end the upper bound of the range of results (not inclusive)
611            * @return the file entries in the folder
612            * @throws PortalException if the folder could not be found
613            * @throws SystemException if a system exception occurred
614            */
615            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
616            public java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
617                    long repositoryId, long folderId, long fileEntryTypeId, int start,
618                    int end)
619                    throws com.liferay.portal.kernel.exception.PortalException,
620                            com.liferay.portal.kernel.exception.SystemException;
621    
622            /**
623            * Returns an ordered range of all the file entries with the file entry type
624            * in the folder.
625            *
626            * @param repositoryId the primary key of the repository
627            * @param folderId the primary key of the folder
628            * @param fileEntryTypeId the primary key of the file entry type
629            * @param start the lower bound of the range of results
630            * @param end the upper bound of the range of results (not inclusive)
631            * @param obc the comparator to order the results by (optionally
632            <code>null</code>)
633            * @return the range of file entries with the file entry type in the folder
634            ordered by <code>null</code>
635            * @throws PortalException if the folder could not be found
636            * @throws SystemException if a system exception occurred
637            */
638            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
639            public java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getFileEntries(
640                    long repositoryId, long folderId, long fileEntryTypeId, int start,
641                    int end, com.liferay.portal.kernel.util.OrderByComparator obc)
642                    throws com.liferay.portal.kernel.exception.PortalException,
643                            com.liferay.portal.kernel.exception.SystemException;
644    
645            /**
646            * Returns a range of all the file entries and shortcuts in the folder.
647            *
648            * <p>
649            * Useful when paginating results. Returns a maximum of <code>end -
650            * start</code> instances. <code>start</code> and <code>end</code> are not
651            * primary keys, they are indexes in the result set. Thus, <code>0</code>
652            * refers to the first result in the set. Setting both <code>start</code>
653            * and <code>end</code> to {@link
654            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
655            * result set.
656            * </p>
657            *
658            * @param repositoryId the primary key of the repository
659            * @param folderId the primary key of the folder
660            * @param status the workflow status
661            * @param start the lower bound of the range of results
662            * @param end the upper bound of the range of results (not inclusive)
663            * @return the range of file entries and shortcuts in the folder
664            * @throws PortalException if the folder could not be found
665            * @throws SystemException if a system exception occurred
666            */
667            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
668            public java.util.List<java.lang.Object> getFileEntriesAndFileShortcuts(
669                    long repositoryId, long folderId, int status, int start, int end)
670                    throws com.liferay.portal.kernel.exception.PortalException,
671                            com.liferay.portal.kernel.exception.SystemException;
672    
673            /**
674            * Returns the number of file entries and shortcuts in the folder.
675            *
676            * @param repositoryId the primary key of the repository
677            * @param folderId the primary key of the folder
678            * @param status the workflow status
679            * @return the number of file entries and shortcuts in the folder
680            * @throws PortalException if the folder ould not be found
681            * @throws SystemException if a system exception occurred
682            */
683            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
684            public int getFileEntriesAndFileShortcutsCount(long repositoryId,
685                    long folderId, int status)
686                    throws com.liferay.portal.kernel.exception.PortalException,
687                            com.liferay.portal.kernel.exception.SystemException;
688    
689            /**
690            * Returns the number of file entries in the folder.
691            *
692            * @param repositoryId the primary key of the file entry's repository
693            * @param folderId the primary key of the file entry's folder
694            * @return the number of file entries in the folder
695            * @throws PortalException if the folder could not be found
696            * @throws SystemException if a system exception occurred
697            */
698            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
699            public int getFileEntriesCount(long repositoryId, long folderId)
700                    throws com.liferay.portal.kernel.exception.PortalException,
701                            com.liferay.portal.kernel.exception.SystemException;
702    
703            /**
704            * Returns the number of file entries with the file entry type in the
705            * folder.
706            *
707            * @param repositoryId the primary key of the file entry's repository
708            * @param folderId the primary key of the file entry's folder
709            * @param fileEntryTypeId the primary key of the file entry type
710            * @return the number of file entries with the file entry type in the folder
711            * @throws PortalException if the folder could not be found
712            * @throws SystemException if a system exception occurred
713            */
714            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
715            public int getFileEntriesCount(long repositoryId, long folderId,
716                    long fileEntryTypeId)
717                    throws com.liferay.portal.kernel.exception.PortalException,
718                            com.liferay.portal.kernel.exception.SystemException;
719    
720            /**
721            * Returns the file entry with the primary key.
722            *
723            * @param fileEntryId the primary key of the file entry
724            * @return the file entry with the primary key
725            * @throws PortalException if the file entry could not be found
726            * @throws SystemException if a system exception occurred
727            */
728            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
729            public com.liferay.portal.kernel.repository.model.FileEntry getFileEntry(
730                    long fileEntryId)
731                    throws com.liferay.portal.kernel.exception.PortalException,
732                            com.liferay.portal.kernel.exception.SystemException;
733    
734            /**
735            * Returns the file entry with the title in the folder.
736            *
737            * @param groupId the primary key of the file entry's group
738            * @param folderId the primary key of the file entry's folder
739            * @param title the file entry's title
740            * @return the file entry with the title in the folder
741            * @throws PortalException if the file entry could not be found
742            * @throws SystemException if a system exception occurred
743            */
744            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
745            public com.liferay.portal.kernel.repository.model.FileEntry getFileEntry(
746                    long groupId, long folderId, java.lang.String title)
747                    throws com.liferay.portal.kernel.exception.PortalException,
748                            com.liferay.portal.kernel.exception.SystemException;
749    
750            /**
751            * Returns the file entry with the UUID and group.
752            *
753            * @param uuid the file entry's universally unique identifier
754            * @param groupId the primary key of the file entry's group
755            * @return the file entry with the UUID and group
756            * @throws PortalException if the file entry could not be found
757            * @throws SystemException if a system exception occurred
758            */
759            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
760            public com.liferay.portal.kernel.repository.model.FileEntry getFileEntryByUuidAndGroupId(
761                    java.lang.String uuid, long groupId)
762                    throws com.liferay.portal.kernel.exception.PortalException,
763                            com.liferay.portal.kernel.exception.SystemException;
764    
765            /**
766            * Returns the file shortcut with the primary key. This method is only
767            * supported by the Liferay repository.
768            *
769            * @param fileShortcutId the primary key of the file shortcut
770            * @return the file shortcut with the primary key
771            * @throws PortalException if the file shortcut could not be found
772            * @throws SystemException if a system exception occurred
773            */
774            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
775            public com.liferay.portlet.documentlibrary.model.DLFileShortcut getFileShortcut(
776                    long fileShortcutId)
777                    throws com.liferay.portal.kernel.exception.PortalException,
778                            com.liferay.portal.kernel.exception.SystemException;
779    
780            /**
781            * Returns the folder with the primary key.
782            *
783            * @param folderId the primary key of the folder
784            * @return the folder with the primary key
785            * @throws PortalException if the folder could not be found
786            * @throws SystemException if a system exception occurred
787            */
788            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
789            public com.liferay.portal.kernel.repository.model.Folder getFolder(
790                    long folderId)
791                    throws com.liferay.portal.kernel.exception.PortalException,
792                            com.liferay.portal.kernel.exception.SystemException;
793    
794            /**
795            * Returns the folder with the name in the parent folder.
796            *
797            * @param repositoryId the primary key of the folder's repository
798            * @param parentFolderId the primary key of the folder's parent folder
799            * @param name the folder's name
800            * @return the folder with the name in the parent folder
801            * @throws PortalException if the folder could not be found
802            * @throws SystemException if a system exception occurred
803            */
804            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
805            public com.liferay.portal.kernel.repository.model.Folder getFolder(
806                    long repositoryId, long parentFolderId, java.lang.String name)
807                    throws com.liferay.portal.kernel.exception.PortalException,
808                            com.liferay.portal.kernel.exception.SystemException;
809    
810            /**
811            * Returns all immediate subfolders of the parent folder.
812            *
813            * @param repositoryId the primary key of the folder's repository
814            * @param parentFolderId the primary key of the folder's parent folder
815            * @return the immediate subfolders of the parent folder
816            * @throws PortalException if the parent folder could not be found
817            * @throws SystemException if a system exception occurred
818            */
819            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
820            public java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
821                    long repositoryId, long parentFolderId)
822                    throws com.liferay.portal.kernel.exception.PortalException,
823                            com.liferay.portal.kernel.exception.SystemException;
824    
825            /**
826            * Returns all immediate subfolders of the parent folder, optionally
827            * including mount folders for third-party repositories.
828            *
829            * @param repositoryId the primary key of the folder's repository
830            * @param parentFolderId the primary key of the folder's parent folder
831            * @param includeMountFolders whether to include mount folders for
832            third-party repositories
833            * @return the immediate subfolders of the parent folder
834            * @throws PortalException if the parent folder could not be found
835            * @throws SystemException if a system exception occurred
836            */
837            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
838            public java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
839                    long repositoryId, long parentFolderId, boolean includeMountFolders)
840                    throws com.liferay.portal.kernel.exception.PortalException,
841                            com.liferay.portal.kernel.exception.SystemException;
842    
843            /**
844            * Returns a range of all the immediate subfolders of the parent folder,
845            * optionally including mount folders for third-party repositories.
846            *
847            * <p>
848            * Useful when paginating results. Returns a maximum of <code>end -
849            * start</code> instances. <code>start</code> and <code>end</code> are not
850            * primary keys, they are indexes in the result set. Thus, <code>0</code>
851            * refers to the first result in the set. Setting both <code>start</code>
852            * and <code>end</code> to {@link
853            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
854            * result set.
855            * </p>
856            *
857            * @param repositoryId the primary key of the folder's repository
858            * @param parentFolderId the primary key of the folder's parent folder
859            * @param includeMountFolders whether to include mount folders for
860            third-party repositories
861            * @param start the lower bound of the range of results
862            * @param end the upper bound of the range of results (not inclusive)
863            * @return the range of immediate subfolders of the parent folder
864            * @throws PortalException if the parent folder could not be found
865            * @throws SystemException if a system exception occurred
866            */
867            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
868            public java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
869                    long repositoryId, long parentFolderId, boolean includeMountFolders,
870                    int start, int end)
871                    throws com.liferay.portal.kernel.exception.PortalException,
872                            com.liferay.portal.kernel.exception.SystemException;
873    
874            /**
875            * Returns an ordered range of all the immediate subfolders of the parent
876            * folder.
877            *
878            * <p>
879            * Useful when paginating results. Returns a maximum of <code>end -
880            * start</code> instances. <code>start</code> and <code>end</code> are not
881            * primary keys, they are indexes in the result set. Thus, <code>0</code>
882            * refers to the first result in the set. Setting both <code>start</code>
883            * and <code>end</code> to {@link
884            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
885            * result set.
886            * </p>
887            *
888            * @param repositoryId the primary key of the folder's repository
889            * @param parentFolderId the primary key of the folder's parent folder
890            * @param includeMountFolders whether to include mount folders for
891            third-party repositories
892            * @param start the lower bound of the range of results
893            * @param end the upper bound of the range of results (not inclusive)
894            * @param obc the comparator to order the folders (optionally
895            <code>null</code>)
896            * @return the range of immediate subfolders of the parent folder ordered by
897            comparator <code>obc</code>
898            * @throws PortalException if the parent folder could not be found
899            * @throws SystemException if a system exception occurred
900            */
901            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
902            public java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
903                    long repositoryId, long parentFolderId, boolean includeMountFolders,
904                    int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
905                    throws com.liferay.portal.kernel.exception.PortalException,
906                            com.liferay.portal.kernel.exception.SystemException;
907    
908            /**
909            * Returns a range of all the immediate subfolders of the parent folder.
910            *
911            * <p>
912            * Useful when paginating results. Returns a maximum of <code>end -
913            * start</code> instances. <code>start</code> and <code>end</code> are not
914            * primary keys, they are indexes in the result set. Thus, <code>0</code>
915            * refers to the first result in the set. Setting both <code>start</code>
916            * and <code>end</code> to {@link
917            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
918            * result set.
919            * </p>
920            *
921            * @param repositoryId the primary key of the folder's repository
922            * @param parentFolderId the primary key of the folder's parent folder
923            * @param start the lower bound of the range of results
924            * @param end the upper bound of the range of results (not inclusive)
925            * @return the range of immediate subfolders of the parent folder
926            * @throws PortalException if the parent folder could not be found
927            * @throws SystemException if a system exception occurred
928            */
929            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
930            public java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
931                    long repositoryId, long parentFolderId, int start, int end)
932                    throws com.liferay.portal.kernel.exception.PortalException,
933                            com.liferay.portal.kernel.exception.SystemException;
934    
935            /**
936            * Returns an ordered range of all the immediate subfolders of the parent
937            * folder.
938            *
939            * <p>
940            * Useful when paginating results. Returns a maximum of <code>end -
941            * start</code> instances. <code>start</code> and <code>end</code> are not
942            * primary keys, they are indexes in the result set. Thus, <code>0</code>
943            * refers to the first result in the set. Setting both <code>start</code>
944            * and <code>end</code> to {@link
945            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
946            * result set.
947            * </p>
948            *
949            * @param repositoryId the primary key of the folder's repository
950            * @param parentFolderId the primary key of the folder's parent folder
951            * @param start the lower bound of the range of results
952            * @param end the upper bound of the range of results (not inclusive)
953            * @param obc the comparator to order the folders (optionally
954            <code>null</code>)
955            * @return the range of immediate subfolders of the parent folder ordered by
956            comparator <code>obc</code>
957            * @throws PortalException if the parent folder could not be found
958            * @throws SystemException if a system exception occurred
959            */
960            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
961            public java.util.List<com.liferay.portal.kernel.repository.model.Folder> getFolders(
962                    long repositoryId, long parentFolderId, int start, int end,
963                    com.liferay.portal.kernel.util.OrderByComparator obc)
964                    throws com.liferay.portal.kernel.exception.PortalException,
965                            com.liferay.portal.kernel.exception.SystemException;
966    
967            /**
968            * Returns a range of all the immediate subfolders, file entries, and file
969            * shortcuts in the parent folder.
970            *
971            * <p>
972            * Useful when paginating results. Returns a maximum of <code>end -
973            * start</code> instances. <code>start</code> and <code>end</code> are not
974            * primary keys, they are indexes in the result set. Thus, <code>0</code>
975            * refers to the first result in the set. Setting both <code>start</code>
976            * and <code>end</code> to {@link
977            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
978            * result set.
979            * </p>
980            *
981            * @param repositoryId the primary key of the repository
982            * @param folderId the primary key of the parent folder
983            * @param status the workflow status
984            * @param includeMountFolders whether to include mount folders for
985            third-party repositories
986            * @param start the lower bound of the range of results
987            * @param end the upper bound of the range of results (not inclusive)
988            * @return the range of immediate subfolders, file entries, and file
989            shortcuts in the parent folder ordered by comparator
990            <code>obc</code>
991            * @throws PortalException if the parent folder could not be found
992            * @throws SystemException if a system exception occurred
993            */
994            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
995            public java.util.List<java.lang.Object> getFoldersAndFileEntriesAndFileShortcuts(
996                    long repositoryId, long folderId, int status,
997                    boolean includeMountFolders, int start, int end)
998                    throws com.liferay.portal.kernel.exception.PortalException,
999                            com.liferay.portal.kernel.exception.SystemException;
1000    
1001            /**
1002            * Returns an ordered range of all the immediate subfolders, file entries,
1003            * and file shortcuts in the parent folder.
1004            *
1005            * <p>
1006            * Useful when paginating results. Returns a maximum of <code>end -
1007            * start</code> instances. <code>start</code> and <code>end</code> are not
1008            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1009            * refers to the first result in the set. Setting both <code>start</code>
1010            * and <code>end</code> to {@link
1011            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1012            * result set.
1013            * </p>
1014            *
1015            * @param repositoryId the primary key of the repository
1016            * @param folderId the primary key of the parent folder
1017            * @param status the workflow status
1018            * @param includeMountFolders whether to include mount folders for
1019            third-party repositories
1020            * @param start the lower bound of the range of results
1021            * @param end the upper bound of the range of results (not inclusive)
1022            * @param obc the comparator to order the results (optionally
1023            <code>null</code>)
1024            * @return the range of immediate subfolders, file entries, and file
1025            shortcuts in the parent folder ordered by comparator
1026            <code>obc</code>
1027            * @throws PortalException if the parent folder could not be found
1028            * @throws SystemException if a system exception occurred
1029            */
1030            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1031            public java.util.List<java.lang.Object> getFoldersAndFileEntriesAndFileShortcuts(
1032                    long repositoryId, long folderId, int status,
1033                    boolean includeMountFolders, int start, int end,
1034                    com.liferay.portal.kernel.util.OrderByComparator obc)
1035                    throws com.liferay.portal.kernel.exception.PortalException,
1036                            com.liferay.portal.kernel.exception.SystemException;
1037    
1038            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1039            public java.util.List<java.lang.Object> getFoldersAndFileEntriesAndFileShortcuts(
1040                    long repositoryId, long folderId, int status,
1041                    java.lang.String[] mimeTypes, boolean includeMountFolders, int start,
1042                    int end, com.liferay.portal.kernel.util.OrderByComparator obc)
1043                    throws com.liferay.portal.kernel.exception.PortalException,
1044                            com.liferay.portal.kernel.exception.SystemException;
1045    
1046            /**
1047            * Returns the number of immediate subfolders, file entries, and file
1048            * shortcuts in the parent folder.
1049            *
1050            * @param repositoryId the primary key of the repository
1051            * @param folderId the primary key of the parent folder
1052            * @param status the workflow status
1053            * @param includeMountFolders whether to include mount folders for
1054            third-party repositories
1055            * @return the number of immediate subfolders, file entries, and file
1056            shortcuts in the parent folder
1057            * @throws PortalException if the folder could not be found
1058            * @throws SystemException if a system exception occurred
1059            */
1060            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1061            public int getFoldersAndFileEntriesAndFileShortcutsCount(
1062                    long repositoryId, long folderId, int status,
1063                    boolean includeMountFolders)
1064                    throws com.liferay.portal.kernel.exception.PortalException,
1065                            com.liferay.portal.kernel.exception.SystemException;
1066    
1067            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1068            public int getFoldersAndFileEntriesAndFileShortcutsCount(
1069                    long repositoryId, long folderId, int status,
1070                    java.lang.String[] mimeTypes, boolean includeMountFolders)
1071                    throws com.liferay.portal.kernel.exception.PortalException,
1072                            com.liferay.portal.kernel.exception.SystemException;
1073    
1074            /**
1075            * Returns the number of immediate subfolders of the parent folder.
1076            *
1077            * @param repositoryId the primary key of the folder's repository
1078            * @param parentFolderId the primary key of the folder's parent folder
1079            * @return the number of immediate subfolders of the parent folder
1080            * @throws PortalException if the parent folder could not be found
1081            * @throws SystemException if a system exception occurred
1082            */
1083            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1084            public int getFoldersCount(long repositoryId, long parentFolderId)
1085                    throws com.liferay.portal.kernel.exception.PortalException,
1086                            com.liferay.portal.kernel.exception.SystemException;
1087    
1088            /**
1089            * Returns the number of immediate subfolders of the parent folder,
1090            * optionally including mount folders for third-party repositories.
1091            *
1092            * @param repositoryId the primary key of the folder's repository
1093            * @param parentFolderId the primary key of the folder's parent folder
1094            * @param includeMountFolders whether to include mount folders for
1095            third-party repositories
1096            * @return the number of immediate subfolders of the parent folder
1097            * @throws PortalException if the parent folder could not be found
1098            * @throws SystemException if a system exception occurred
1099            */
1100            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1101            public int getFoldersCount(long repositoryId, long parentFolderId,
1102                    boolean includeMountFolders)
1103                    throws com.liferay.portal.kernel.exception.PortalException,
1104                            com.liferay.portal.kernel.exception.SystemException;
1105    
1106            /**
1107            * Returns the number of immediate subfolders and file entries across the
1108            * folders.
1109            *
1110            * @param repositoryId the primary key of the repository
1111            * @param folderIds the primary keys of folders from which to count
1112            immediate subfolders and file entries
1113            * @param status the workflow status
1114            * @return the number of immediate subfolders and file entries across the
1115            folders
1116            * @throws PortalException if the repository could not be found
1117            * @throws SystemException if a system exception occurred
1118            */
1119            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1120            public int getFoldersFileEntriesCount(long repositoryId,
1121                    java.util.List<java.lang.Long> folderIds, int status)
1122                    throws com.liferay.portal.kernel.exception.PortalException,
1123                            com.liferay.portal.kernel.exception.SystemException;
1124    
1125            /**
1126            * Returns an ordered range of all the file entries in the group starting at
1127            * the repository default parent folder that are stored within the Liferay
1128            * repository. This method is primarily used to search for recently modified
1129            * file entries. It can be limited to the file entries modified by a given
1130            * user.
1131            *
1132            * <p>
1133            * Useful when paginating results. Returns a maximum of <code>end -
1134            * start</code> instances. <code>start</code> and <code>end</code> are not
1135            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1136            * refers to the first result in the set. Setting both <code>start</code>
1137            * and <code>end</code> to {@link
1138            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1139            * result set.
1140            * </p>
1141            *
1142            * @param groupId the primary key of the group
1143            * @param userId the primary key of the user who created the file
1144            (optionally <code>0</code>)
1145            * @param start the lower bound of the range of results
1146            * @param end the upper bound of the range of results (not inclusive)
1147            * @return the range of matching file entries ordered by date modified
1148            * @throws PortalException if the group could not be found
1149            * @throws SystemException if a system exception occurred
1150            */
1151            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1152            public java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getGroupFileEntries(
1153                    long groupId, long userId, int start, int end)
1154                    throws com.liferay.portal.kernel.exception.PortalException,
1155                            com.liferay.portal.kernel.exception.SystemException;
1156    
1157            /**
1158            * Returns an ordered range of all the file entries in the group that are
1159            * stored within the Liferay repository. This method is primarily used to
1160            * search for recently modified file entries. It can be limited to the file
1161            * entries modified by a given user.
1162            *
1163            * <p>
1164            * Useful when paginating results. Returns a maximum of <code>end -
1165            * start</code> instances. <code>start</code> and <code>end</code> are not
1166            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1167            * refers to the first result in the set. Setting both <code>start</code>
1168            * and <code>end</code> to {@link
1169            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1170            * result set.
1171            * </p>
1172            *
1173            * @param groupId the primary key of the group
1174            * @param userId the primary key of the user who created the file
1175            (optionally <code>0</code>)
1176            * @param start the lower bound of the range of results
1177            * @param end the upper bound of the range of results (not inclusive)
1178            * @param obc the comparator to order the file entries (optionally
1179            <code>null</code>)
1180            * @return the range of matching file entries ordered by comparator
1181            <code>obc</code>
1182            * @throws PortalException if the group could not be found
1183            * @throws SystemException if a system exception occurred
1184            */
1185            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1186            public java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getGroupFileEntries(
1187                    long groupId, long userId, int start, int end,
1188                    com.liferay.portal.kernel.util.OrderByComparator obc)
1189                    throws com.liferay.portal.kernel.exception.PortalException,
1190                            com.liferay.portal.kernel.exception.SystemException;
1191    
1192            /**
1193            * Returns an ordered range of all the file entries in the group starting at
1194            * the root folder that are stored within the Liferay repository. This
1195            * method is primarily used to search for recently modified file entries. It
1196            * can be limited to the file entries modified by a given user.
1197            *
1198            * <p>
1199            * Useful when paginating results. Returns a maximum of <code>end -
1200            * start</code> instances. <code>start</code> and <code>end</code> are not
1201            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1202            * refers to the first result in the set. Setting both <code>start</code>
1203            * and <code>end</code> to {@link
1204            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1205            * result set.
1206            * </p>
1207            *
1208            * @param groupId the primary key of the group
1209            * @param userId the primary key of the user who created the file
1210            (optionally <code>0</code>)
1211            * @param rootFolderId the primary key of the root folder to begin the
1212            search
1213            * @param start the lower bound of the range of results
1214            * @param end the upper bound of the range of results (not inclusive)
1215            * @return the range of matching file entries ordered by date modified
1216            * @throws PortalException if the group could not be found
1217            * @throws SystemException if a system exception occurred
1218            */
1219            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1220            public java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getGroupFileEntries(
1221                    long groupId, long userId, long rootFolderId, int start, int end)
1222                    throws com.liferay.portal.kernel.exception.PortalException,
1223                            com.liferay.portal.kernel.exception.SystemException;
1224    
1225            /**
1226            * Returns an ordered range of all the file entries in the group starting at
1227            * the root folder that are stored within the Liferay repository. This
1228            * method is primarily used to search for recently modified file entries. It
1229            * can be limited to the file entries modified by a given user.
1230            *
1231            * <p>
1232            * Useful when paginating results. Returns a maximum of <code>end -
1233            * start</code> instances. <code>start</code> and <code>end</code> are not
1234            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1235            * refers to the first result in the set. Setting both <code>start</code>
1236            * and <code>end</code> to {@link
1237            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1238            * result set.
1239            * </p>
1240            *
1241            * @param groupId the primary key of the group
1242            * @param userId the primary key of the user who created the file
1243            (optionally <code>0</code>)
1244            * @param rootFolderId the primary key of the root folder to begin the
1245            search
1246            * @param start the lower bound of the range of results
1247            * @param end the upper bound of the range of results (not inclusive)
1248            * @param obc the comparator to order the file entries (optionally
1249            <code>null</code>)
1250            * @return the range of matching file entries ordered by comparator
1251            <code>obc</code>
1252            * @throws PortalException if the group could not be found
1253            * @throws SystemException if a system exception occurred
1254            */
1255            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1256            public java.util.List<com.liferay.portal.kernel.repository.model.FileEntry> getGroupFileEntries(
1257                    long groupId, long userId, long rootFolderId, int start, int end,
1258                    com.liferay.portal.kernel.util.OrderByComparator obc)
1259                    throws com.liferay.portal.kernel.exception.PortalException,
1260                            com.liferay.portal.kernel.exception.SystemException;
1261    
1262            /**
1263            * Returns the number of file entries in a group starting at the repository
1264            * default parent folder that are stored within the Liferay repository. This
1265            * method is primarily used to search for recently modified file entries. It
1266            * can be limited to the file entries modified by a given user.
1267            *
1268            * @param groupId the primary key of the group
1269            * @param userId the primary key of the user who created the file
1270            (optionally <code>0</code>)
1271            * @return the number of matching file entries
1272            * @throws PortalException if the group could not be found
1273            * @throws SystemException if a system exception occurred
1274            */
1275            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1276            public int getGroupFileEntriesCount(long groupId, long userId)
1277                    throws com.liferay.portal.kernel.exception.PortalException,
1278                            com.liferay.portal.kernel.exception.SystemException;
1279    
1280            /**
1281            * Returns the number of file entries in a group starting at the root folder
1282            * that are stored within the Liferay repository. This method is primarily
1283            * used to search for recently modified file entries. It can be limited to
1284            * the file entries modified by a given user.
1285            *
1286            * @param groupId the primary key of the group
1287            * @param userId the primary key of the user who created the file
1288            (optionally <code>0</code>)
1289            * @param rootFolderId the primary key of the root folder to begin the
1290            search
1291            * @return the number of matching file entries
1292            * @throws PortalException if the group could not be found
1293            * @throws SystemException if a system exception occurred
1294            */
1295            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1296            public int getGroupFileEntriesCount(long groupId, long userId,
1297                    long rootFolderId)
1298                    throws com.liferay.portal.kernel.exception.PortalException,
1299                            com.liferay.portal.kernel.exception.SystemException;
1300    
1301            /**
1302            * Returns all immediate subfolders of the parent folder that are used for
1303            * mounting third-party repositories. This method is only supported by the
1304            * Liferay repository.
1305            *
1306            * @param repositoryId the primary key of the folder's repository
1307            * @param parentFolderId the primary key of the folder's parent folder
1308            * @return the immediate subfolders of the parent folder that are used for
1309            mounting third-party repositories
1310            * @throws PortalException if the repository or parent folder could not be
1311            found
1312            * @throws SystemException if a system exception occurred
1313            */
1314            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1315            public java.util.List<com.liferay.portal.kernel.repository.model.Folder> getMountFolders(
1316                    long repositoryId, long parentFolderId)
1317                    throws com.liferay.portal.kernel.exception.PortalException,
1318                            com.liferay.portal.kernel.exception.SystemException;
1319    
1320            /**
1321            * Returns a range of all the immediate subfolders of the parent folder that
1322            * are used for mounting third-party repositories. This method is only
1323            * supported by the Liferay repository.
1324            *
1325            * <p>
1326            * Useful when paginating results. Returns a maximum of <code>end -
1327            * start</code> instances. <code>start</code> and <code>end</code> are not
1328            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1329            * refers to the first result in the set. Setting both <code>start</code>
1330            * and <code>end</code> to {@link
1331            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1332            * result set.
1333            * </p>
1334            *
1335            * @param repositoryId the primary key of the repository
1336            * @param parentFolderId the primary key of the parent folder
1337            * @param start the lower bound of the range of results
1338            * @param end the upper bound of the range of results (not inclusive)
1339            * @return the range of immediate subfolders of the parent folder that are
1340            used for mounting third-party repositories
1341            * @throws PortalException if the repository or parent folder could not be
1342            found
1343            * @throws SystemException if a system exception occurred
1344            */
1345            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1346            public java.util.List<com.liferay.portal.kernel.repository.model.Folder> getMountFolders(
1347                    long repositoryId, long parentFolderId, int start, int end)
1348                    throws com.liferay.portal.kernel.exception.PortalException,
1349                            com.liferay.portal.kernel.exception.SystemException;
1350    
1351            /**
1352            * Returns an ordered range of all the immediate subfolders of the parent
1353            * folder that are used for mounting third-party repositories. This method
1354            * is only supported by the Liferay repository.
1355            *
1356            * <p>
1357            * Useful when paginating results. Returns a maximum of <code>end -
1358            * start</code> instances. <code>start</code> and <code>end</code> are not
1359            * primary keys, they are indexes in the result set. Thus, <code>0</code>
1360            * refers to the first result in the set. Setting both <code>start</code>
1361            * and <code>end</code> to {@link
1362            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
1363            * result set.
1364            * </p>
1365            *
1366            * @param repositoryId the primary key of the folder's repository
1367            * @param parentFolderId the primary key of the folder's parent folder
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            * @param obc the comparator to order the folders (optionally
1371            <code>null</code>)
1372            * @return the range of immediate subfolders of the parent folder that are
1373            used for mounting third-party repositories ordered by comparator
1374            <code>obc</code>
1375            * @throws PortalException if the repository or parent folder could not be
1376            found
1377            * @throws SystemException if a system exception occurred
1378            */
1379            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1380            public java.util.List<com.liferay.portal.kernel.repository.model.Folder> getMountFolders(
1381                    long repositoryId, long parentFolderId, int start, int end,
1382                    com.liferay.portal.kernel.util.OrderByComparator obc)
1383                    throws com.liferay.portal.kernel.exception.PortalException,
1384                            com.liferay.portal.kernel.exception.SystemException;
1385    
1386            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1387            public void getSubfolderIds(long repositoryId,
1388                    java.util.List<java.lang.Long> folderIds, long folderId)
1389                    throws com.liferay.portal.kernel.exception.PortalException,
1390                            com.liferay.portal.kernel.exception.SystemException;
1391    
1392            /**
1393            * Returns all the descendant folders of the folder with the primary key.
1394            *
1395            * @param repositoryId the primary key of the repository
1396            * @param folderId the primary key of the folder
1397            * @return the descendant folders of the folder with the primary key
1398            * @throws PortalException if the repository or parent folder could not be
1399            found
1400            * @throws SystemException if a system exception occurred
1401            */
1402            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1403            public java.util.List<java.lang.Long> getSubfolderIds(long repositoryId,
1404                    long folderId)
1405                    throws com.liferay.portal.kernel.exception.PortalException,
1406                            com.liferay.portal.kernel.exception.SystemException;
1407    
1408            /**
1409            * Returns descendant folders of the folder with the primary key, optionally
1410            * limiting to one level deep.
1411            *
1412            * @param repositoryId the primary key of the repository
1413            * @param folderId the primary key of the folder
1414            * @param recurse whether to recurse through each subfolder
1415            * @return the descendant folders of the folder with the primary key
1416            * @throws PortalException if the repository or parent folder could not be
1417            found
1418            * @throws SystemException if a system exception occurred
1419            */
1420            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1421            public java.util.List<java.lang.Long> getSubfolderIds(long repositoryId,
1422                    long folderId, boolean recurse)
1423                    throws com.liferay.portal.kernel.exception.PortalException,
1424                            com.liferay.portal.kernel.exception.SystemException;
1425    
1426            /**
1427            * Returns all the temporary file entry names.
1428            *
1429            * @param groupId the primary key of the group
1430            * @param folderId the primary key of the folder where the file entry will
1431            eventually reside
1432            * @param tempFolderName the temporary folder's name
1433            * @return the temporary file entry names
1434            * @throws PortalException if the folder was invalid
1435            * @throws SystemException if a system exception occurred
1436            * @see #addTempFileEntry(long, long, String, String, File)
1437            * @see com.liferay.portal.kernel.util.TempFileUtil
1438            */
1439            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1440            public java.lang.String[] getTempFileEntryNames(long groupId,
1441                    long folderId, java.lang.String tempFolderName)
1442                    throws com.liferay.portal.kernel.exception.PortalException,
1443                            com.liferay.portal.kernel.exception.SystemException;
1444    
1445            /**
1446            * Locks the folder. This method is primarily used by WebDAV.
1447            *
1448            * @param repositoryId the primary key of the repository
1449            * @param folderId the primary key of the folder
1450            * @return the lock object
1451            * @throws PortalException if the repository or folder could not be found
1452            * @throws SystemException if a system exception occurred
1453            */
1454            public com.liferay.portal.model.Lock lockFolder(long repositoryId,
1455                    long folderId)
1456                    throws com.liferay.portal.kernel.exception.PortalException,
1457                            com.liferay.portal.kernel.exception.SystemException;
1458    
1459            /**
1460            * Locks the folder. This method is primarily used by WebDAV.
1461            *
1462            * @param repositoryId the primary key of the repository
1463            * @param folderId the primary key of the folder
1464            * @param owner the owner string for the checkout (optionally
1465            <code>null</code>)
1466            * @param inheritable whether the lock must propagate to descendants
1467            * @param expirationTime the time in milliseconds before the lock expires.
1468            If the value is <code>0</code>, the default expiration time will
1469            be used from <code>portal.properties>.
1470            * @return the lock object
1471            * @throws PortalException if the repository or folder could not be found
1472            * @throws SystemException if a system exception occurred
1473            */
1474            public com.liferay.portal.model.Lock lockFolder(long repositoryId,
1475                    long folderId, java.lang.String owner, boolean inheritable,
1476                    long expirationTime)
1477                    throws com.liferay.portal.kernel.exception.PortalException,
1478                            com.liferay.portal.kernel.exception.SystemException;
1479    
1480            /**
1481            * Moves the file entry to the new folder.
1482            *
1483            * @param fileEntryId the primary key of the file entry
1484            * @param newFolderId the primary key of the new folder
1485            * @param serviceContext the service context to be applied
1486            * @return the file entry
1487            * @throws PortalException if the file entry or the new folder could not be
1488            found
1489            * @throws SystemException if a system exception occurred
1490            */
1491            public com.liferay.portal.kernel.repository.model.FileEntry moveFileEntry(
1492                    long fileEntryId, long newFolderId,
1493                    com.liferay.portal.service.ServiceContext serviceContext)
1494                    throws com.liferay.portal.kernel.exception.PortalException,
1495                            com.liferay.portal.kernel.exception.SystemException;
1496    
1497            /**
1498            * Moves the folder to the new parent folder with the primary key.
1499            *
1500            * @param folderId the primary key of the folder
1501            * @param parentFolderId the primary key of the new parent folder
1502            * @param serviceContext the service context to be applied
1503            * @return the file entry
1504            * @throws PortalException if the folder could not be found
1505            * @throws SystemException if a system exception occurred
1506            */
1507            public com.liferay.portal.kernel.repository.model.Folder moveFolder(
1508                    long folderId, long parentFolderId,
1509                    com.liferay.portal.service.ServiceContext serviceContext)
1510                    throws com.liferay.portal.kernel.exception.PortalException,
1511                            com.liferay.portal.kernel.exception.SystemException;
1512    
1513            /**
1514            * Refreshes the lock for the file entry. This method is primarily used by
1515            * WebDAV.
1516            *
1517            * @param lockUuid the lock's universally unique identifier
1518            * @param expirationTime the time in milliseconds before the lock expires.
1519            If the value is <code>0</code>, the default expiration time will
1520            be used from <code>portal.properties>.
1521            * @return the lock object
1522            * @throws PortalException if the file entry or lock could not be found
1523            * @throws SystemException if a system exception occurred
1524            */
1525            public com.liferay.portal.model.Lock refreshFileEntryLock(
1526                    java.lang.String lockUuid, long expirationTime)
1527                    throws com.liferay.portal.kernel.exception.PortalException,
1528                            com.liferay.portal.kernel.exception.SystemException;
1529    
1530            /**
1531            * Refreshes the lock for the folder. This method is primarily used by
1532            * WebDAV.
1533            *
1534            * @param lockUuid the lock's universally unique identifier
1535            * @param expirationTime the time in milliseconds before the lock expires.
1536            If the value is <code>0</code>, the default expiration time will
1537            be used from <code>portal.properties>.
1538            * @return the lock object
1539            * @throws PortalException if the folder or lock could not be found
1540            * @throws SystemException if a system exception occurred
1541            */
1542            public com.liferay.portal.model.Lock refreshFolderLock(
1543                    java.lang.String lockUuid, long expirationTime)
1544                    throws com.liferay.portal.kernel.exception.PortalException,
1545                            com.liferay.portal.kernel.exception.SystemException;
1546    
1547            /**
1548            * Reverts the file entry to a previous version. A new version will be
1549            * created based on the previous version and metadata.
1550            *
1551            * @param fileEntryId the primary key of the file entry
1552            * @param version the version to revert back to
1553            * @param serviceContext the service context to be applied
1554            * @throws PortalException if the file entry or version could not be found
1555            * @throws SystemException if a system exception occurred
1556            */
1557            public void revertFileEntry(long fileEntryId, java.lang.String version,
1558                    com.liferay.portal.service.ServiceContext serviceContext)
1559                    throws com.liferay.portal.kernel.exception.PortalException,
1560                            com.liferay.portal.kernel.exception.SystemException;
1561    
1562            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1563            public com.liferay.portal.kernel.search.Hits search(long repositoryId,
1564                    com.liferay.portal.kernel.search.SearchContext searchContext)
1565                    throws com.liferay.portal.kernel.search.SearchException;
1566    
1567            @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
1568            public com.liferay.portal.kernel.search.Hits search(long repositoryId,
1569                    com.liferay.portal.kernel.search.SearchContext searchContext,
1570                    com.liferay.portal.kernel.search.Query query)
1571                    throws com.liferay.portal.kernel.search.SearchException;
1572    
1573            /**
1574            * Unlocks the folder. This method is primarily used by WebDAV.
1575            *
1576            * @param repositoryId the primary key of the repository
1577            * @param folderId the primary key of the folder
1578            * @param lockUuid the lock's universally unique identifier
1579            * @throws PortalException if the repository or folder could not be found
1580            * @throws SystemException if a system exception occurred
1581            */
1582            public void unlockFolder(long repositoryId, long folderId,
1583                    java.lang.String lockUuid)
1584                    throws com.liferay.portal.kernel.exception.PortalException,
1585                            com.liferay.portal.kernel.exception.SystemException;
1586    
1587            /**
1588            * Unlocks the folder. This method is primarily used by WebDAV.
1589            *
1590            * @param repositoryId the primary key of the repository
1591            * @param parentFolderId the primary key of the parent folder
1592            * @param name the folder's name
1593            * @param lockUuid the lock's universally unique identifier
1594            * @throws PortalException if the repository or folder could not be found
1595            * @throws SystemException if a system exception occurred
1596            */
1597            public void unlockFolder(long repositoryId, long parentFolderId,
1598                    java.lang.String name, java.lang.String lockUuid)
1599                    throws com.liferay.portal.kernel.exception.PortalException,
1600                            com.liferay.portal.kernel.exception.SystemException;
1601    
1602            /**
1603            * Updates a file entry and associated metadata based on a byte array
1604            * object. If the file data is <code>null</code>, then only the associated
1605            * metadata (i.e., <code>title</code>, <code>description</code>, and
1606            * parameters in the <code>serviceContext</code>) will be updated.
1607            *
1608            * <p>
1609            * This method takes two file names, the <code>sourceFileName</code> and the
1610            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
1611            * name of the actual file being uploaded. The <code>title</code>
1612            * corresponds to a name the client wishes to assign this file after it has
1613            * been uploaded to the portal.
1614            * </p>
1615            *
1616            * @param fileEntryId the primary key of the file entry
1617            * @param sourceFileName the original file's name (optionally
1618            <code>null</code>)
1619            * @param mimeType the file's MIME type (optionally <code>null</code>)
1620            * @param title the new name to be assigned to the file (optionally <code>
1621            null</code>)
1622            * @param description the file's new description
1623            * @param changeLog the file's version change log (optionally
1624            <code>null</code>)
1625            * @param majorVersion whether the new file version is a major version
1626            * @param bytes the file's data (optionally <code>null</code>)
1627            * @param serviceContext the service context to be applied. Can specify the
1628            file entry's asset category IDs, asset tag names, and expando
1629            bridge attributes. In a Liferay repository, it may include:
1630            
1631            <ul>
1632            <li>
1633            fileEntryTypeId - ID for a custom file entry type
1634            </li>
1635            <li>
1636            fieldsMap - mapping for fields associated with a custom file
1637            entry type
1638            </li>
1639            </ul>
1640            * @return the file entry
1641            * @throws PortalException if the file entry could not be found
1642            * @throws SystemException if a system exception occurred
1643            */
1644            public com.liferay.portal.kernel.repository.model.FileEntry updateFileEntry(
1645                    long fileEntryId, java.lang.String sourceFileName,
1646                    java.lang.String mimeType, java.lang.String title,
1647                    java.lang.String description, java.lang.String changeLog,
1648                    boolean majorVersion, byte[] bytes,
1649                    com.liferay.portal.service.ServiceContext serviceContext)
1650                    throws com.liferay.portal.kernel.exception.PortalException,
1651                            com.liferay.portal.kernel.exception.SystemException;
1652    
1653            /**
1654            * Updates a file entry and associated metadata based on a {@link File}
1655            * object. If the file data is <code>null</code>, then only the associated
1656            * metadata (i.e., <code>title</code>, <code>description</code>, and
1657            * parameters in the <code>serviceContext</code>) will be updated.
1658            *
1659            * <p>
1660            * This method takes two file names, the <code>sourceFileName</code> and the
1661            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
1662            * name of the actual file being uploaded. The <code>title</code>
1663            * corresponds to a name the client wishes to assign this file after it has
1664            * been uploaded to the portal.
1665            * </p>
1666            *
1667            * @param fileEntryId the primary key of the file entry
1668            * @param sourceFileName the original file's name (optionally
1669            <code>null</code>)
1670            * @param mimeType the file's MIME type (optionally <code>null</code>)
1671            * @param title the new name to be assigned to the file (optionally <code>
1672            null</code>)
1673            * @param description the file's new description
1674            * @param changeLog the file's version change log (optionally
1675            <code>null</code>)
1676            * @param majorVersion whether the new file version is a major version
1677            * @param file EntryId the primary key of the file entry
1678            * @param serviceContext the service context to be applied. Can specify the
1679            file entry's asset category IDs, asset tag names, and expando
1680            bridge attributes. In a Liferay repository, it may include:
1681            
1682            <ul>
1683            <li>
1684            fileEntryTypeId - ID for a custom file entry type
1685            </li>
1686            <li>
1687            fieldsMap - mapping for fields associated with a custom file
1688            entry type
1689            </li>
1690            </ul>
1691            * @return the file entry
1692            * @throws PortalException if the file entry could not be found
1693            * @throws SystemException if a system exception occurred
1694            */
1695            public com.liferay.portal.kernel.repository.model.FileEntry updateFileEntry(
1696                    long fileEntryId, java.lang.String sourceFileName,
1697                    java.lang.String mimeType, java.lang.String title,
1698                    java.lang.String description, java.lang.String changeLog,
1699                    boolean majorVersion, java.io.File file,
1700                    com.liferay.portal.service.ServiceContext serviceContext)
1701                    throws com.liferay.portal.kernel.exception.PortalException,
1702                            com.liferay.portal.kernel.exception.SystemException;
1703    
1704            /**
1705            * Updates a file entry and associated metadata based on an {@link
1706            * InputStream} object. If the file data is <code>null</code>, then only the
1707            * associated metadata (i.e., <code>title</code>, <code>description</code>,
1708            * and parameters in the <code>serviceContext</code>) will be updated.
1709            *
1710            * <p>
1711            * This method takes two file names, the <code>sourceFileName</code> and the
1712            * <code>title</code>. The <code>sourceFileName</code> corresponds to the
1713            * name of the actual file being uploaded. The <code>title</code>
1714            * corresponds to a name the client wishes to assign this file after it has
1715            * been uploaded to the portal.
1716            * </p>
1717            *
1718            * @param fileEntryId the primary key of the file entry
1719            * @param sourceFileName the original file's name (optionally
1720            <code>null</code>)
1721            * @param mimeType the file's MIME type (optionally <code>null</code>)
1722            * @param title the new name to be assigned to the file (optionally <code>
1723            null</code>)
1724            * @param description the file's new description
1725            * @param changeLog the file's version change log (optionally
1726            <code>null</code>)
1727            * @param majorVersion whether the new file version is a major version
1728            * @param is the file's data (optionally <code>null</code>)
1729            * @param size the file's size (optionally <code>0</code>)
1730            * @param serviceContext the service context to be applied. Can specify the
1731            file entry's asset category IDs, asset tag names, and expando
1732            bridge attributes. In a Liferay repository, it may include:
1733            
1734            <ul>
1735            <li>
1736            fileEntryTypeId - ID for a custom file entry type
1737            </li>
1738            <li>
1739            fieldsMap - mapping for fields associated with a custom file
1740            entry type
1741            </li>
1742            </ul>
1743            * @return the file entry
1744            * @throws PortalException if the file entry could not be found
1745            * @throws SystemException if a system exception occurred
1746            */
1747            public com.liferay.portal.kernel.repository.model.FileEntry updateFileEntry(
1748                    long fileEntryId, java.lang.String sourceFileName,
1749                    java.lang.String mimeType, java.lang.String title,
1750                    java.lang.String description, java.lang.String changeLog,
1751                    boolean majorVersion, java.io.InputStream is, long size,
1752                    com.liferay.portal.service.ServiceContext serviceContext)
1753                    throws com.liferay.portal.kernel.exception.PortalException,
1754                            com.liferay.portal.kernel.exception.SystemException;
1755    
1756            public com.liferay.portal.kernel.repository.model.FileEntry updateFileEntryAndCheckIn(
1757                    long fileEntryId, java.lang.String sourceFileName,
1758                    java.lang.String mimeType, java.lang.String title,
1759                    java.lang.String description, java.lang.String changeLog,
1760                    boolean majorVersion, java.io.File file,
1761                    com.liferay.portal.service.ServiceContext serviceContext)
1762                    throws com.liferay.portal.kernel.exception.PortalException,
1763                            com.liferay.portal.kernel.exception.SystemException;
1764    
1765            public com.liferay.portal.kernel.repository.model.FileEntry updateFileEntryAndCheckIn(
1766                    long fileEntryId, java.lang.String sourceFileName,
1767                    java.lang.String mimeType, java.lang.String title,
1768                    java.lang.String description, java.lang.String changeLog,
1769                    boolean majorVersion, java.io.InputStream is, long size,
1770                    com.liferay.portal.service.ServiceContext serviceContext)
1771                    throws com.liferay.portal.kernel.exception.PortalException,
1772                            com.liferay.portal.kernel.exception.SystemException;
1773    
1774            /**
1775            * Updates a file shortcut to the existing file entry. This method is only
1776            * supported by the Liferay repository.
1777            *
1778            * @param fileShortcutId the primary key of the file shortcut
1779            * @param folderId the primary key of the file shortcut's parent folder
1780            * @param toFileEntryId the primary key of the file shortcut's file entry
1781            * @param serviceContext the service context to be applied. Can specify the
1782            file entry's asset category IDs, asset tag names, and expando
1783            bridge attributes.
1784            * @return the file shortcut
1785            * @throws PortalException if the file shortcut, folder, or file entry could
1786            not be found
1787            * @throws SystemException if a system exception occurred
1788            */
1789            public com.liferay.portlet.documentlibrary.model.DLFileShortcut updateFileShortcut(
1790                    long fileShortcutId, long folderId, long toFileEntryId,
1791                    com.liferay.portal.service.ServiceContext serviceContext)
1792                    throws com.liferay.portal.kernel.exception.PortalException,
1793                            com.liferay.portal.kernel.exception.SystemException;
1794    
1795            /**
1796            * Updates the folder.
1797            *
1798            * @param folderId the primary key of the folder
1799            * @param name the folder's new name
1800            * @param description the folder's new description
1801            * @param serviceContext the service context to be applied. In a Liferay
1802            repository, it may include:
1803            
1804            <ul>
1805            <li>
1806            defaultFileEntryTypeId - the file entry type to default all
1807            Liferay file entries to
1808            </li>
1809            <li>
1810            fileEntryTypeSearchContainerPrimaryKeys - a comma-delimited list
1811            of file entry type primary keys allowed in the given folder and
1812            all descendants
1813            </li>
1814            <li>
1815            overrideFileEntryTypes - boolean specifying whether to override
1816            ancestral folder's restriction of file entry types allowed
1817            </li>
1818            <li>
1819            workflowDefinitionXYZ - the workflow definition name specified
1820            per file entry type. The parameter name must be the string
1821            <code>workflowDefinition</code> appended by the
1822            <code>fileEntryTypeId</code> (optionally <code>0</code>).
1823            </li>
1824            </ul>
1825            * @return the folder
1826            * @throws PortalException if the current or new parent folder could not be
1827            found or if the new parent folder's information was invalid
1828            * @throws SystemException if a system exception occurred
1829            */
1830            public com.liferay.portal.kernel.repository.model.Folder updateFolder(
1831                    long folderId, java.lang.String name, java.lang.String description,
1832                    com.liferay.portal.service.ServiceContext serviceContext)
1833                    throws com.liferay.portal.kernel.exception.PortalException,
1834                            com.liferay.portal.kernel.exception.SystemException;
1835    
1836            /**
1837            * Returns <code>true</code> if the file entry is checked out. This method
1838            * is primarily used by WebDAV.
1839            *
1840            * @param repositoryId the primary key for the repository
1841            * @param fileEntryId the primary key for the file entry
1842            * @param lockUuid the lock's universally unique identifier
1843            * @return <code>true</code> if the file entry is checked out;
1844            <code>false</code> otherwise
1845            * @throws PortalException if the file entry could not be found
1846            * @throws SystemException if a system exception occurred
1847            */
1848            public boolean verifyFileEntryCheckOut(long repositoryId, long fileEntryId,
1849                    java.lang.String lockUuid)
1850                    throws com.liferay.portal.kernel.exception.PortalException,
1851                            com.liferay.portal.kernel.exception.SystemException;
1852    
1853            /**
1854            * Returns <code>true</code> if the inheritable lock exists. This method is
1855            * primarily used by WebDAV.
1856            *
1857            * @param repositoryId the primary key for the repository
1858            * @param folderId the primary key for the folder
1859            * @param lockUuid the lock's universally unique identifier
1860            * @return <code>true</code> if the inheritable lock exists;
1861            <code>false</code> otherwise
1862            * @throws PortalException if the folder could not be found
1863            * @throws SystemException if a system exception occurred
1864            */
1865            public boolean verifyInheritableLock(long repositoryId, long folderId,
1866                    java.lang.String lockUuid)
1867                    throws com.liferay.portal.kernel.exception.PortalException,
1868                            com.liferay.portal.kernel.exception.SystemException;
1869    }