Class DefineObjectsTag
- java.lang.Object
-
- javax.servlet.jsp.tagext.TagSupport
-
- org.apache.sling.scripting.jsp.taglib.DefineObjectsTag
-
- All Implemented Interfaces:
java.io.Serializable
,IterationTag
,JspTag
,Tag
- Direct Known Subclasses:
DefineObjectsTag
public class DefineObjectsTag extends TagSupport
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
DEFAULT_BINDINGS_NAME
Default name for the scripting variable referencing thejavax.script.Bindings
object (value is "bindings").static java.lang.String
DEFAULT_LOG_NAME
Default name for the scripting variable referencing the logorg.slf4j.Logger
(value is "log").static java.lang.String
DEFAULT_NODE_NAME
Default name for the scripting variable referencing the JCR node underlying the currentResource
object if it is based on a JCR node (value is "currentNode").static java.lang.String
DEFAULT_REQUEST_NAME
Default name for the scripting variable referencing theSlingHttpServletRequest
object (value is "slingRequest").static java.lang.String
DEFAULT_RESOURCE_NAME
Default name for the scripting variable referencing the currentResource
object (value is "resource").static java.lang.String
DEFAULT_RESOURCE_RESOLVER_NAME
Default name for the scripting variable referencing the currentResourceResolver
(value is "resourceResolver").static java.lang.String
DEFAULT_RESPONSE_NAME
Default name for the scripting variable referencing theSlingHttpServletResponse
object (value is "slingResponse").static java.lang.String
DEFAULT_SLING_NAME
Default name for the scripting variable referencing the currentSlingScriptHelper
(value is "sling").-
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
-
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
-
-
Constructor Summary
Constructors Constructor Description DefineObjectsTag()
Default constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
doEndTag()
Creates Scripting variables for:SlingHttpServletRequest
SlingHttpServletResponse
currentResource
currentNode
(if resource is adaptable to a node) currentLogger
currentSlingScriptHelper
void
release()
Release state.void
setBindingsName(java.lang.String name)
void
setLogName(java.lang.String name)
void
setNodeName(java.lang.String name)
void
setPageContext(PageContext pageContext)
Set the page context.void
setRequestName(java.lang.String requestName)
void
setResourceName(java.lang.String name)
void
setResourceResolverName(java.lang.String name)
void
setResponseName(java.lang.String responseName)
void
setSlingName(java.lang.String name)
-
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, doStartTag, findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setParent, setValue
-
-
-
-
Field Detail
-
DEFAULT_REQUEST_NAME
public static final java.lang.String DEFAULT_REQUEST_NAME
Default name for the scripting variable referencing theSlingHttpServletRequest
object (value is "slingRequest").- See Also:
- Constant Field Values
-
DEFAULT_RESPONSE_NAME
public static final java.lang.String DEFAULT_RESPONSE_NAME
Default name for the scripting variable referencing theSlingHttpServletResponse
object (value is "slingResponse").- See Also:
- Constant Field Values
-
DEFAULT_RESOURCE_NAME
public static final java.lang.String DEFAULT_RESOURCE_NAME
Default name for the scripting variable referencing the currentResource
object (value is "resource").- See Also:
- Constant Field Values
-
DEFAULT_NODE_NAME
public static final java.lang.String DEFAULT_NODE_NAME
Default name for the scripting variable referencing the JCR node underlying the currentResource
object if it is based on a JCR node (value is "currentNode").- See Also:
- Constant Field Values
-
DEFAULT_BINDINGS_NAME
public static final java.lang.String DEFAULT_BINDINGS_NAME
Default name for the scripting variable referencing thejavax.script.Bindings
object (value is "bindings").- See Also:
- Constant Field Values
-
DEFAULT_LOG_NAME
public static final java.lang.String DEFAULT_LOG_NAME
Default name for the scripting variable referencing the logorg.slf4j.Logger
(value is "log").- See Also:
- Constant Field Values
-
DEFAULT_SLING_NAME
public static final java.lang.String DEFAULT_SLING_NAME
Default name for the scripting variable referencing the currentSlingScriptHelper
(value is "sling").- See Also:
- Constant Field Values
-
DEFAULT_RESOURCE_RESOLVER_NAME
public static final java.lang.String DEFAULT_RESOURCE_RESOLVER_NAME
Default name for the scripting variable referencing the currentResourceResolver
(value is "resourceResolver").- See Also:
- Constant Field Values
-
-
Method Detail
-
doEndTag
public int doEndTag()
Creates Scripting variables for:SlingHttpServletRequest
SlingHttpServletResponse
- current
Resource
- current
Node
(if resource is adaptable to a node) - current
Logger
- current
SlingScriptHelper
- Specified by:
doEndTag
in interfaceTag
- Overrides:
doEndTag
in classTagSupport
- Returns:
- always
Tag.EVAL_PAGE
. - See Also:
Tag.doEndTag()
-
setPageContext
public void setPageContext(PageContext pageContext)
Description copied from class:TagSupport
Set the page context.- Specified by:
setPageContext
in interfaceTag
- Overrides:
setPageContext
in classTagSupport
- Parameters:
pageContext
- The PageContext.- See Also:
Tag.setPageContext(javax.servlet.jsp.PageContext)
-
setRequestName
public void setRequestName(java.lang.String requestName)
-
setResponseName
public void setResponseName(java.lang.String responseName)
-
setResourceName
public void setResourceName(java.lang.String name)
-
setNodeName
public void setNodeName(java.lang.String name)
-
setLogName
public void setLogName(java.lang.String name)
-
setSlingName
public void setSlingName(java.lang.String name)
-
setResourceResolverName
public void setResourceResolverName(java.lang.String name)
-
setBindingsName
public void setBindingsName(java.lang.String name)
-
release
public void release()
Description copied from class:TagSupport
Release state.- Specified by:
release
in interfaceTag
- Overrides:
release
in classTagSupport
- See Also:
Tag.release()
-
-