public final class ResolverUtil extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
ID_TYPE_FILE |
static int |
ID_TYPE_ID |
static int |
ID_TYPE_RESOURCE |
static int |
ID_TYPE_UUID |
| Modifier and Type | Method and Description |
|---|---|
static com.liferay.journal.model.JournalArticle |
getArticleByArticleID(String articleId,
long groupId) |
static String |
getClassIdByName(String value,
String locationHint) |
static com.liferay.portal.kernel.model.Organization |
getOrganization(String name,
long companyId,
String locationHint) |
static long |
getSiteGroupIdByName(String siteName,
long company,
String locationName) |
static long |
getStructureId(String structureKey,
long groupId,
Class clazz,
boolean includeAncestorStructures) |
static String |
getStructureUUID(String structureKey,
long groupId,
Class clazz) |
static long |
getTemplateId(String templateKey,
long groupId,
Class clazz) |
static String |
getTemplateUUID(String templateKey,
long groupId) |
static com.liferay.portal.kernel.model.UserGroup |
getUserGroup(String name,
long companyId,
String locationHint) |
static String |
lookupAll(long runAsUserId,
long groupId,
long company,
String value,
String resolverHint)
Resolves a value with a given key inside a given content.
|
static String |
lookupArticleWithArticleId(String content,
String locationHint,
long groupId,
long company,
int typeOfId) |
static String |
lookupDDLRecordSetId(String content,
String locationHint,
long groupId,
long company) |
static String |
lookupOrgOrUserGroupIdWithName(String locationHint,
String value,
long company,
boolean uuid,
boolean org) |
static String |
lookupPageIdWithFriendlyUrl(String content,
String locationHint,
long groupId,
long company,
boolean isPrivate,
IdMode mode) |
static String |
lookupSiteIdWithName(String locationHint,
String value,
long company) |
static String |
lookupStructureOrTemplateIdWithKey(String content,
String locationHint,
long groupId,
long company,
boolean uuid,
String commandPrefix,
boolean isTemplate,
Class referredClass) |
static String |
substituteCategoryNameWithCategoryId(String content,
String locationHint,
long groupId,
long company,
long userId) |
static String |
substituteFileReferencesWithURL(String content,
String locationHint,
long groupId,
long company,
long repoId,
long userId,
int refType)
Substitutes all references for documents and media files.
|
public static final int ID_TYPE_ID
public static final int ID_TYPE_UUID
public static final int ID_TYPE_RESOURCE
public static final int ID_TYPE_FILE
public static String lookupAll(long runAsUserId, long groupId, long company, String value, String resolverHint)
runAsUserId - The user id under which the look up is done.groupId - the group id which is used by default for the look up.company - the company id that is used for the default look up.value - the value string in which the occurance of any above resolve
expression is resolved.resolverHint - the resovler hint textually specifies where the value is
from and is used for logging problems or infos on the resolution.public static long getSiteGroupIdByName(String siteName, long company, String locationName)
public static String substituteFileReferencesWithURL(String content, String locationHint, long groupId, long company, long repoId, long userId, int refType)
content - The content of the article.locationHint - A location hint where the substitution is done (for
logging), eg., the file name of the article.groupId - The group id (site) in which scope the article is imported.company - The company id.repoId - The repository id.userId - The id of the importing user.refType - -public static String substituteCategoryNameWithCategoryId(String content, String locationHint, long groupId, long company, long userId)
public static String lookupSiteIdWithName(String locationHint, String value, long company)
public static String lookupOrgOrUserGroupIdWithName(String locationHint, String value, long company, boolean uuid, boolean org)
public static String lookupArticleWithArticleId(String content, String locationHint, long groupId, long company, int typeOfId)
public static String lookupPageIdWithFriendlyUrl(String content, String locationHint, long groupId, long company, boolean isPrivate, IdMode mode)
public static String lookupDDLRecordSetId(String content, String locationHint, long groupId, long company)
public static String lookupStructureOrTemplateIdWithKey(String content, String locationHint, long groupId, long company, boolean uuid, String commandPrefix, boolean isTemplate, Class referredClass)
public static com.liferay.journal.model.JournalArticle getArticleByArticleID(String articleId, long groupId) throws com.liferay.portal.kernel.exception.SystemException
com.liferay.portal.kernel.exception.SystemExceptionpublic static long getStructureId(String structureKey, long groupId, Class clazz, boolean includeAncestorStructures) throws com.liferay.portal.kernel.exception.SystemException, com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.SystemExceptioncom.liferay.portal.kernel.exception.PortalExceptionpublic static String getStructureUUID(String structureKey, long groupId, Class clazz) throws com.liferay.portal.kernel.exception.SystemException, com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.SystemExceptioncom.liferay.portal.kernel.exception.PortalExceptionpublic static long getTemplateId(String templateKey, long groupId, Class clazz) throws com.liferay.portal.kernel.exception.SystemException, com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.SystemExceptioncom.liferay.portal.kernel.exception.PortalExceptionpublic static com.liferay.portal.kernel.model.Organization getOrganization(String name, long companyId, String locationHint)
public static com.liferay.portal.kernel.model.UserGroup getUserGroup(String name, long companyId, String locationHint)
public static String getTemplateUUID(String templateKey, long groupId) throws com.liferay.portal.kernel.exception.SystemException, com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.SystemExceptioncom.liferay.portal.kernel.exception.PortalExceptionCopyright © 2016–2022 Lundegaard a.s.. All rights reserved.