com.liferay.portlet.documentlibrary.util
Class DLUtil
java.lang.Object
com.liferay.portlet.documentlibrary.util.DLUtil
public class DLUtil
- extends Object
Method Summary |
static void |
addPortletBreadcrumbEntries(DLFileShortcut dlFileShortcut,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
|
static void |
addPortletBreadcrumbEntries(FileEntry fileEntry,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
|
static void |
addPortletBreadcrumbEntries(Folder folder,
javax.servlet.http.HttpServletRequest request,
LiferayPortletResponse liferayPortletResponse)
|
static void |
addPortletBreadcrumbEntries(Folder folder,
javax.servlet.http.HttpServletRequest request,
PortletURL portletURL)
|
static void |
addPortletBreadcrumbEntries(Folder folder,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
|
static void |
addPortletBreadcrumbEntries(long folderId,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
|
static int |
compareVersions(String version1,
String version2)
|
static String |
getAbsolutePath(PortletRequest portletRequest,
long folderId)
|
static Set<String> |
getAllMediaGalleryMimeTypes()
|
static String |
getDDMStructureKey(DLFileEntryType dlFileEntryType)
|
static String |
getDDMStructureKey(String fileEntryTypeUuid)
|
static String |
getDeprecatedDDMStructureKey(DLFileEntryType dlFileEntryType)
|
static String |
getDeprecatedDDMStructureKey(long fileEntryTypeId)
|
static String |
getDividedPath(long id)
|
static DL |
getDL()
|
static String |
getDLFileEntryControlPanelLink(PortletRequest portletRequest,
long fileEntryId)
|
static String |
getDLFolderControlPanelLink(PortletRequest portletRequest,
long folderId)
|
static Map<Locale,String> |
getEmailFileEntryAddedBodyMap(PortletPreferences preferences)
|
static boolean |
getEmailFileEntryAddedEnabled(PortletPreferences preferences)
|
static Map<Locale,String> |
getEmailFileEntryAddedSubjectMap(PortletPreferences preferences)
|
static Map<Locale,String> |
getEmailFileEntryUpdatedBodyMap(PortletPreferences preferences)
|
static boolean |
getEmailFileEntryUpdatedEnabled(PortletPreferences preferences)
|
static Map<Locale,String> |
getEmailFileEntryUpdatedSubjectMap(PortletPreferences preferences)
|
static String |
getEmailFromAddress(PortletPreferences preferences,
long companyId)
|
static String |
getEmailFromName(PortletPreferences preferences,
long companyId)
|
static List<Object> |
getEntries(Hits hits)
|
static String |
getFileEntryImage(FileEntry fileEntry,
ThemeDisplay themeDisplay)
|
static Set<Long> |
getFileEntryTypeSubscriptionClassPKs(long userId)
|
static String |
getFileIcon(String extension)
|
static String |
getGenericName(String extension)
|
static String |
getImagePreviewURL(FileEntry fileEntry,
FileVersion fileVersion,
ThemeDisplay themeDisplay)
|
static String |
getImagePreviewURL(FileEntry fileEntry,
ThemeDisplay themeDisplay)
|
static String[] |
getMediaGalleryMimeTypes(PortletPreferences portletPreferences,
PortletRequest portletRequest)
|
static String |
getPreviewURL(FileEntry fileEntry,
FileVersion fileVersion,
ThemeDisplay themeDisplay,
String queryString)
|
static String |
getPreviewURL(FileEntry fileEntry,
FileVersion fileVersion,
ThemeDisplay themeDisplay,
String queryString,
boolean appendToken)
Deprecated. As of 6.2.0, replaced by getPreviewURL(FileEntry,
FileVersion, ThemeDisplay, String, boolean, boolean) |
static String |
getPreviewURL(FileEntry fileEntry,
FileVersion fileVersion,
ThemeDisplay themeDisplay,
String queryString,
boolean appendVersion,
boolean absoluteURL)
|
static OrderByComparator |
getRepositoryModelOrderByComparator(String orderByCol,
String orderByType)
|
static String |
getTempFileId(long id,
String version)
|
static String |
getTempFileId(long id,
String version,
String languageId)
|
static String |
getThumbnailSrc(FileEntry fileEntry,
DLFileShortcut dlFileShortcut,
ThemeDisplay themeDisplay)
|
static String |
getThumbnailSrc(FileEntry fileEntry,
FileVersion fileVersion,
DLFileShortcut dlFileShortcut,
ThemeDisplay themeDisplay)
|
static String |
getThumbnailStyle()
|
static String |
getThumbnailStyle(boolean max,
int margin)
|
static String |
getTitleWithExtension(FileEntry fileEntry)
|
static String |
getTitleWithExtension(String title,
String extension)
|
static String |
getWebDavURL(ThemeDisplay themeDisplay,
Folder folder,
FileEntry fileEntry)
|
static String |
getWebDavURL(ThemeDisplay themeDisplay,
Folder folder,
FileEntry fileEntry,
boolean manualCheckInRequired)
|
static String |
getWebDavURL(ThemeDisplay themeDisplay,
Folder folder,
FileEntry fileEntry,
boolean manualCheckInRequired,
boolean officeExtensionRequired)
|
static boolean |
hasWorkflowDefinitionLink(long companyId,
long groupId,
long folderId,
long fileEntryTypeId)
|
static boolean |
isAutoGeneratedDLFileEntryTypeDDMStructureKey(String ddmStructureKey)
|
static boolean |
isOfficeExtension(String extension)
|
static boolean |
isSubscribedToFileEntryType(long companyId,
long groupId,
long userId,
long fileEntryTypeId)
|
static boolean |
isSubscribedToFolder(long companyId,
long groupId,
long userId,
long folderId)
|
static boolean |
isSubscribedToFolder(long companyId,
long groupId,
long userId,
long folderId,
boolean recursive)
|
static boolean |
isValidVersion(String version)
|
void |
setDL(DL dl)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DLUtil
public DLUtil()
addPortletBreadcrumbEntries
public static void addPortletBreadcrumbEntries(DLFileShortcut dlFileShortcut,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
throws Exception
- Throws:
Exception
addPortletBreadcrumbEntries
public static void addPortletBreadcrumbEntries(FileEntry fileEntry,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
throws Exception
- Throws:
Exception
addPortletBreadcrumbEntries
public static void addPortletBreadcrumbEntries(Folder folder,
javax.servlet.http.HttpServletRequest request,
LiferayPortletResponse liferayPortletResponse)
throws Exception
- Throws:
Exception
addPortletBreadcrumbEntries
public static void addPortletBreadcrumbEntries(Folder folder,
javax.servlet.http.HttpServletRequest request,
PortletURL portletURL)
throws Exception
- Throws:
Exception
addPortletBreadcrumbEntries
public static void addPortletBreadcrumbEntries(Folder folder,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
throws Exception
- Throws:
Exception
addPortletBreadcrumbEntries
public static void addPortletBreadcrumbEntries(long folderId,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
throws Exception
- Throws:
Exception
compareVersions
public static int compareVersions(String version1,
String version2)
getAbsolutePath
public static String getAbsolutePath(PortletRequest portletRequest,
long folderId)
throws PortalException,
SystemException
- Throws:
PortalException
SystemException
getAllMediaGalleryMimeTypes
public static Set<String> getAllMediaGalleryMimeTypes()
getDDMStructureKey
public static String getDDMStructureKey(DLFileEntryType dlFileEntryType)
getDDMStructureKey
public static String getDDMStructureKey(String fileEntryTypeUuid)
getDeprecatedDDMStructureKey
public static String getDeprecatedDDMStructureKey(DLFileEntryType dlFileEntryType)
getDeprecatedDDMStructureKey
public static String getDeprecatedDDMStructureKey(long fileEntryTypeId)
getDividedPath
public static String getDividedPath(long id)
getDL
public static DL getDL()
getDLFileEntryControlPanelLink
public static String getDLFileEntryControlPanelLink(PortletRequest portletRequest,
long fileEntryId)
throws PortalException,
SystemException
- Throws:
PortalException
SystemException
getDLFolderControlPanelLink
public static String getDLFolderControlPanelLink(PortletRequest portletRequest,
long folderId)
throws PortalException,
SystemException
- Throws:
PortalException
SystemException
getEmailFileEntryAddedBodyMap
public static Map<Locale,String> getEmailFileEntryAddedBodyMap(PortletPreferences preferences)
getEmailFileEntryAddedEnabled
public static boolean getEmailFileEntryAddedEnabled(PortletPreferences preferences)
getEmailFileEntryAddedSubjectMap
public static Map<Locale,String> getEmailFileEntryAddedSubjectMap(PortletPreferences preferences)
getEmailFileEntryUpdatedBodyMap
public static Map<Locale,String> getEmailFileEntryUpdatedBodyMap(PortletPreferences preferences)
getEmailFileEntryUpdatedEnabled
public static boolean getEmailFileEntryUpdatedEnabled(PortletPreferences preferences)
getEmailFileEntryUpdatedSubjectMap
public static Map<Locale,String> getEmailFileEntryUpdatedSubjectMap(PortletPreferences preferences)
getEmailFromAddress
public static String getEmailFromAddress(PortletPreferences preferences,
long companyId)
throws SystemException
- Throws:
SystemException
getEmailFromName
public static String getEmailFromName(PortletPreferences preferences,
long companyId)
throws SystemException
- Throws:
SystemException
getEntries
public static List<Object> getEntries(Hits hits)
getFileEntryImage
public static String getFileEntryImage(FileEntry fileEntry,
ThemeDisplay themeDisplay)
getFileEntryTypeSubscriptionClassPKs
public static Set<Long> getFileEntryTypeSubscriptionClassPKs(long userId)
throws SystemException
- Throws:
SystemException
getFileIcon
public static String getFileIcon(String extension)
getGenericName
public static String getGenericName(String extension)
getImagePreviewURL
public static String getImagePreviewURL(FileEntry fileEntry,
FileVersion fileVersion,
ThemeDisplay themeDisplay)
throws Exception
- Throws:
Exception
getImagePreviewURL
public static String getImagePreviewURL(FileEntry fileEntry,
ThemeDisplay themeDisplay)
throws Exception
- Throws:
Exception
getMediaGalleryMimeTypes
public static String[] getMediaGalleryMimeTypes(PortletPreferences portletPreferences,
PortletRequest portletRequest)
getPreviewURL
public static String getPreviewURL(FileEntry fileEntry,
FileVersion fileVersion,
ThemeDisplay themeDisplay,
String queryString)
getPreviewURL
public static String getPreviewURL(FileEntry fileEntry,
FileVersion fileVersion,
ThemeDisplay themeDisplay,
String queryString,
boolean appendToken)
- Deprecated. As of 6.2.0, replaced by
getPreviewURL(FileEntry,
FileVersion, ThemeDisplay, String, boolean, boolean)
getPreviewURL
public static String getPreviewURL(FileEntry fileEntry,
FileVersion fileVersion,
ThemeDisplay themeDisplay,
String queryString,
boolean appendVersion,
boolean absoluteURL)
getRepositoryModelOrderByComparator
public static OrderByComparator getRepositoryModelOrderByComparator(String orderByCol,
String orderByType)
getTempFileId
public static String getTempFileId(long id,
String version)
getTempFileId
public static String getTempFileId(long id,
String version,
String languageId)
getThumbnailSrc
public static String getThumbnailSrc(FileEntry fileEntry,
DLFileShortcut dlFileShortcut,
ThemeDisplay themeDisplay)
throws Exception
- Throws:
Exception
getThumbnailSrc
public static String getThumbnailSrc(FileEntry fileEntry,
FileVersion fileVersion,
DLFileShortcut dlFileShortcut,
ThemeDisplay themeDisplay)
throws Exception
- Throws:
Exception
getThumbnailStyle
public static String getThumbnailStyle()
throws Exception
- Throws:
Exception
getThumbnailStyle
public static String getThumbnailStyle(boolean max,
int margin)
throws Exception
- Throws:
Exception
getTitleWithExtension
public static String getTitleWithExtension(FileEntry fileEntry)
getTitleWithExtension
public static String getTitleWithExtension(String title,
String extension)
getWebDavURL
public static String getWebDavURL(ThemeDisplay themeDisplay,
Folder folder,
FileEntry fileEntry)
throws PortalException,
SystemException
- Throws:
PortalException
SystemException
getWebDavURL
public static String getWebDavURL(ThemeDisplay themeDisplay,
Folder folder,
FileEntry fileEntry,
boolean manualCheckInRequired)
throws PortalException,
SystemException
- Throws:
PortalException
SystemException
getWebDavURL
public static String getWebDavURL(ThemeDisplay themeDisplay,
Folder folder,
FileEntry fileEntry,
boolean manualCheckInRequired,
boolean officeExtensionRequired)
throws PortalException,
SystemException
- Throws:
PortalException
SystemException
hasWorkflowDefinitionLink
public static boolean hasWorkflowDefinitionLink(long companyId,
long groupId,
long folderId,
long fileEntryTypeId)
throws Exception
- Throws:
Exception
isAutoGeneratedDLFileEntryTypeDDMStructureKey
public static boolean isAutoGeneratedDLFileEntryTypeDDMStructureKey(String ddmStructureKey)
isOfficeExtension
public static boolean isOfficeExtension(String extension)
isSubscribedToFileEntryType
public static boolean isSubscribedToFileEntryType(long companyId,
long groupId,
long userId,
long fileEntryTypeId)
throws SystemException
- Throws:
SystemException
isSubscribedToFolder
public static boolean isSubscribedToFolder(long companyId,
long groupId,
long userId,
long folderId)
throws PortalException,
SystemException
- Throws:
PortalException
SystemException
isSubscribedToFolder
public static boolean isSubscribedToFolder(long companyId,
long groupId,
long userId,
long folderId,
boolean recursive)
throws PortalException,
SystemException
- Throws:
PortalException
SystemException
isValidVersion
public static boolean isValidVersion(String version)
setDL
public void setDL(DL dl)