Package com.liferay.social.kernel.model
Class BaseSocialActivityInterpreter
Object
com.liferay.social.kernel.model.BaseSocialActivityInterpreter
- All Implemented Interfaces:
SocialActivityInterpreter
public abstract class BaseSocialActivityInterpreter
extends Object
implements SocialActivityInterpreter
- Author:
- Brian Wing Shun Chan, Ryan Park
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected ResourceBundleLoaderprotected StringaddNoSuchEntryRedirect(String url, String className, long classPK, ServiceContext serviceContext) protected Stringprotected SocialActivityFeedEntrydoInterpret(SocialActivity activity, ServiceContext serviceContext) protected SocialActivityFeedEntrydoInterpret(SocialActivitySet activitySet, ServiceContext serviceContext) protected longgetActivitySetId(long activityId) protected StringgetBody(SocialActivity activity, ServiceContext serviceContext) protected StringgetEntryTitle(SocialActivity activity, ServiceContext serviceContext) protected StringgetGroupName(long groupId, ServiceContext serviceContext) protected StringgetJSONValue(String json, String key) protected StringgetJSONValue(String json, String key, String defaultValue) protected StringgetLink(SocialActivity activity, ServiceContext serviceContext) protected StringgetPath(SocialActivity activity, ServiceContext serviceContext) protected StringgetTitle(SocialActivity activity, ServiceContext serviceContext) protected Object[]getTitleArguments(String groupName, SocialActivity activity, String link, String title, ServiceContext serviceContext) protected StringgetTitlePattern(String groupName, SocialActivity activity) protected StringgetUserName(long userId, ServiceContext serviceContext) protected StringgetViewEntryInTrashURL(String className, long classPK, ServiceContext serviceContext) protected StringgetViewEntryURL(String className, long classPK, ServiceContext serviceContext) booleanhasPermission(PermissionChecker permissionChecker, SocialActivity activity, String actionId, ServiceContext serviceContext) protected booleanhasPermissions(PermissionChecker permissionChecker, SocialActivity activity, String actionId, ServiceContext serviceContext) interpret(SocialActivity activity, ServiceContext serviceContext) interpret(SocialActivitySet activitySet, ServiceContext serviceContext) voidupdateActivitySet(long activityId) protected Stringprotected StringwrapLink(String link, String key, ServiceContext serviceContext) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.liferay.social.kernel.model.SocialActivityInterpreter
getClassNames
-
Constructor Details
-
BaseSocialActivityInterpreter
public BaseSocialActivityInterpreter()
-
-
Method Details
-
getSelector
- Specified by:
getSelectorin interfaceSocialActivityInterpreter
-
hasPermission
public boolean hasPermission(PermissionChecker permissionChecker, SocialActivity activity, String actionId, ServiceContext serviceContext) throws Exception - Specified by:
hasPermissionin interfaceSocialActivityInterpreter- Throws:
Exception
-
interpret
- Specified by:
interpretin interfaceSocialActivityInterpreter
-
interpret
public SocialActivityFeedEntry interpret(SocialActivitySet activitySet, ServiceContext serviceContext) - Specified by:
interpretin interfaceSocialActivityInterpreter
-
updateActivitySet
- Specified by:
updateActivitySetin interfaceSocialActivityInterpreter- Throws:
PortalException
-
acquireResourceBundleLoader
-
addNoSuchEntryRedirect
protected String addNoSuchEntryRedirect(String url, String className, long classPK, ServiceContext serviceContext) throws Exception - Throws:
Exception
-
buildLink
-
doInterpret
protected SocialActivityFeedEntry doInterpret(SocialActivity activity, ServiceContext serviceContext) throws Exception - Throws:
Exception
-
doInterpret
protected SocialActivityFeedEntry doInterpret(SocialActivitySet activitySet, ServiceContext serviceContext) throws Exception - Throws:
Exception
-
getActivitySetId
protected long getActivitySetId(long activityId) -
getBody
- Throws:
Exception
-
getEntryTitle
protected String getEntryTitle(SocialActivity activity, ServiceContext serviceContext) throws Exception - Throws:
Exception
-
getGroupName
-
getJSONValue
-
getJSONValue
-
getLink
- Throws:
Exception
-
getPath
- Throws:
Exception
-
getTitle
- Throws:
Exception
-
getTitleArguments
protected Object[] getTitleArguments(String groupName, SocialActivity activity, String link, String title, ServiceContext serviceContext) throws Exception - Throws:
Exception
-
getTitlePattern
- Throws:
Exception
-
getUserName
-
getViewEntryInTrashURL
protected String getViewEntryInTrashURL(String className, long classPK, ServiceContext serviceContext) throws Exception - Throws:
Exception
-
getViewEntryURL
protected String getViewEntryURL(String className, long classPK, ServiceContext serviceContext) throws Exception - Throws:
Exception
-
hasPermissions
protected boolean hasPermissions(PermissionChecker permissionChecker, SocialActivity activity, String actionId, ServiceContext serviceContext) throws Exception - Throws:
Exception
-
wrapLink
-
wrapLink
-