001
014
015 package com.liferay.portlet.documentlibrary.service;
016
017 import aQute.bnd.annotation.ProviderType;
018
019 import com.liferay.portal.kernel.exception.PortalException;
020 import com.liferay.portal.kernel.exception.SystemException;
021 import com.liferay.portal.kernel.jsonwebservice.JSONWebService;
022 import com.liferay.portal.kernel.transaction.Isolation;
023 import com.liferay.portal.kernel.transaction.Propagation;
024 import com.liferay.portal.kernel.transaction.Transactional;
025 import com.liferay.portal.security.ac.AccessControlled;
026 import com.liferay.portal.service.BaseService;
027
028
039 @ProviderType
040 @AccessControlled
041 @JSONWebService
042 @Transactional(isolation = Isolation.PORTAL, rollbackFor = {
043 PortalException.class, SystemException.class})
044 public interface DLFileEntryService extends BaseService {
045
050
051
056 public java.lang.String getBeanIdentifier();
057
058
063 public void setBeanIdentifier(java.lang.String beanIdentifier);
064
065 public com.liferay.portlet.documentlibrary.model.DLFileEntry addFileEntry(
066 long groupId, long repositoryId, long folderId,
067 java.lang.String sourceFileName, java.lang.String mimeType,
068 java.lang.String title, java.lang.String description,
069 java.lang.String changeLog, long fileEntryTypeId,
070 java.util.Map<java.lang.String, com.liferay.portlet.dynamicdatamapping.storage.Fields> fieldsMap,
071 java.io.File file, java.io.InputStream is, long size,
072 com.liferay.portal.service.ServiceContext serviceContext)
073 throws com.liferay.portal.kernel.exception.PortalException,
074 com.liferay.portal.kernel.exception.SystemException;
075
076 public com.liferay.portlet.documentlibrary.model.DLFileVersion cancelCheckOut(
077 long fileEntryId)
078 throws com.liferay.portal.kernel.exception.PortalException,
079 com.liferay.portal.kernel.exception.SystemException;
080
081 public void checkInFileEntry(long fileEntryId, boolean major,
082 java.lang.String changeLog,
083 com.liferay.portal.service.ServiceContext serviceContext)
084 throws com.liferay.portal.kernel.exception.PortalException,
085 com.liferay.portal.kernel.exception.SystemException;
086
087
091 public void checkInFileEntry(long fileEntryId, java.lang.String lockUuid)
092 throws com.liferay.portal.kernel.exception.PortalException,
093 com.liferay.portal.kernel.exception.SystemException;
094
095 public void checkInFileEntry(long fileEntryId, java.lang.String lockUuid,
096 com.liferay.portal.service.ServiceContext serviceContext)
097 throws com.liferay.portal.kernel.exception.PortalException,
098 com.liferay.portal.kernel.exception.SystemException;
099
100
104 public com.liferay.portlet.documentlibrary.model.DLFileEntry checkOutFileEntry(
105 long fileEntryId)
106 throws com.liferay.portal.kernel.exception.PortalException,
107 com.liferay.portal.kernel.exception.SystemException;
108
109 public com.liferay.portlet.documentlibrary.model.DLFileEntry checkOutFileEntry(
110 long fileEntryId,
111 com.liferay.portal.service.ServiceContext serviceContext)
112 throws com.liferay.portal.kernel.exception.PortalException,
113 com.liferay.portal.kernel.exception.SystemException;
114
115
119 public com.liferay.portlet.documentlibrary.model.DLFileEntry checkOutFileEntry(
120 long fileEntryId, java.lang.String owner, long expirationTime)
121 throws com.liferay.portal.kernel.exception.PortalException,
122 com.liferay.portal.kernel.exception.SystemException;
123
124 public com.liferay.portlet.documentlibrary.model.DLFileEntry checkOutFileEntry(
125 long fileEntryId, java.lang.String owner, long expirationTime,
126 com.liferay.portal.service.ServiceContext serviceContext)
127 throws com.liferay.portal.kernel.exception.PortalException,
128 com.liferay.portal.kernel.exception.SystemException;
129
130 public com.liferay.portlet.documentlibrary.model.DLFileEntry copyFileEntry(
131 long groupId, long repositoryId, long fileEntryId, long destFolderId,
132 com.liferay.portal.service.ServiceContext serviceContext)
133 throws com.liferay.portal.kernel.exception.PortalException,
134 com.liferay.portal.kernel.exception.SystemException;
135
136 public void deleteFileEntry(long fileEntryId)
137 throws com.liferay.portal.kernel.exception.PortalException,
138 com.liferay.portal.kernel.exception.SystemException;
139
140 public void deleteFileEntry(long groupId, long folderId,
141 java.lang.String title)
142 throws com.liferay.portal.kernel.exception.PortalException,
143 com.liferay.portal.kernel.exception.SystemException;
144
145 public void deleteFileVersion(long fileEntryId, java.lang.String version)
146 throws com.liferay.portal.kernel.exception.PortalException,
147 com.liferay.portal.kernel.exception.SystemException;
148
149 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
150 public com.liferay.portlet.documentlibrary.model.DLFileEntry fetchFileEntryByImageId(
151 long imageId)
152 throws com.liferay.portal.kernel.exception.PortalException,
153 com.liferay.portal.kernel.exception.SystemException;
154
155 public java.io.InputStream getFileAsStream(long fileEntryId,
156 java.lang.String version)
157 throws com.liferay.portal.kernel.exception.PortalException,
158 com.liferay.portal.kernel.exception.SystemException;
159
160 public java.io.InputStream getFileAsStream(long fileEntryId,
161 java.lang.String version, boolean incrementCounter)
162 throws com.liferay.portal.kernel.exception.PortalException,
163 com.liferay.portal.kernel.exception.SystemException;
164
165 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
166 public java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getFileEntries(
167 long groupId, long folderId, int status, int start, int end,
168 com.liferay.portal.kernel.util.OrderByComparator obc)
169 throws com.liferay.portal.kernel.exception.PortalException,
170 com.liferay.portal.kernel.exception.SystemException;
171
172 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
173 public java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getFileEntries(
174 long groupId, long folderId, int start, int end,
175 com.liferay.portal.kernel.util.OrderByComparator obc)
176 throws com.liferay.portal.kernel.exception.PortalException,
177 com.liferay.portal.kernel.exception.SystemException;
178
179 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
180 public java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getFileEntries(
181 long groupId, long folderId, long fileEntryTypeId, int start, int end,
182 com.liferay.portal.kernel.util.OrderByComparator obc)
183 throws com.liferay.portal.kernel.exception.PortalException,
184 com.liferay.portal.kernel.exception.SystemException;
185
186 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
187 public java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getFileEntries(
188 long groupId, long folderId, java.lang.String[] mimeTypes, int start,
189 int end, com.liferay.portal.kernel.util.OrderByComparator obc)
190 throws com.liferay.portal.kernel.exception.PortalException,
191 com.liferay.portal.kernel.exception.SystemException;
192
193 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
194 public int getFileEntriesCount(long groupId, long folderId)
195 throws com.liferay.portal.kernel.exception.SystemException;
196
197 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
198 public int getFileEntriesCount(long groupId, long folderId, int status)
199 throws com.liferay.portal.kernel.exception.SystemException;
200
201 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
202 public int getFileEntriesCount(long groupId, long folderId,
203 long fileEntryTypeId)
204 throws com.liferay.portal.kernel.exception.SystemException;
205
206 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
207 public int getFileEntriesCount(long groupId, long folderId,
208 java.lang.String[] mimeTypes)
209 throws com.liferay.portal.kernel.exception.SystemException;
210
211 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
212 public com.liferay.portlet.documentlibrary.model.DLFileEntry getFileEntry(
213 long fileEntryId)
214 throws com.liferay.portal.kernel.exception.PortalException,
215 com.liferay.portal.kernel.exception.SystemException;
216
217 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
218 public com.liferay.portlet.documentlibrary.model.DLFileEntry getFileEntry(
219 long groupId, long folderId, java.lang.String title)
220 throws com.liferay.portal.kernel.exception.PortalException,
221 com.liferay.portal.kernel.exception.SystemException;
222
223 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
224 public com.liferay.portlet.documentlibrary.model.DLFileEntry getFileEntryByUuidAndGroupId(
225 java.lang.String uuid, long groupId)
226 throws com.liferay.portal.kernel.exception.PortalException,
227 com.liferay.portal.kernel.exception.SystemException;
228
229 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
230 public com.liferay.portal.model.Lock getFileEntryLock(long fileEntryId);
231
232 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
233 public int getFoldersFileEntriesCount(long groupId,
234 java.util.List<java.lang.Long> folderIds, int status)
235 throws com.liferay.portal.kernel.exception.SystemException;
236
237 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
238 public java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getGroupFileEntries(
239 long groupId, long userId, long rootFolderId, int start, int end,
240 com.liferay.portal.kernel.util.OrderByComparator obc)
241 throws com.liferay.portal.kernel.exception.PortalException,
242 com.liferay.portal.kernel.exception.SystemException;
243
244 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
245 public java.util.List<com.liferay.portlet.documentlibrary.model.DLFileEntry> getGroupFileEntries(
246 long groupId, long userId, long rootFolderId,
247 java.lang.String[] mimeTypes, int status, int start, int end,
248 com.liferay.portal.kernel.util.OrderByComparator obc)
249 throws com.liferay.portal.kernel.exception.PortalException,
250 com.liferay.portal.kernel.exception.SystemException;
251
252 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
253 public int getGroupFileEntriesCount(long groupId, long userId,
254 long rootFolderId)
255 throws com.liferay.portal.kernel.exception.PortalException,
256 com.liferay.portal.kernel.exception.SystemException;
257
258 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
259 public int getGroupFileEntriesCount(long groupId, long userId,
260 long rootFolderId, java.lang.String[] mimeTypes, int status)
261 throws com.liferay.portal.kernel.exception.PortalException,
262 com.liferay.portal.kernel.exception.SystemException;
263
264 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
265 public boolean hasFileEntryLock(long fileEntryId)
266 throws com.liferay.portal.kernel.exception.PortalException,
267 com.liferay.portal.kernel.exception.SystemException;
268
269 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
270 public boolean isFileEntryCheckedOut(long fileEntryId)
271 throws com.liferay.portal.kernel.exception.PortalException,
272 com.liferay.portal.kernel.exception.SystemException;
273
274 public com.liferay.portlet.documentlibrary.model.DLFileEntry moveFileEntry(
275 long fileEntryId, long newFolderId,
276 com.liferay.portal.service.ServiceContext serviceContext)
277 throws com.liferay.portal.kernel.exception.PortalException,
278 com.liferay.portal.kernel.exception.SystemException;
279
280 public com.liferay.portal.model.Lock refreshFileEntryLock(
281 java.lang.String lockUuid, long companyId, long expirationTime)
282 throws com.liferay.portal.kernel.exception.PortalException,
283 com.liferay.portal.kernel.exception.SystemException;
284
285 public void revertFileEntry(long fileEntryId, java.lang.String version,
286 com.liferay.portal.service.ServiceContext serviceContext)
287 throws com.liferay.portal.kernel.exception.PortalException,
288 com.liferay.portal.kernel.exception.SystemException;
289
290 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
291 public com.liferay.portal.kernel.search.Hits search(long groupId,
292 long creatorUserId, int status, int start, int end)
293 throws com.liferay.portal.kernel.exception.PortalException,
294 com.liferay.portal.kernel.exception.SystemException;
295
296 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
297 public com.liferay.portal.kernel.search.Hits search(long groupId,
298 long creatorUserId, long folderId, java.lang.String[] mimeTypes,
299 int status, int start, int end)
300 throws com.liferay.portal.kernel.exception.PortalException,
301 com.liferay.portal.kernel.exception.SystemException;
302
303 public com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry(
304 long fileEntryId, java.lang.String sourceFileName,
305 java.lang.String mimeType, java.lang.String title,
306 java.lang.String description, java.lang.String changeLog,
307 boolean majorVersion, long fileEntryTypeId,
308 java.util.Map<java.lang.String, com.liferay.portlet.dynamicdatamapping.storage.Fields> fieldsMap,
309 java.io.File file, java.io.InputStream is, long size,
310 com.liferay.portal.service.ServiceContext serviceContext)
311 throws com.liferay.portal.kernel.exception.PortalException,
312 com.liferay.portal.kernel.exception.SystemException;
313
314 public boolean verifyFileEntryCheckOut(long fileEntryId,
315 java.lang.String lockUuid)
316 throws com.liferay.portal.kernel.exception.PortalException,
317 com.liferay.portal.kernel.exception.SystemException;
318
319 public boolean verifyFileEntryLock(long fileEntryId,
320 java.lang.String lockUuid)
321 throws com.liferay.portal.kernel.exception.PortalException,
322 com.liferay.portal.kernel.exception.SystemException;
323 }