Ja-Jakarta
Translation

javax.servlet.jsp.tagext
クラス TagAdapter

java.lang.Object
  上位を拡張 javax.servlet.jsp.tagext.TagAdapter
すべての実装されたインタフェース:
JspTag, Tag

public class TagAdapter
extends java.lang.Object
implements Tag

Wraps any SimpleTag and exposes it using a Tag interface. This is used to allow collaboration between classic Tag handlers and SimpleTag handlers.

Because SimpleTag does not extend Tag, and because Tag.setParent() only accepts a Tag instance, a classic tag handler (one that implements Tag) cannot have a SimpleTag as its parent. To remedy this, a TagAdapter is created to wrap the SimpleTag parent, and the adapter is passed to setParent() instead. A classic Tag Handler can call getAdaptee() to retrieve the encapsulated SimpleTag instance.

導入されたバージョン:
2.0

フィールドの概要
 
インタフェース javax.servlet.jsp.tagext.Tag から継承されたフィールド
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 
コンストラクタの概要
TagAdapter(SimpleTag adaptee)
          Creates a new TagAdapter that wraps the given SimpleTag and returns the parent tag when getParent() is called.
 
メソッドの概要
 int doEndTag()
          Must not be called.
 int doStartTag()
          Must not be called.
 JspTag getAdaptee()
          Gets the tag that is being adapted to the Tag interface.
 Tag getParent()
          Returns the parent of this tag, which is always getAdaptee().getParent().
 void release()
          Must not be called.
 void setPageContext(javax.servlet.jsp.PageContext pc)
          Must not be called.
 void setParent(Tag parentTag)
          Must not be called.
 
クラス java.lang.Object から継承されたメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

コンストラクタの詳細

TagAdapter

public TagAdapter(SimpleTag adaptee)
Creates a new TagAdapter that wraps the given SimpleTag and returns the parent tag when getParent() is called.

パラメータ:
adaptee - The SimpleTag being adapted as a Tag.
メソッドの詳細

setPageContext

public void setPageContext(javax.servlet.jsp.PageContext pc)
Must not be called.

定義:
インタフェース Tag 内の setPageContext
パラメータ:
pc - ignored.
例外:
java.lang.UnsupportedOperationException - Must not be called

setParent

public void setParent(Tag parentTag)
Must not be called. The parent of this tag is always getAdaptee().getParent().

定義:
インタフェース Tag 内の setParent
パラメータ:
parentTag - ignored.
例外:
java.lang.UnsupportedOperationException - Must not be called.

getParent

public Tag getParent()
Returns the parent of this tag, which is always getAdaptee().getParent(). This will either be the enclosing Tag (if getAdaptee().getParent() implements Tag), or an adapter to the enclosing Tag (if getAdaptee().getParent() does not implement Tag).

定義:
インタフェース Tag 内の getParent
戻り値:
The parent of the tag being adapted.
関連項目:
TagSupport.findAncestorWithClass(javax.servlet.jsp.tagext.Tag, java.lang.Class)

getAdaptee

public JspTag getAdaptee()
Gets the tag that is being adapted to the Tag interface. This should be an instance of SimpleTag in JSP 2.0, but room is left for other kinds of tags in future spec versions.

戻り値:
the tag that is being adapted

doStartTag

public int doStartTag()
               throws javax.servlet.jsp.JspException
Must not be called.

定義:
インタフェース Tag 内の doStartTag
戻り値:
always throws UnsupportedOperationException
例外:
java.lang.UnsupportedOperationException - Must not be called
javax.servlet.jsp.JspException - never thrown
関連項目:
BodyTag

doEndTag

public int doEndTag()
             throws javax.servlet.jsp.JspException
Must not be called.

定義:
インタフェース Tag 内の doEndTag
戻り値:
always throws UnsupportedOperationException
例外:
java.lang.UnsupportedOperationException - Must not be called
javax.servlet.jsp.JspException - never thrown

release

public void release()
Must not be called.

定義:
インタフェース Tag 内の release
例外:
java.lang.UnsupportedOperationException - Must not be called

Ja-Jakarta
Translation

Copyright © 2000- The Apache Software Foundation. All rights Reserved.