use of com.liferay.portal.kernel.repository.RepositoryException in project liferay-ide by liferay.
the class WebServerServlet method _checkFileEntry.
private static void _checkFileEntry(String[] pathArray) throws Exception {
if (pathArray.length == 1) {
long dlFileShortcutId = GetterUtil.getLong(pathArray[0]);
DLFileShortcut dlFileShortcut = DLAppLocalServiceUtil.getFileShortcut(dlFileShortcutId);
DLAppLocalServiceUtil.getFileEntry(dlFileShortcut.getToFileEntryId());
} else if (pathArray.length == 2) {
// Unable to check with UUID because of multiple repositories
} else {
long groupId = GetterUtil.getLong(pathArray[0]);
long folderId = GetterUtil.getLong(pathArray[1]);
String fileName = pathArray[2];
try {
DLAppLocalServiceUtil.getFileEntry(groupId, folderId, fileName);
} catch (RepositoryException re) {
}
}
}
Aggregations