Package com.composum.sling.cpnl
Class ClientlibTag
- java.lang.Object
-
- javax.servlet.jsp.tagext.TagSupport
-
- javax.servlet.jsp.tagext.BodyTagSupport
-
- com.composum.sling.cpnl.CpnlBodyTagSupport
-
- com.composum.sling.cpnl.ClientlibTag
-
- All Implemented Interfaces:
Serializable,javax.servlet.jsp.tagext.BodyTag,javax.servlet.jsp.tagext.IterationTag,javax.servlet.jsp.tagext.JspTag,javax.servlet.jsp.tagext.Tag
public class ClientlibTag extends CpnlBodyTagSupport
A tag build references to styles and script files. Renders either links to individual files, client libraries containing several embedded files or client library categories containing embedded files for a category of client libraries.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static StringALREADY_EMBEDDEDprotected Stringcategoryprotected Stringpathprotected Objecttestprotected Clientlib.Typetype-
Fields inherited from class com.composum.sling.cpnl.CpnlBodyTagSupport
context, out, request, resource, resourceResolver
-
-
Constructor Summary
Constructors Constructor Description ClientlibTag()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidclear()Reset all member variables to the (default) start values.intdoEndTag()protected booleangetTestResult()evaluates the test expression if present and returns the evaluation result; default: 'true'protected Clientlib.TypegetType()voidsetCategory(String category)voidsetPath(String path)voidsetTest(Object value)the 'test' expression for conditional tagsvoidsetType(String type)-
Methods inherited from class com.composum.sling.cpnl.CpnlBodyTagSupport
createContext, doStartTag, eval, getExpressionUtil, release, setPageContext
-
Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
doAfterBody, doInitBody, getBodyContent, getPreviousOut, setBodyContent
-
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setParent, setValue
-
-
-
-
Field Detail
-
ALREADY_EMBEDDED
public static final String ALREADY_EMBEDDED
- See Also:
- Constant Field Values
-
type
protected Clientlib.Type type
-
path
protected String path
-
category
protected String category
-
test
protected Object test
-
-
Method Detail
-
setType
public void setType(String type)
-
setPath
public void setPath(String path)
-
setCategory
public void setCategory(String category)
-
setTest
public void setTest(Object value)
the 'test' expression for conditional tags
-
getTestResult
protected boolean getTestResult()
evaluates the test expression if present and returns the evaluation result; default: 'true'
-
clear
protected void clear()
Description copied from class:CpnlBodyTagSupportReset all member variables to the (default) start values. Called prior processing the tag and at release time.- Overrides:
clearin classCpnlBodyTagSupport
-
getType
protected Clientlib.Type getType()
-
doEndTag
public int doEndTag() throws javax.servlet.jsp.JspException- Specified by:
doEndTagin interfacejavax.servlet.jsp.tagext.Tag- Overrides:
doEndTagin classjavax.servlet.jsp.tagext.BodyTagSupport- Throws:
javax.servlet.jsp.JspException
-
-