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
060 public InputStream getContentStream()
061 throws PortalException, SystemException;
062
063 public InputStream getContentStream(String version)
064 throws PortalException, SystemException;
065
066 @Override
067 public Date getCreateDate();
068
069 public String getDescription();
070
071 public String getExtension();
072
073 public long getFileEntryId();
074
075
085 public FileVersion getFileVersion() throws PortalException, SystemException;
086
087 public FileVersion getFileVersion(String version)
088 throws PortalException, SystemException;
089
090 public List<FileVersion> getFileVersions(int status)
091 throws SystemException;
092
093 public Folder getFolder();
094
095 public long getFolderId();
096
097 @Override
098 public long getGroupId();
099
100 public String getIcon();
101
102
110 public FileVersion getLatestFileVersion()
111 throws PortalException, SystemException;
112
113 public Lock getLock();
114
115 public String getMimeType();
116
117 public String getMimeType(String version);
118
119 @Override
120 public Date getModifiedDate();
121
122 public int getReadCount();
123
124 public long getRepositoryId();
125
126 public long getSize();
127
128 public String getTitle();
129
130 @Override
131 public long getUserId();
132
133 @Override
134 public String getUserName();
135
136 @Override
137 public String getUserUuid() throws SystemException;
138
139 public String getUuid();
140
141 public String getVersion();
142
143 public long getVersionUserId();
144
145 public String getVersionUserName();
146
147 public String getVersionUserUuid() throws SystemException;
148
149 public boolean hasLock();
150
151 public boolean isCheckedOut();
152
153 public boolean isDefaultRepository();
154
155 public boolean isSupportsLocking();
156
157 public boolean isSupportsMetadata();
158
159 public boolean isSupportsSocial();
160
161 }