org.broadleafcommerce.cms.web.file
Class UrlRewriteTag

java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by org.broadleafcommerce.cms.web.file.UrlRewriteTag
All Implemented Interfaces:
Serializable, javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.JspTag, javax.servlet.jsp.tagext.Tag

public class UrlRewriteTag
extends javax.servlet.jsp.tagext.TagSupport

Will convert from http/https based on the request. If the URL is based on a BLC-CMS-Asset and the environment specifies a replacement prefix, then the prefix will be set. Populates the page-attribute "assetpath" with the updated url.

See Also:
Serialized Form

Field Summary
static String REQUEST_DTO
           
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
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
UrlRewriteTag()
           
 
Method Summary
 int doEndTag()
           
 int doStartTag()
           
 String getValue()
           
 String getVar()
           
protected  void initServices()
           
protected  boolean isRequestSecure()
          Returns true if the current request.scheme = HTTPS or if the request.isSecure value is true.
 void release()
           
 void setValue(String value)
           
 void setVar(String var)
           
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

REQUEST_DTO

public static final String REQUEST_DTO
See Also:
Constant Field Values
Constructor Detail

UrlRewriteTag

public UrlRewriteTag()
Method Detail

initServices

protected void initServices()

isRequestSecure

protected boolean isRequestSecure()
Returns true if the current request.scheme = HTTPS or if the request.isSecure value is true.

Returns:

doStartTag

public int doStartTag()
               throws javax.servlet.jsp.JspException
Specified by:
doStartTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doStartTag in class javax.servlet.jsp.tagext.TagSupport
Throws:
javax.servlet.jsp.JspException

doEndTag

public int doEndTag()
             throws javax.servlet.jsp.JspException
Specified by:
doEndTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doEndTag in class javax.servlet.jsp.tagext.TagSupport
Throws:
javax.servlet.jsp.JspException

release

public void release()
Specified by:
release in interface javax.servlet.jsp.tagext.Tag
Overrides:
release in class javax.servlet.jsp.tagext.TagSupport

getValue

public String getValue()

setValue

public void setValue(String value)

getVar

public String getVar()

setVar

public void setVar(String var)


Copyright © 2012. All Rights Reserved.