|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.alfresco.web.extensibility.SlingshotEvaluatorUtil
public class SlingshotEvaluatorUtil
Utility class for evaluators to pick values from the request and get site information etc.
Field Summary | |
---|---|
protected static java.lang.String |
PORTLET_HOST
|
protected static java.lang.String |
PORTLET_URL
|
protected org.springframework.extensions.surf.WebFrameworkServiceRegistry |
serviceRegistry
|
protected static java.lang.String |
SITE
|
protected static java.lang.String |
SITE_PRESET
|
static java.lang.String |
SITE_PRESET_CACHE
|
Constructor Summary | |
---|---|
SlingshotEvaluatorUtil()
|
Method Summary | |
---|---|
protected java.lang.String |
getEvaluatorParam(java.util.Map params,
java.lang.String name,
java.lang.String defaultValue)
Helper for getting an evaluator parameter trimmed OR defaultValue if no value has been provided. |
protected java.lang.Boolean |
getPortletHost(org.springframework.extensions.surf.RequestContext context)
Returns true if we are viewed from inside a portal. |
protected java.lang.String |
getPortletUrl(org.springframework.extensions.surf.RequestContext context)
Returns the portal url if we are inside a portal, otherwise null. |
protected java.lang.String |
getSite(org.springframework.extensions.surf.RequestContext context)
Returns the current site id OR null if we aren't in a site |
protected java.lang.String |
getSitePreset(org.springframework.extensions.surf.RequestContext context,
java.lang.String siteId)
The site's sitePreset OR null if something goes wrong. |
void |
setServiceRegistry(org.springframework.extensions.surf.WebFrameworkServiceRegistry serviceRegistry)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String SITE_PRESET_CACHE
protected static final java.lang.String PORTLET_HOST
protected static final java.lang.String PORTLET_URL
protected static final java.lang.String SITE_PRESET
protected static final java.lang.String SITE
protected org.springframework.extensions.surf.WebFrameworkServiceRegistry serviceRegistry
Constructor Detail |
---|
public SlingshotEvaluatorUtil()
Method Detail |
---|
public void setServiceRegistry(org.springframework.extensions.surf.WebFrameworkServiceRegistry serviceRegistry)
protected java.lang.String getEvaluatorParam(java.util.Map params, java.lang.String name, java.lang.String defaultValue)
params
- name
- defaultValue
-
protected java.lang.Boolean getPortletHost(org.springframework.extensions.surf.RequestContext context)
context
-
protected java.lang.String getPortletUrl(org.springframework.extensions.surf.RequestContext context)
context
-
protected java.lang.String getSite(org.springframework.extensions.surf.RequestContext context)
context
-
protected java.lang.String getSitePreset(org.springframework.extensions.surf.RequestContext context, java.lang.String siteId)
context
- siteId
- The id of the site to retrieve the sitePreset for.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |