java.lang.Object
jakarta.servlet.jsp.tagext.TagSupport
jakarta.servlet.jsp.tagext.BodyTagSupport
net.ontopia.topicmaps.nav.taglibs.template.AbstractTemplateTag
net.ontopia.topicmaps.nav.taglibs.template.PutTag
All Implemented Interfaces:
jakarta.servlet.jsp.tagext.BodyTag, jakarta.servlet.jsp.tagext.IterationTag, jakarta.servlet.jsp.tagext.JspTag, jakarta.servlet.jsp.tagext.Tag, Serializable

public class PutTag extends AbstractTemplateTag
INTERNAL: Labels a string on a JSP content (model) page which can be used by GetTag for use on a template (view) page.

Examples

  • Including the body:

    <template:put name='title'>My Title</template:put>
  • Including the value of the "content" attribute:

    <template:put name='title' direct="true" content='My Title'/>
  • Including a file:

    <template:put name='title' content='/fragments/mytitle.txt'/>
  • See Also:
    • Field Summary

      Fields inherited from class net.ontopia.topicmaps.nav.taglibs.template.AbstractTemplateTag

      name

      Fields inherited from class jakarta.servlet.jsp.tagext.BodyTagSupport

      bodyContent

      Fields inherited from class jakarta.servlet.jsp.tagext.TagSupport

      id, pageContext

      Fields inherited from interface jakarta.servlet.jsp.tagext.BodyTag

      EVAL_BODY_BUFFERED

      Fields inherited from interface jakarta.servlet.jsp.tagext.IterationTag

      EVAL_BODY_AGAIN

      Fields inherited from interface jakarta.servlet.jsp.tagext.Tag

      EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
    • Constructor Summary

      Constructors
      Constructor
      Description
       
    • Method Summary

      Modifier and Type
      Method
      Description
      int
       
      int
       
      int
       
      void
      Deprecated.
      attribute no longer neccessary to use becaue the existence of a content attribute tells the tag whether to use the body content or not.
      void
      Sets the content of the string which can either be a path to a file or the string itself, depending on the value of the "direct" attribute.
      void
      Sets a flag which, if set to "true", will interpret the content string directly.
      void
      Sets the name of the string.

      Methods inherited from class net.ontopia.topicmaps.nav.taglibs.template.AbstractTemplateTag

      getParameter, putParameter

      Methods inherited from class jakarta.servlet.jsp.tagext.BodyTagSupport

      doInitBody, getBodyContent, getPreviousOut, release, setBodyContent

      Methods inherited from class jakarta.servlet.jsp.tagext.TagSupport

      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

      Methods inherited from interface jakarta.servlet.jsp.tagext.Tag

      getParent, setPageContext, setParent
    • Constructor Details

      • PutTag

        public PutTag()
    • Method Details

      • doStartTag

        public int doStartTag() throws jakarta.servlet.jsp.JspException
        Specified by:
        doStartTag in interface jakarta.servlet.jsp.tagext.Tag
        Overrides:
        doStartTag in class jakarta.servlet.jsp.tagext.BodyTagSupport
        Throws:
        jakarta.servlet.jsp.JspException
      • doAfterBody

        public int doAfterBody() throws jakarta.servlet.jsp.JspException
        Specified by:
        doAfterBody in interface jakarta.servlet.jsp.tagext.IterationTag
        Overrides:
        doAfterBody in class jakarta.servlet.jsp.tagext.BodyTagSupport
        Throws:
        jakarta.servlet.jsp.JspException
      • doEndTag

        public int doEndTag()
        Specified by:
        doEndTag in interface jakarta.servlet.jsp.tagext.Tag
        Overrides:
        doEndTag in class jakarta.servlet.jsp.tagext.BodyTagSupport
      • setName

        public void setName(String s)
        Sets the name of the string.
      • setContent

        public void setContent(String s)
        Sets the content of the string which can either be a path to a file or the string itself, depending on the value of the "direct" attribute.
      • setDirect

        public void setDirect(String s)
        Sets a flag which, if set to "true", will interpret the content string directly. If not, the tag expects a file path to be in content. Default value is false.
      • setBody

        public void setBody(String s)
        Deprecated.
        attribute no longer neccessary to use becaue the existence of a content attribute tells the tag whether to use the body content or not.
        Sets a flag which, if set to "true", will make the tag ignore the "content" attribute and use the body content of the tag. Default value is false.