java.lang.Object
javax.servlet.jsp.tagext.TagSupport
com.opencms.flex.jsp.CmsJspTagInfo
- All Implemented Interfaces:
- javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.JspTag, java.io.Serializable, javax.servlet.jsp.tagext.Tag
- public class CmsJspTagInfo
- extends javax.servlet.jsp.tagext.TagSupport
Provides access to OpenCms and System related information.
This tag supports the following special "property" values:
opencms.version returns the current OpenCms version, e.g. 5.0 Kaitain
opencms.url returns the current request URL, e.g.
http://localhost:8080/opencms/opencms/index.jsp
opencms.uri returns the current request URI, e.g.
/opencms/opencms/index.jsp
opencms.webapp returns the name of the OpenCms web application, e.g.
opencms
opencms.webbasepath returns the name of system path to the OpenCms web
application, e.g. C:\Java\Tomcat\webapps\opencms\
opencms.request.uri returns the name of the currently requested URI in
the OpenCms VFS, e.g. /index.jsp
opencms.request.element.uri returns the name of the currently processed element,
which might be a sub-element like a template part,
in the OpenCms VFS, e.g. /system/modules/org.opencms.welcome/jsptemplates/welcome.jsp
opencms.request.folder returns the name of the parent folder of the currently
requested URI in the OpenCms VFS, e.g. /
opencms.request.encoding returns the content encoding that has been set
for the currently requested resource, e.g. ISO-8859-1
All other property values that are passes to the tag as routed to a standard
System.getProperty(value) call,
so you can also get information about the Java VM environment,
using values like
java.vm.version or
os.name.
If the given property value does not match a key from the special OpenCms values
and also not the system values, a (String) message is returned with a formatted
error message.
- Version:
- $Revision: 1.10.2.1 $
| Methods inherited from class javax.servlet.jsp.tagext.TagSupport |
doAfterBody, doEndTag, 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 |
m_property
private java.lang.String m_property
m_systemProperties
private static final java.lang.String[] m_systemProperties
- Static array with allowed info property values
m_userProperty
private static final java.util.List m_userProperty
- array list of allowed property values for more convenient lookup
CmsJspTagInfo
public CmsJspTagInfo()
setProperty
public void setProperty(java.lang.String name)
- Sets the info property name.
getProperty
public java.lang.String getProperty()
- Returns the selected info property.
release
public void release()
- Description copied from class:
javax.servlet.jsp.tagext.TagSupport
- Release state.
doStartTag
public int doStartTag()
throws javax.servlet.jsp.JspException
- Description copied from class:
javax.servlet.jsp.tagext.TagSupport
- Default processing of the start tag, returning SKIP_BODY.
infoTagAction
public static java.lang.String infoTagAction(java.lang.String property,
javax.servlet.http.HttpServletRequest req)
- Returns the selected info property value based on the provided
parameters.