001
014
015 package com.liferay.portal.kernel.repository.model;
016
017 import com.liferay.portal.kernel.exception.PortalException;
018 import com.liferay.portal.kernel.exception.SystemException;
019 import com.liferay.portal.kernel.util.Accessor;
020 import com.liferay.portal.model.Lock;
021 import com.liferay.portal.security.permission.PermissionChecker;
022
023 import java.io.InputStream;
024
025 import java.util.Date;
026 import java.util.List;
027
028
031 public interface FileEntry extends RepositoryModel<FileEntry> {
032
033 public static final Accessor<FileEntry, Long> FILE_ENTRY_ID_ACCESSOR =
034
035 new Accessor<FileEntry, Long>() {
036
037 @Override
038 public Long get(FileEntry fileEntry) {
039 return fileEntry.getFileEntryId();
040 }
041
042 };
043
044 public boolean containsPermission(
045 PermissionChecker permissionChecker, String actionId)
046 throws PortalException, SystemException;
047
048 @Override
049 public long getCompanyId();
050
051
062 public InputStream getContentStream()
063 throws PortalException, SystemException;
064
065 public InputStream getContentStream(String version)
066 throws PortalException, SystemException;
067
068 @Override
069 public Date getCreateDate();
070
071 public String getDescription();
072
073 public String getExtension();
074
075 public long getFileEntryId();
076
077
089 public FileVersion getFileVersion() throws PortalException, SystemException;
090
091 public FileVersion getFileVersion(String version)
092 throws PortalException, SystemException;
093
094 public List<FileVersion> getFileVersions(int status)
095 throws SystemException;
096
097 public Folder getFolder();
098
099 public long getFolderId();
100
101 @Override
102 public long getGroupId();
103
104 public String getIcon();
105
106
116 public FileVersion getLatestFileVersion()
117 throws PortalException, SystemException;
118
119 public Lock getLock();
120
121 public String getMimeType();
122
123 public String getMimeType(String version);
124
125 @Override
126 public Date getModifiedDate();
127
128 public int getReadCount();
129
130 public long getRepositoryId();
131
132 public long getSize();
133
134 public String getTitle();
135
136 @Override
137 public long getUserId();
138
139 @Override
140 public String getUserName();
141
142 @Override
143 public String getUserUuid() throws SystemException;
144
145 @Override
146 public String getUuid();
147
148 public String getVersion();
149
150 public long getVersionUserId();
151
152 public String getVersionUserName();
153
154 public String getVersionUserUuid() throws SystemException;
155
156 public boolean hasLock();
157
158 public boolean isCheckedOut();
159
160 public boolean isDefaultRepository();
161
162 public boolean isInTrash();
163
164 public boolean isInTrashContainer();
165
166 public boolean isManualCheckInRequired();
167
168 public boolean isSupportsLocking();
169
170 public boolean isSupportsMetadata();
171
172 public boolean isSupportsSocial();
173
174 }