org.apache.jackrabbit.taglib
Class SetTag

java.lang.Object
  extended byjavax.servlet.jsp.tagext.TagSupport
      extended byorg.apache.jackrabbit.taglib.SetTag
All Implemented Interfaces:
javax.servlet.jsp.tagext.IterationTag, java.io.Serializable, javax.servlet.jsp.tagext.Tag
Direct Known Subclasses:
CdTag

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

Stores the given node or property in a scoped variable.

Author:
Edgar Poce
See Also:
Serialized Form

Field Summary
protected  java.lang.String item
          Item
protected  int scope
          Scope
protected  java.lang.String session
          Name of the scoped variable where the jcr session will be stored.
static java.lang.String TAG_NAME
          Tag Name
protected  java.lang.String var
          Scoped variable where the jcr Item will be stored
 
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
SetTag()
          Constructor
 
Method Summary
 int doEndTag()
           
 int doStartTag()
           
protected  javax.jcr.Item getItem()
          Gets the item
 void release()
           
 void setItem(java.lang.String item)
          Sets the item
 void setProperty(java.lang.String property)
          Sets the property.
 void setScope(java.lang.String scope)
          Sets the scope
 void setSession(java.lang.String session)
          Sets the session
 void setVar(java.lang.String var)
          Sets the variable name where the Item will be stored.
 
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

TAG_NAME

public static java.lang.String TAG_NAME
Tag Name


session

protected java.lang.String session
Name of the scoped variable where the jcr session will be stored. If not set then JCRTagConstants.KEY_SESSION is used.


item

protected java.lang.String item
Item


var

protected java.lang.String var
Scoped variable where the jcr Item will be stored


scope

protected int scope
Scope

Constructor Detail

SetTag

public SetTag()
Constructor

Method Detail

doEndTag

public int doEndTag()
             throws javax.servlet.jsp.JspException
Throws:
javax.servlet.jsp.JspException

setItem

public void setItem(java.lang.String item)
Sets the item

Parameters:
item -

setSession

public void setSession(java.lang.String session)
Sets the session

Parameters:
session -

release

public void release()

setVar

public void setVar(java.lang.String var)
Sets the variable name where the Item will be stored.

Parameters:
var -

doStartTag

public int doStartTag()
               throws javax.servlet.jsp.JspException
Throws:
javax.servlet.jsp.JspException

getItem

protected javax.jcr.Item getItem()
                          throws javax.servlet.jsp.JspException,
                                 javax.jcr.RepositoryException
Gets the item

Returns:
@throws JspException
Throws:
javax.jcr.RepositoryException
javax.servlet.jsp.JspException

setProperty

public void setProperty(java.lang.String property)
Sets the property. This can be set only when the item is a node.

Parameters:
property -

setScope

public void setScope(java.lang.String scope)
Sets the scope

Parameters:
scope -


Copyright © 2005 . All Rights Reserved.