Package com.jalios.jcms.taglib
Class UrlTag
java.lang.Object
javax.servlet.jsp.tagext.TagSupport
javax.servlet.jsp.tagext.BodyTagSupport
com.jalios.jcms.taglib.UrlTag
- All Implemented Interfaces:
Serializable,javax.servlet.jsp.tagext.BodyTag,javax.servlet.jsp.tagext.IterationTag,javax.servlet.jsp.tagext.JspTag,javax.servlet.jsp.tagext.Tag
- Direct Known Subclasses:
LinkTag
public class UrlTag
extends javax.servlet.jsp.tagext.BodyTagSupport
Output an url using the given parameters.
This tag is not a BodyTag but extends BodyTagSupport to allow
the
LinkTag to benefit from all the computation provided
by the UrlTag.- Since:
- jcms-5.7
- Author:
- Olivier Jaquemet
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringUse this request attribute to force a specific base URL to be used in the UrlTag, if this value is specified, it will supercede any other value.Fields inherited from class javax.servlet.jsp.tagext.BodyTagSupport
bodyContentFields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContextFields inherited from interface javax.servlet.jsp.tagext.BodyTag
EVAL_BODY_BUFFERED, EVAL_BODY_TAGFields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAINFields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintintdoEndTag()intprotected StringgetBaseURL(javax.servlet.http.HttpServletRequest request) voidPrints URL using parameter of this tag.voidvoidsetBaseUrl(String baseURL) voidvoidvoidsetParamNames(String[] names) voidsetParamRemove(String[] remove) voidvoidsetParamValues(String[] values) voidsetUpdate(boolean update) Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
doInitBody, getBodyContent, getPreviousOut, release, setBodyContentMethods inherited from class javax.servlet.jsp.tagext.TagSupport
findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setPageContext, setParent, setValueMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface javax.servlet.jsp.tagext.Tag
getParent, setPageContext, setParent
-
Field Details
-
BASE_URL
Use this request attribute to force a specific base URL to be used in the UrlTag, if this value is specified, it will supercede any other value.- See Also:
-
-
Constructor Details
-
UrlTag
public UrlTag()
-
-
Method Details
-
setData
-
setId
- Overrides:
setIdin classjavax.servlet.jsp.tagext.TagSupport
-
setBaseUrl
-
setUpdate
public void setUpdate(boolean update) -
setParamNames
-
setParamValues
-
setParamRemove
-
setParams
-
setAnchor
-
printUrl
public void printUrl(javax.servlet.http.HttpServletRequest request, Writer out, Locale locale) throws Exception Prints URL using parameter of this tag.- Parameters:
request- the current HttpServletRequestout- the current JspWriterlocale- the user Locale- Throws:
Exception- Since:
- jcms-5.7.0
-
getBaseURL
-
doStartTag
public int doStartTag() throws javax.servlet.jsp.JspException- Specified by:
doStartTagin interfacejavax.servlet.jsp.tagext.Tag- Overrides:
doStartTagin classjavax.servlet.jsp.tagext.BodyTagSupport- Throws:
javax.servlet.jsp.JspException
-
doAfterBody
public int doAfterBody() throws javax.servlet.jsp.JspException- Specified by:
doAfterBodyin interfacejavax.servlet.jsp.tagext.IterationTag- Overrides:
doAfterBodyin classjavax.servlet.jsp.tagext.BodyTagSupport- Throws:
javax.servlet.jsp.JspException
-
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
-