001    /**
002     * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.repository.util;
016    
017    import com.liferay.portal.kernel.exception.PortalException;
018    import com.liferay.portal.kernel.repository.Repository;
019    import com.liferay.portal.kernel.repository.capabilities.Capability;
020    import com.liferay.portal.kernel.repository.model.FileEntry;
021    import com.liferay.portal.kernel.repository.model.FileVersion;
022    import com.liferay.portal.kernel.repository.model.Folder;
023    import com.liferay.portal.kernel.search.Hits;
024    import com.liferay.portal.kernel.search.Query;
025    import com.liferay.portal.kernel.search.SearchContext;
026    import com.liferay.portal.kernel.search.SearchException;
027    import com.liferay.portal.kernel.util.OrderByComparator;
028    import com.liferay.portal.model.Lock;
029    import com.liferay.portal.service.ServiceContext;
030    
031    import java.io.File;
032    import java.io.InputStream;
033    
034    import java.util.List;
035    
036    /**
037     * @author Adolfo P??rez
038     */
039    public class RepositoryWrapper implements Repository {
040    
041            public RepositoryWrapper(Repository repository) {
042                    _repository = repository;
043            }
044    
045            @Override
046            public FileEntry addFileEntry(
047                            long userId, long folderId, String sourceFileName, String mimeType,
048                            String title, String description, String changeLog, File file,
049                            ServiceContext serviceContext)
050                    throws PortalException {
051    
052                    return _repository.addFileEntry(
053                            userId, folderId, sourceFileName, mimeType, title, description,
054                            changeLog, file, serviceContext);
055            }
056    
057            @Override
058            public FileEntry addFileEntry(
059                            long userId, long folderId, String sourceFileName, String mimeType,
060                            String title, String description, String changeLog, InputStream is,
061                            long size, ServiceContext serviceContext)
062                    throws PortalException {
063    
064                    return _repository.addFileEntry(
065                            userId, folderId, sourceFileName, mimeType, title, description,
066                            changeLog, is, size, serviceContext);
067            }
068    
069            /**
070             * @deprecated As of 7.0.0, see {@link #addFileEntry(long, long, String,
071             *             String, String, String, String, File, ServiceContext)}
072             */
073            @Deprecated
074            @Override
075            public FileEntry addFileEntry(
076                            long folderId, String sourceFileName, String mimeType, String title,
077                            String description, String changeLog, File file,
078                            ServiceContext serviceContext)
079                    throws PortalException {
080    
081                    return _repository.addFileEntry(
082                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
083                                    getUserId(),
084                            folderId, sourceFileName, mimeType, title, description, changeLog,
085                            file, serviceContext);
086            }
087    
088            /**
089             * @deprecated As of 7.0.0, see {@link #addFileEntry(long, long, String,
090             *             String, String, String, String, InputStream, long,
091             *             ServiceContext)}
092             */
093            @Deprecated
094            @Override
095            public FileEntry addFileEntry(
096                            long folderId, String sourceFileName, String mimeType, String title,
097                            String description, String changeLog, InputStream is, long size,
098                            ServiceContext serviceContext)
099                    throws PortalException {
100    
101                    return _repository.addFileEntry(
102                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
103                                    getUserId(),
104                            folderId, sourceFileName, mimeType, title, description, changeLog,
105                            is, size, serviceContext);
106            }
107    
108            @Override
109            public Folder addFolder(
110                            long userId, long parentFolderId, String name, String description,
111                            ServiceContext serviceContext)
112                    throws PortalException {
113    
114                    return _repository.addFolder(
115                            userId, parentFolderId, name, description, serviceContext);
116            }
117    
118            /**
119             * @deprecated As of 7.0.0, replaced by {@link #addFolder(long, long,
120             *             String, String, ServiceContext)}
121             */
122            @Deprecated
123            @Override
124            public Folder addFolder(
125                            long parentFolderId, String name, String description,
126                            ServiceContext serviceContext)
127                    throws PortalException {
128    
129                    return _repository.addFolder(
130                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
131                                    getUserId(),
132                            parentFolderId, name, description, serviceContext);
133            }
134    
135            @Override
136            public FileVersion cancelCheckOut(long fileEntryId) throws PortalException {
137                    return _repository.cancelCheckOut(fileEntryId);
138            }
139    
140            /**
141             * @deprecated As of 7.0.0, replaced by {@link #checkInFileEntry(long, long,
142             *             boolean, String, ServiceContext)}
143             */
144            @Deprecated
145            @Override
146            public void checkInFileEntry(
147                            long fileEntryId, boolean major, String changeLog,
148                            ServiceContext serviceContext)
149                    throws PortalException {
150    
151                    _repository.checkInFileEntry(
152                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
153                                    getUserId(),
154                            fileEntryId, major, changeLog, serviceContext);
155            }
156    
157            @Override
158            public void checkInFileEntry(
159                            long userId, long fileEntryId, boolean major, String changeLog,
160                            ServiceContext serviceContext)
161                    throws PortalException {
162    
163                    _repository.checkInFileEntry(
164                            userId, fileEntryId, major, changeLog, serviceContext);
165            }
166    
167            @Override
168            public void checkInFileEntry(
169                            long userId, long fileEntryId, String lockUuid,
170                            ServiceContext serviceContext)
171                    throws PortalException {
172    
173                    _repository.checkInFileEntry(
174                            userId, fileEntryId, lockUuid, serviceContext);
175            }
176    
177            @Deprecated
178            @Override
179            public void checkInFileEntry(long fileEntryId, String lockUuid)
180                    throws PortalException {
181    
182                    _repository.checkInFileEntry(
183                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
184                                    getUserId(),
185                            fileEntryId, lockUuid, new ServiceContext());
186            }
187    
188            /**
189             * @deprecated As of 7.0.0, replaced by {@link #checkInFileEntry(long, long,
190             *             String, ServiceContext)}
191             */
192            @Deprecated
193            @Override
194            public void checkInFileEntry(
195                            long fileEntryId, String lockUuid, ServiceContext serviceContext)
196                    throws PortalException {
197    
198                    _repository.checkInFileEntry(
199                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
200                                    getUserId(),
201                            fileEntryId, lockUuid, serviceContext);
202            }
203    
204            @Override
205            public FileEntry checkOutFileEntry(
206                            long fileEntryId, ServiceContext serviceContext)
207                    throws PortalException {
208    
209                    return _repository.checkOutFileEntry(fileEntryId, serviceContext);
210            }
211    
212            @Override
213            public FileEntry checkOutFileEntry(
214                            long fileEntryId, String owner, long expirationTime,
215                            ServiceContext serviceContext)
216                    throws PortalException {
217    
218                    return _repository.checkOutFileEntry(
219                            fileEntryId, owner, expirationTime, serviceContext);
220            }
221    
222            @Override
223            public FileEntry copyFileEntry(
224                            long userId, long groupId, long fileEntryId, long destFolderId,
225                            ServiceContext serviceContext)
226                    throws PortalException {
227    
228                    return _repository.copyFileEntry(
229                            userId, groupId, fileEntryId, destFolderId, serviceContext);
230            }
231    
232            /**
233             * @deprecated As of 7.0.0, replaced by {@link #copyFileEntry(long, long,
234             *             long, long, ServiceContext)}
235             */
236            @Deprecated
237            @Override
238            public FileEntry copyFileEntry(
239                            long groupId, long fileEntryId, long destFolderId,
240                            ServiceContext serviceContext)
241                    throws PortalException {
242    
243                    return _repository.copyFileEntry(
244                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
245                                    getUserId(),
246                            groupId, fileEntryId, destFolderId, serviceContext);
247            }
248    
249            @Override
250            public void deleteAll() throws PortalException {
251                    _repository.deleteAll();
252            }
253    
254            @Override
255            public void deleteFileEntry(long fileEntryId) throws PortalException {
256                    _repository.deleteFileEntry(fileEntryId);
257            }
258    
259            @Override
260            public void deleteFileEntry(long folderId, String title)
261                    throws PortalException {
262    
263                    _repository.deleteFileEntry(folderId, title);
264            }
265    
266            @Override
267            public void deleteFileVersion(long fileEntryId, String version)
268                    throws PortalException {
269    
270                    _repository.deleteFileVersion(fileEntryId, version);
271            }
272    
273            @Override
274            public void deleteFolder(long folderId) throws PortalException {
275                    _repository.deleteFolder(folderId);
276            }
277    
278            @Override
279            public void deleteFolder(long parentFolderId, String name)
280                    throws PortalException {
281    
282                    _repository.deleteFolder(parentFolderId, name);
283            }
284    
285            @Override
286            public <T extends Capability> T getCapability(Class<T> capabilityClass) {
287                    return _repository.getCapability(capabilityClass);
288            }
289    
290            @Override
291            public List<FileEntry> getFileEntries(
292                            long folderId, int start, int end, OrderByComparator<FileEntry> obc)
293                    throws PortalException {
294    
295                    return _repository.getFileEntries(folderId, start, end, obc);
296            }
297    
298            @Override
299            public List<FileEntry> getFileEntries(
300                            long folderId, long fileEntryTypeId, int start, int end,
301                            OrderByComparator<FileEntry> obc)
302                    throws PortalException {
303    
304                    return _repository.getFileEntries(
305                            folderId, fileEntryTypeId, start, end, obc);
306            }
307    
308            @Override
309            public List<FileEntry> getFileEntries(
310                            long folderId, String[] mimeTypes, int start, int end,
311                            OrderByComparator<FileEntry> obc)
312                    throws PortalException {
313    
314                    return _repository.getFileEntries(folderId, mimeTypes, start, end, obc);
315            }
316    
317            @Override
318            public List<Object> getFileEntriesAndFileShortcuts(
319                            long folderId, int status, int start, int end)
320                    throws PortalException {
321    
322                    return _repository.getFileEntriesAndFileShortcuts(
323                            folderId, status, start, end);
324            }
325    
326            @Override
327            public int getFileEntriesAndFileShortcutsCount(long folderId, int status)
328                    throws PortalException {
329    
330                    return _repository.getFileEntriesAndFileShortcutsCount(
331                            folderId, status);
332            }
333    
334            @Override
335            public int getFileEntriesAndFileShortcutsCount(
336                            long folderId, int status, String[] mimeTypes)
337                    throws PortalException {
338    
339                    return _repository.getFileEntriesAndFileShortcutsCount(
340                            folderId, status, mimeTypes);
341            }
342    
343            @Override
344            public int getFileEntriesCount(long folderId) throws PortalException {
345                    return _repository.getFileEntriesCount(folderId);
346            }
347    
348            @Override
349            public int getFileEntriesCount(long folderId, long fileEntryTypeId)
350                    throws PortalException {
351    
352                    return _repository.getFileEntriesCount(folderId, fileEntryTypeId);
353            }
354    
355            @Override
356            public int getFileEntriesCount(long folderId, String[] mimeTypes)
357                    throws PortalException {
358    
359                    return _repository.getFileEntriesCount(folderId, mimeTypes);
360            }
361    
362            @Override
363            public FileEntry getFileEntry(long fileEntryId) throws PortalException {
364                    return _repository.getFileEntry(fileEntryId);
365            }
366    
367            @Override
368            public FileEntry getFileEntry(long folderId, String title)
369                    throws PortalException {
370    
371                    return _repository.getFileEntry(folderId, title);
372            }
373    
374            @Override
375            public FileEntry getFileEntryByUuid(String uuid) throws PortalException {
376                    return _repository.getFileEntryByUuid(uuid);
377            }
378    
379            @Override
380            public FileVersion getFileVersion(long fileVersionId)
381                    throws PortalException {
382    
383                    return _repository.getFileVersion(fileVersionId);
384            }
385    
386            @Override
387            public Folder getFolder(long folderId) throws PortalException {
388                    return _repository.getFolder(folderId);
389            }
390    
391            @Override
392            public Folder getFolder(long parentFolderId, String name)
393                    throws PortalException {
394    
395                    return _repository.getFolder(parentFolderId, name);
396            }
397    
398            @Override
399            public List<Folder> getFolders(
400                            long parentFolderId, boolean includeMountFolders, int start,
401                            int end, OrderByComparator<Folder> obc)
402                    throws PortalException {
403    
404                    return _repository.getFolders(
405                            parentFolderId, includeMountFolders, start, end, obc);
406            }
407    
408            @Override
409            public List<Folder> getFolders(
410                            long parentFolderId, int status, boolean includeMountFolders,
411                            int start, int end, OrderByComparator<Folder> obc)
412                    throws PortalException {
413    
414                    return _repository.getFolders(
415                            parentFolderId, status, includeMountFolders, start, end, obc);
416            }
417    
418            @Override
419            public List<Object> getFoldersAndFileEntriesAndFileShortcuts(
420                            long folderId, int status, boolean includeMountFolders, int start,
421                            int end, OrderByComparator<?> obc)
422                    throws PortalException {
423    
424                    return _repository.getFoldersAndFileEntriesAndFileShortcuts(
425                            folderId, status, includeMountFolders, start, end, obc);
426            }
427    
428            @Override
429            public List<Object> getFoldersAndFileEntriesAndFileShortcuts(
430                            long folderId, int status, String[] mimetypes,
431                            boolean includeMountFolders, int start, int end,
432                            OrderByComparator<?> obc)
433                    throws PortalException {
434    
435                    return _repository.getFoldersAndFileEntriesAndFileShortcuts(
436                            folderId, status, mimetypes, includeMountFolders, start, end, obc);
437            }
438    
439            @Override
440            public int getFoldersAndFileEntriesAndFileShortcutsCount(
441                            long folderId, int status, boolean includeMountFolders)
442                    throws PortalException {
443    
444                    return _repository.getFoldersAndFileEntriesAndFileShortcutsCount(
445                            folderId, status, includeMountFolders);
446            }
447    
448            @Override
449            public int getFoldersAndFileEntriesAndFileShortcutsCount(
450                            long folderId, int status, String[] mimetypes,
451                            boolean includeMountFolders)
452                    throws PortalException {
453    
454                    return _repository.getFoldersAndFileEntriesAndFileShortcutsCount(
455                            folderId, status, mimetypes, includeMountFolders);
456            }
457    
458            @Override
459            public int getFoldersCount(long parentFolderId, boolean includeMountfolders)
460                    throws PortalException {
461    
462                    return _repository.getFoldersCount(parentFolderId, includeMountfolders);
463            }
464    
465            @Override
466            public int getFoldersCount(
467                            long parentFolderId, int status, boolean includeMountfolders)
468                    throws PortalException {
469    
470                    return _repository.getFoldersCount(
471                            parentFolderId, status, includeMountfolders);
472            }
473    
474            @Override
475            public int getFoldersFileEntriesCount(List<Long> folderIds, int status)
476                    throws PortalException {
477    
478                    return _repository.getFoldersFileEntriesCount(folderIds, status);
479            }
480    
481            @Override
482            public List<Folder> getMountFolders(
483                            long parentFolderId, int start, int end,
484                            OrderByComparator<Folder> obc)
485                    throws PortalException {
486    
487                    return _repository.getMountFolders(parentFolderId, start, end, obc);
488            }
489    
490            @Override
491            public int getMountFoldersCount(long parentFolderId)
492                    throws PortalException {
493    
494                    return _repository.getMountFoldersCount(parentFolderId);
495            }
496    
497            @Override
498            public List<FileEntry> getRepositoryFileEntries(
499                            long userId, long rootFolderId, int start, int end,
500                            OrderByComparator<FileEntry> obc)
501                    throws PortalException {
502    
503                    return _repository.getRepositoryFileEntries(
504                            userId, rootFolderId, start, end, obc);
505            }
506    
507            @Override
508            public List<FileEntry> getRepositoryFileEntries(
509                            long userId, long rootFolderId, String[] mimeTypes, int status,
510                            int start, int end, OrderByComparator<FileEntry> obc)
511                    throws PortalException {
512    
513                    return _repository.getRepositoryFileEntries(
514                            userId, rootFolderId, mimeTypes, status, start, end, obc);
515            }
516    
517            @Override
518            public int getRepositoryFileEntriesCount(long userId, long rootFolderId)
519                    throws PortalException {
520    
521                    return _repository.getRepositoryFileEntriesCount(userId, rootFolderId);
522            }
523    
524            @Override
525            public int getRepositoryFileEntriesCount(
526                            long userId, long rootFolderId, String[] mimeTypes, int status)
527                    throws PortalException {
528    
529                    return _repository.getRepositoryFileEntriesCount(
530                            userId, rootFolderId, mimeTypes, status);
531            }
532    
533            @Override
534            public long getRepositoryId() {
535                    return _repository.getRepositoryId();
536            }
537    
538            @Override
539            public void getSubfolderIds(List<Long> folderIds, long folderId)
540                    throws PortalException {
541    
542                    _repository.getSubfolderIds(folderIds, folderId);
543            }
544    
545            @Override
546            public List<Long> getSubfolderIds(long folderId, boolean recurse)
547                    throws PortalException {
548    
549                    return _repository.getSubfolderIds(folderId, recurse);
550            }
551    
552            @Override
553            public <T extends Capability> boolean isCapabilityProvided(
554                    Class<T> capabilityClass) {
555    
556                    return _repository.isCapabilityProvided(capabilityClass);
557            }
558    
559            @Deprecated
560            @Override
561            public Lock lockFileEntry(long fileEntryId) throws PortalException {
562                    return _repository.lockFileEntry(fileEntryId);
563            }
564    
565            @Deprecated
566            @Override
567            public Lock lockFileEntry(
568                            long fileEntryId, String owner, long expirationTime)
569                    throws PortalException {
570    
571                    return _repository.lockFileEntry(fileEntryId, owner, expirationTime);
572            }
573    
574            @Override
575            public Lock lockFolder(long folderId) throws PortalException {
576                    return _repository.lockFolder(folderId);
577            }
578    
579            @Override
580            public Lock lockFolder(
581                            long folderId, String owner, boolean inheritable,
582                            long expirationTime)
583                    throws PortalException {
584    
585                    return _repository.lockFolder(
586                            folderId, owner, inheritable, expirationTime);
587            }
588    
589            @Override
590            public FileEntry moveFileEntry(
591                            long userId, long fileEntryId, long newFolderId,
592                            ServiceContext serviceContext)
593                    throws PortalException {
594    
595                    return _repository.moveFileEntry(
596                            userId, fileEntryId, newFolderId, serviceContext);
597            }
598    
599            /**
600             * @deprecated As of 7.0.0, replaced by {@link #moveFileEntry(long, long,
601             *             long, ServiceContext)}
602             */
603            @Deprecated
604            @Override
605            public FileEntry moveFileEntry(
606                            long fileEntryId, long newFolderId, ServiceContext serviceContext)
607                    throws PortalException {
608    
609                    return _repository.moveFileEntry(
610                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
611                                    getUserId(),
612                            fileEntryId, newFolderId, serviceContext);
613            }
614    
615            @Override
616            public Folder moveFolder(
617                            long userId, long folderId, long parentFolderId,
618                            ServiceContext serviceContext)
619                    throws PortalException {
620    
621                    return _repository.moveFolder(
622                            userId, folderId, parentFolderId, serviceContext);
623            }
624    
625            /**
626             * @deprecated As of 7.0.0, replaced by {@link #moveFolder(long, long, long,
627             *             ServiceContext)}
628             */
629            @Deprecated
630            @Override
631            public Folder moveFolder(
632                            long folderId, long newParentFolderId,
633                            ServiceContext serviceContext)
634                    throws PortalException {
635    
636                    return _repository.moveFolder(
637                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
638                                    getUserId(),
639                            newParentFolderId, serviceContext);
640            }
641    
642            @Override
643            public Lock refreshFileEntryLock(
644                            String lockUuid, long companyId, long expirationTime)
645                    throws PortalException {
646    
647                    return _repository.refreshFileEntryLock(
648                            lockUuid, companyId, expirationTime);
649            }
650    
651            @Override
652            public Lock refreshFolderLock(
653                            String lockUuid, long companyId, long expirationTime)
654                    throws PortalException {
655    
656                    return _repository.refreshFolderLock(
657                            lockUuid, companyId, expirationTime);
658            }
659    
660            @Override
661            public void revertFileEntry(
662                            long userId, long fileEntryId, String version,
663                            ServiceContext serviceContext)
664                    throws PortalException {
665    
666                    _repository.revertFileEntry(
667                            userId, fileEntryId, version, serviceContext);
668            }
669    
670            /**
671             * @deprecated As of 7.0.0, replaced by {@link #revertFileEntry(long, long,
672             *             String, ServiceContext)}
673             */
674            @Deprecated
675            @Override
676            public void revertFileEntry(
677                            long fileEntryId, String version, ServiceContext serviceContext)
678                    throws PortalException {
679    
680                    _repository.revertFileEntry(
681                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
682                                    getUserId(),
683                            fileEntryId, version, serviceContext);
684            }
685    
686            @Override
687            public Hits search(long creatorUserId, int status, int start, int end)
688                    throws PortalException {
689    
690                    return _repository.search(creatorUserId, status, start, end);
691            }
692    
693            @Override
694            public Hits search(
695                            long creatorUserId, long folderId, String[] mimeTypes, int status,
696                            int start, int end)
697                    throws PortalException {
698    
699                    return _repository.search(
700                            creatorUserId, folderId, mimeTypes, status, start, end);
701            }
702    
703            @Override
704            public Hits search(SearchContext searchContext) throws SearchException {
705                    return _repository.search(searchContext);
706            }
707    
708            @Override
709            public Hits search(SearchContext searchContext, Query query)
710                    throws SearchException {
711    
712                    return _repository.search(searchContext, query);
713            }
714    
715            @Override
716            public void unlockFolder(long folderId, String lockUuid)
717                    throws PortalException {
718    
719                    _repository.unlockFolder(folderId, lockUuid);
720            }
721    
722            @Override
723            public void unlockFolder(long parentFolderId, String name, String lockUuid)
724                    throws PortalException {
725    
726                    _repository.unlockFolder(parentFolderId, name, lockUuid);
727            }
728    
729            @Override
730            public FileEntry updateFileEntry(
731                            long userId, long fileEntryId, String sourceFileName,
732                            String mimeType, String title, String description, String changeLog,
733                            boolean majorVersion, File file, ServiceContext serviceContext)
734                    throws PortalException {
735    
736                    return _repository.updateFileEntry(
737                            userId, fileEntryId, sourceFileName, mimeType, title, description,
738                            changeLog, majorVersion, file, serviceContext);
739            }
740    
741            @Override
742            public FileEntry updateFileEntry(
743                            long userId, long fileEntryId, String sourceFileName,
744                            String mimeType, String title, String description, String changeLog,
745                            boolean majorVersion, InputStream is, long size,
746                            ServiceContext serviceContext)
747                    throws PortalException {
748    
749                    return _repository.updateFileEntry(
750                            userId, fileEntryId, sourceFileName, mimeType, title, description,
751                            changeLog, majorVersion, is, size, serviceContext);
752            }
753    
754            /**
755             * @deprecated As of 7.0.0, replaced by {@link #updateFileEntry(long, long,
756             *             String, String, String, String, String, boolean, File,
757             *             ServiceContext)}
758             */
759            @Deprecated
760            @Override
761            public FileEntry updateFileEntry(
762                            long fileEntryId, String sourceFileName, String mimeType,
763                            String title, String description, String changeLog,
764                            boolean majorVersion, File file, ServiceContext serviceContext)
765                    throws PortalException {
766    
767                    return _repository.updateFileEntry(
768                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
769                                    getUserId(),
770                            fileEntryId, sourceFileName, mimeType, title, description,
771                            changeLog, majorVersion, file, serviceContext);
772            }
773    
774            /**
775             * @deprecated As of 7.0.0, replaced by {@link #updateFileEntry(long, long,
776             *             String, String, String, String, String, boolean, InputStream,
777             *             long, ServiceContext)}
778             */
779            @Deprecated
780            @Override
781            public FileEntry updateFileEntry(
782                            long fileEntryId, String sourceFileName, String mimeType,
783                            String title, String description, String changeLog,
784                            boolean majorVersion, InputStream is, long size,
785                            ServiceContext serviceContext)
786                    throws PortalException {
787    
788                    return _repository.updateFileEntry(
789                            com.liferay.portal.kernel.repository.util.RepositoryUserUtil.
790                                    getUserId(),
791                            fileEntryId, sourceFileName, mimeType, title, description,
792                            changeLog, majorVersion, is, size, serviceContext);
793            }
794    
795            @Override
796            public Folder updateFolder(
797                            long folderId, long parentFolderId, String name, String description,
798                            ServiceContext serviceContext)
799                    throws PortalException {
800    
801                    return _repository.updateFolder(
802                            folderId, parentFolderId, name, description, serviceContext);
803            }
804    
805            @Override
806            public Folder updateFolder(
807                            long folderId, String name, String description,
808                            ServiceContext serviceContext)
809                    throws PortalException {
810    
811                    return _repository.updateFolder(
812                            folderId, name, description, serviceContext);
813            }
814    
815            @Override
816            public boolean verifyFileEntryCheckOut(long fileEntryId, String lockUuid)
817                    throws PortalException {
818    
819                    return _repository.verifyFileEntryCheckOut(fileEntryId, lockUuid);
820            }
821    
822            @Override
823            public boolean verifyFileEntryLock(long fileEntryId, String lockUuid)
824                    throws PortalException {
825    
826                    return _repository.verifyFileEntryLock(fileEntryId, lockUuid);
827            }
828    
829            @Override
830            public boolean verifyInheritableLock(long folderId, String lockUuid)
831                    throws PortalException {
832    
833                    return _repository.verifyInheritableLock(folderId, lockUuid);
834            }
835    
836            private final Repository _repository;
837    
838    }