Strutsフレームワーク
ようこそ
トップページ
キックスタートFAQ
ユーザガイド
リソース
私たちは誰でしょう
ダウンロード
バイナリ
ソースコード
はじめよう
インストール
リリースノート
APIドキュメント
メーリングリスト
バグ データベース
開発者ガイド
Beanタグ
HTMLタグ
Logicタグ
Templateタグ
Digester
Utilities
タグライブラリ ドキュメント
Beanタグ
HTMLタグ
Logicタグ
Templateタグ
現在の開発
インストール(ナイトリビルド)
リリースノート(ナイトリビルド)
APIドキュメント(ナイトリビルド)
ワークフローの提案
TODOリスト
Struts Bean タグ

This tag library contains tags useful in accessing beans and their properties, as well as defining new beans (based on these accesses) that are accessible to the remainder of the page via scripting variables and page scope attributes. Convenient mechanisms to create new beans based on the value of request cookies, headers, and parameters are also provided.


このタグライブラリは、 bean と そのプロパティにアクセスするのと同様に、 変数およびページスコープ属性を記述することによりページの残りにアクセス可能な新しい (これらのアクセスに基づいた)bean を定義する際に有用なタグを含んでいます。 リクエストクッキー、ヘッダーおよびパラメータの値に基づいた新しい bean を作成する便利なメカニズムもまた提供されます。

Many of the tags in this tag library will throw a JspException at runtime when they are utilized incorrectly (such as when you specify an invalid combination of tag attributes). JSP allows you to declare an "error page" in the <%@ page %> directive. If you wish to process the actual exception that caused the problem, it is passed to the error page as a request attribute under key org.apache.struts.action.EXCEPTION.


このタグライブラリの多くのタグは、それらが不正確に利用された場合、 実行時に JspException をスローします (タグの属性を誤った組み合わせで指定した場合など)。 JSPは、<%@ page %>指示の中で "error page"を宣言することができます。 その問題を引き起こした実際の例外を処理したい場合は、 キー org.apache.struts.action.EXCEPTION の下のリクエスト属性としてエラーページに渡されます。

If you are viewing this page from within the Struts Documentation Application (or online at http://jakarta.apache.org/struts), you can learn more about using these tags in the Bean Tags Developer's Guide.


このページを Struts Documentation Application (またはオンラインの http://jakarta.apache.org/struts) から見ているのであれば、 Bean タグ デベロッパーズ ガイド の中でこれらのタグの使い方についてさらに知ることができます。

Tag NameDescription
cookie指定したリクエストクッキーの値に基づいて変数を定義します。
define指定した bean プロパティの値に基づいて変数を定義します。
header指定したリクエストヘッダの値に基づいて変数を定義します。
include 動的なアプリケーションリクエストから応答をロードして bean として利用可能にします。
message応答となる国際化されたメッセージ文字列を表現します。
page 指定したアイテムをbeanとしてページコンテキストから取り出します。
parameter 指定したリクエストパラメータの値に基づいて変数を定義します。
resource Web アプリケーションのリソースをロードして bean として利用可能にします。
size Collection または Map の要素数を含む bean を定義します。
struts 指定したStruts内部コンフィグレーション オブジェクトを bean として取り出します。
write 指定した bean プロパティの値を現在の JspWriter として表現します。
cookie - 指定したリクエストクッキーの値に基づいて変数を定義します。

Retrieve the value of the specified request cookie (as a single value or multiple values, depending on the multiple attribute), and define the result as a page scope attribute of type Cookie (if multiple is not specified) or Cookie[] (if multiple is specified).


指定したリクエストクッキー (一つまたは複数の値、multiple属性に依存) の値を取り出し、結果をCookie型 (multipleが指定されていない場合) または、Cookie[]型 (multipleを指定した場合) のページスコープ属性として定義します。

If no cookie with the specified name can be located, and no default value is specified, a request time exception will be thrown.


指定した名前のクッキーが無く、デフォルト値が指定されていない場合、 リクエスト時に例外がスローされます。

Attribute NameDescription
id

Specifies the name of the scripting variable (and associated page scope attribute) that will be made available with the value of the specified request cookie.


指定したリクエストクッキーの値として利用可能となる変数 (かつ、関連するページスコープ属性) の名前を指定します。

[Required] [RT Expr]
multiple

If any arbitrary value for this attribute is specified, causes all matching cookies to be accumulated and stored into a bean of type Cookie[]. If not specified, the first value for the specified cookie will be retrieved as a value of type Cookie.


この属性に合う任意の値を指定した場合、一致するすべてのクッキーは Cookie[]型のbeanへ蓄積、格納されます。 指定されない場合は、指定したクッキーに合う最初の値が Cookie型の値として取り出されます。

[RT Expr]
name

Specifies the name of the request cookie whose value, or values, is to be retrieved.


(一つまたは複数の)値が取り出されるリクエストクッキーの名前を指定します。

[Required] [RT Expr]
value

The default cookie value to return if no cookie with the specified name was included in this request.


指定した名前を持つクッキーがこのリクエストに含まれていなかった場合に戻すデフォルトのクッキー値。

[RT Expr]
define - 指定した bean プロパティの値に基づいて変数を定義します。

Retrieve the value of a specified bean property, and define it as an attribute (in the scope specified by the toScope property) accessible to the remainder of the current page. No type conversion is performed on the returned property value, unless it is a Java primitive type, in which case it is wrapped in the appropriate wrapper class (i.e. int is wrapped by java.lang.Integer).


指定した bean プロパティの値を取り出し、現在のページの残りにアクセス可能な、 (toScopeプロパティで指定したスコープ内での)属性として定義します。 戻されるプロパティ値はJavaのプリミティブ型でなければ型変換されず、 適切なラッパクラスでラップされます。 (例えば、int は Java.lang.Integer でラップされます)

If you specify a "value" attribute, the exposed bean will be of type java.lang.String and initialized to the specified value.


"value" 属性を指定した場合、取り出される bean は、 java.lang.String 型で、指定した値で初期化されます。

If a problem occurs while retrieving the specified bean property, a request time exception will be thrown.


もし指定した bean プロパティの取り出し中に問題が発生した場合は、 リクエスト時に例外がスローされます。

The <bean:define> tag differs from <jsp:useBean> in several ways, including:


<bean:define> タグ は、 <jsp:useBean> との違いがいくつかあります:

  • Unconditionally creates (or replaces) a bean under the specified identifier.

  • 指定した識別子で bean を無条件に 作成(または置換)します。
  • Can create a bean with the value returned by a property getter of a different bean (including properties referenced with a nested and/or indexed property name).

  • 別の bean のプロパティ ゲッター が戻す値によって bean を作成できます。 (ネストされて(かつ、または) インデックス付きのプロパティ名で参照されるプロパティを含む)
  • Can create a bean whose contents is a literal string (or the result of a runtime expression) specified by the value attribute.

  • value属性で指定した リテラル 文字列 (または実行時式の結果) を含む bean を作成できます。
  • Does not support nested content (such as <jsp:setProperty> tags) that are only executed if a bean was actually created.

  • <jsp:setProperty> タグのように ネストされた内容はサポートされません。 bean が実際に作成された場合にのみ実行されます。

USAGE NOTE - There is a restriction in the JSP 1.1 Specification that disallows using the same value for an id attribute more than once in a single JSP page. Therefore, you will not be able to use <bean:define> for the same bean name more than once in a single page.


使い方の注意 - JSP 1.1 仕様の中に制限事項があります。 単一のJSPページの中で、id属性に同じ値を使用することは許可されていません。 そのため、<bean:define> を 単一ページ内で2回以上同じ bean 名で使用することはできません。

See the Bean Developer's Guide section on bean creation for more information about these differences, as well as alternative approaches to introducing beans into a JSP page.


これらの違いやJSPページにbeanを導入する代替アプローチについての詳しい情報は、 Bean デベロッパーズ ガイド の bean 作成 セクションを参照してください。

Attribute NameDescription
id

Specifies the name of the scripting variable (and associated page scope attribute) that will be made available with the value of the specified property.


指定したプロパティの値と共に利用可能となる変数(と、関連付けされたページスコープ属性)の名前を指定します。

[Required] [RT Expr]
name

Specifies the attribute name of the bean whose property is accessed to define a new page scope attribute (if property is also specified) or the attribute name of the bean that is duplicated with the new reference created by this tag (if property is not also specified). This attribute is required unless you specify a value attribute.


新しいページスコープ属性を定義するためにプロパティがアクセスされる bean の属性名 (propertyを指定した場合)、 またはこのタグによって新しい参照がコピーされる bean の属性名 (propertyが指定されない場合) を指定します。 この属性は value 属性を指定しない場合は必須となります。

[RT Expr]
property

Specifies the name of the property to be accessed on the bean specified by name. This value may be a simple, indexed, or nested property reference expression. If not specified, the bean identified by name is given a new reference identified by id.


name によって指定した bean 上でアクセスされるプロパティの名前を指定します。 この値はシンプル、インデックス付き、またはネストされたプロパティ参照式になります。 指定されない場合は、name によって識別された bean は id によって識別された新しい参照を与えられます。

[RT Expr]
scope

Specifies the variable scope searched to retrieve the bean specified by name. If not specified, the default rules applied by PageContext.findAttribute() are applied.


name によって指定した bean を取り出すために検索さるスコープを指定します。 指定されない場合、PageContext.findAttribute() によって適用されたデフォルトのルールが適用されます。

[RT Expr]
toScope

Specifies the variable scope into which the newly defined bean will be created. If not specified, the bean will be created in page scope.


新しく定義された bean が作成されるスコープを指定します。 指定されない場合は、bean は page スコープ内で作成されます。

[RT Expr]
type

Specifies the fully qualified class name of the value to be exposed as the id attribute. If not specified, the default type is java.lang.String (if you specify a value attribute), or java.lang.Object otherwise.


id属性として表される値の完全修飾されたクラス名を指定します。 指定されない場合、デフォルトの型は、 java.lang.String です (value 属性を指定した場合)。 それ以外の場合は、java.lang.Object となります。

[RT Expr]
value

The java.lang.String value to which the exposed bean should be set. This attribute is required unless you specify the name attribute.


取り出されたbean がセットされるべき java.lang.String の値。 name 属性を指定しない場合、この属性は必須です。

[RT Expr]
header - 指定したリクエストヘッダの値に基づいて変数を定義します。

Retrieve the value of the specified request header (as a single value or multiple values, depending on the multiple attribute), and define the result as a page scope attribute of type String (if multiple is not specified) or String[] (if multiple is specified).


指定したリクエストヘッダ(1つまたは複数の値、multiple属性に依存) を取り出し 結果をString型(multipleが指定されていない場合)、 または String[]型(multipleを指定した場合) のページスコープ属性として、定義します。

If no header with the specified name can be located, and no default value is specified, a request time exception will be thrown.


指定した名前でヘッダを識別できず、かつデフォルト値が指定されない場合は、 リクエスト時に例外がスローされます。

Attribute NameDescription
id

Specifies the name of the scripting variable (and associated page scope attribute) that will be made available with the value of the specified request header.


指定したリクエストヘッダの値と共に有効となる変数(と、 関連するページスコープ属性)の名前を指定します。

[Required] [RT Expr]
multiple

If any arbitrary value for this attribute is specified, causes a call to HttpServletRequest.getHeaders() and a definition of the result as a bean of type String[]. Otherwise, HttpServletRequest.getHeader() will be called, and a definition of the result as a bean of type String will be performed.


この属性に合う任意の値が指定された場合、 HttpServletRequest.getHeaders() を呼び出し String[]型の bean として結果を定義します。 そうでなければ、HttpServletRequest.getHeader() が呼ばれ、String型の bean として結果の定義が行われます。

[RT Expr]
name

Specifies the name of the request header whose value, or values, is to be retrieved.


(一つまたは複数の)値が取り出されるリクエストヘッダの名前を指定します。

[Required] [RT Expr]
value

The default header value to return if no header with the specified name was included in this request.


指定した名前を持つヘッダがこのリクエストに含まれていなかった場合に戻すデフォルトのヘッダ値。

[RT Expr]
include - 動的なアプリケーションリクエストから応答をロードして bean として利用可能にします。

Perform an internal dispatch to the specified application component (or external URL) and make the response data from that request available as a bean of type String. This tag has a function similar to that of the standard <jsp:include> tag, except that the response data is stored in a page scope attribute instead of being written to the output stream. If the current request is part of a session, the generated request for the include will also include the session identifier (and thus be part of the same session).


指定したアプリケーション コンポーネント (または外部のURL) への内部ディスパッチを行います。 そして、リクエストから String 型の bean として利用可能なレスポンスデータを作成します。 このタグは、標準の <jsp:include> タグに似た機能を持ちますが、 レスポンスデータがアウトプットストリームではなく、ページスコープ属性に格納されます。 現在のリクエストがセッションの一部であれば、include のために生成されたリクエストは セッション識別子も含みます(そして同じセッションの一部となります)。

The URL used to access the specified application component is calculated based on which of the following attributes you specify (you must specify exactly one of them):


指定したアプリケーションコンポーネントのアクセスに使われるURLは、 次の属性を基に求められます。 (どれか一つを必ず指定してください):

  • forward - Use the value of this attribute as the name of a global ActionForward to be looked up, and use the context-relative URI found there.

  • forward - グローバル ActionForwardからこの値を検索し、 見つかった結果をコンテキスト相対URIとして使用します。
  • href - Use the value of this attribute unchanged (since this might link to a resource external to the application, the session identifier is not included.

  • href - この属性の値を変更せずに使用します。 (外部アプリケーションのリソースにリンクするかもしれません)。 セッション識別子は含まれません
  • page - Use the value of this attribute as a context-relative URI to the desired resource.

  • page - この属性の値を対象リソースへの コンテキスト相対URI として使用します。
Attribute NameDescription
anchor

Optional anchor tag ("#xxx") to be added to the generated hyperlink. Specify this value without any "#" character.


生成されたハイパーリンクに付加されるオプションのアンカータグ ("#xxx")。 この値は、"#"文字を使用せずに指定してください。

[RT Expr]
forward

Logical name of a global ActionForward that contains the actual content-relative URI of the resource to be included.


インクルードされるべき実際のコンテキスト相対URIを含んでいる、 グローバル ActionForward の論理名。

[RT Expr]
href

Absolute URL (including the appropriate protocol prefix such as "http:") of the resource to be included. Because this URL could be external to the current web application, the session identifier will not be included in the request.


インクルードされるべきリソースの絶対URL("http:" のような適切なプロトコル プレフィックスを含む)。 なぜなら、このURLは現在の Web アプリケーションの外部となるので、 セッション識別子はリクエストに含まれないでしょう。

[RT Expr]
id

Specifies the name of the scripting variable (and associated page scope attribute) that will be made available with the value of the specified web application resource.


指定した Web アプリケーション リソースの値共に有効となる変数 (と関連するページスコープ属性)の名前を指定します。

[Required] [RT Expr]
name

Context-relative name (starting with a '/') of the web application request to be dispatched, and whose response data is to be made available as a bean. DEPRECATED - Use the "page" attribute instead.


ディスパッチされる Web アプリケーションのリクエストのコンテキスト相対名("/"で始まる)。 そしてそのレスポンスデータは bean として利用可能となります。 非推奨 - 代わりに "page" 属性を使用してください。

[RT Expr]
page

Context-relative URI (starting with a '/') of the web application resource to be included.


インクルードされるべき Web アプリケーション リソース のコンテキスト相対URI ("/"で始まる)。

[RT Expr]
transaction

Set to true if you want the current transaction control token included in the generated URL for this include.


現在のトランザクション コントロール トークンを、 このインクルードのために生成した URL を含ませたい場合は、 trueをセットする。

[RT Expr]
message - 応答となる国際化されたメッセージ文字列を表現します。

Retrieves an internationalized message for the specified locale, using the specified message key, and write it to the output stream. Up to five parametric replacements (such as "{0}") may be specified.


指定したメッセージキーを使用して、 指定のロケールの国際化されたメッセージを取り出し、 アウトプットストリームに書き出します。 5つ迄のパラメータ置換("{0}" のような)が指定されます。

Attribute NameDescription
arg0

First parametric replacement value, if any.


最初のパラメータの置換値 (もしあれば)

[RT Expr]
arg1

Second parametric replacement value, if any.


2番目のパラメータの置換値 (もしあれば)

[RT Expr]
arg2

Third parametric replacement value, if any.


3番目のパラメータの置換値 (もしあれば)

[RT Expr]
arg3

Fourth parametric replacement value, if any.


4番目のパラメータの置換値 (もしあれば)

[RT Expr]
arg4

Fifth parametric replacement value, if any.


5番目のパラメータの置換値 (もしあれば)

[RT Expr]
bundle

The name of the application scope bean under which the MessageResources object containing our messages is stored. If not specified, the default name (the value of the Action.MESSAGES_KEY constant string) is used.


メッセージを含んでいるMessageResources オブジェクトが格納される アプリケーション スコープ bean の名前。 指定されない場合は、デフォルトの名前 (Action.MESSAGES_KEYの定数文字列の値)が使用されます。

[RT Expr]
key

The message key of the requested message, which must have a corresponding value in the message resources.


要求されたメッセージ (メッセージ リソースの中に対応する値を持っている) のメッセージキー。

[Required] [RT Expr]
locale

The name of the session scope bean under which our currently selected Locale object is stored. If not specified, the default name (the value of the Action.LOCALE_KEY constant string) is used.


現在選択されている Locale オブジェクトが格納される セッション スコープ bean の名前。 指定されない場合は、デフォルトの名前(Action.LOCALE_KEY の定数文字列の値)が使用されます。

[RT Expr]
page - 指定したアイテムをbeanとしてページコンテキストから取り出します。

Retrieve the value of the specified item from the page context for this page, and define it as a scripting variable, and a page scope attribute accessible to the remainder of the current page.


指定したアイテムを このページのページコンテキストから取り出し、 現在のページの残りにアクセス可能なページスコープ属性の変数として定義します。

If a problem occurs while retrieving the specified configuration object, a request time exception will be thrown.


指定した コンフィグレーションオブジェクトの取り出し中に問題が発生した場合は、 リクエスト時に例外がスローされます。

Attribute NameDescription
id

Specifies the name of the scripting variable (and associated page scope attribute) that will be made available with the value of the specified page context property.


指定したコンテキスト プロパティの値として利用可能となる変数(かつ、 関連するページスコープ属性)の名前を指定します。

[Required] [RT Expr]
property

Name of the property from our page context to be retrieved and exposed. Must be one of application, config, request, response, or session.


ページ コンテキストから取り出され表されるべきプロパティの名前。 applicationconfigrequestresponse、 または session のうちの1つ。

[Required] [RT Expr]
parameter - 指定したリクエストパラメータの値に基づいて変数を定義します。

Retrieve the value of the specified request parameter (as a single value or multiple values, depending on the multiple attribute), and define the result as a page scope attribute of type String (if multiple is not specified) or String[] (if multiple is specified).


指定したリクエストパラメータ (1つまたは複数の値、multiple属性に依存) を取り出し、 結果をString型(multipleが指定されていない場合)、 または String[]型(multipleを指定した場合) のページスコープ属性として、定義します。

If no request parameter with the specified name can be located, and no default value is specified, a request time exception will be thrown.


指定した リクエストパラメータの取り出し中に問題が発生した場合は、 リクエスト時に例外がスローされます。

Attribute NameDescription
id

Specifies the name of the scripting variable (and associated page scope attribute) that will be made available with the value of the specified request parameter.


指定したリクエストパラメータの値として利用可能となる変数 (かつ、関連するページスコープ属性)の名前を指定します。

[Required] [RT Expr]
multiple

If any arbitrary value for this attribute is specified, causes a call to ServletRequest.getParameterValues() and a definition of the result as a bean of type String[]. Otherwise, ServletRequest.getParameter() will be called, and a definition of the result as a bean of type String will be performed.


この属性に合う任意の値が指定される場合、 HttpServletRequest.getParameterValues() を呼び出し String[]型の bean として結果を定義します。 そうでなければ、HttpServletRequest.getParameterValue() が呼ばれ、String型の bean として結果の定義が行われます。

[RT Expr]
name

Specifies the name of the request parameter whose value, or values, is to be retrieved.


(一つまたは複数の)値が取り出されるリクエストパラメータの名前を指定します。

[Required] [RT Expr]
value

The default parameter value to return if no parameter with the specified name was included in this request.


指定した名前を持つパラメータがこのリクエストに含まれていなかった場合に戻す デフォルトのパラメータ値。

[RT Expr]
resource - Web アプリケーションのリソースをロードして bean として利用可能にします。

Retrieve the value of the specified web application resource, and make it available as either a InputStream or a String, depending on the value of the input attribute.


指定した Web アプリケーション リソースの値を取り出し、 InputStream または String のどちらか一方として利用可能な input 属性に依存する値を作成します。

If a problem occurs while retrieving the specified resource, a request time exception will be thrown.


指定した リソースの取り出し中に問題が発生した場合は、 リクエスト時に例外がスローされます。

Attribute NameDescription
id

Specifies the name of the scripting variable (and associated page scope attribute) that will be made available with the value of the specified web application resource.


指定した Web アプリケーション リソースの値として利用可能となる変数 (かつ、関連するページスコープ属性)の名前を指定します。

[Required] [RT Expr]
input

If any arbitrary value for this attribute is specified, the resource will be made available as an InputStream. If this attribute is not specified, the resource will be made available as a String.


この属性に合う任意の値が指定された場合、リソースは InputStream として利用可能になります。 この属性が指定されない場合、リソースは String として利用可能になります。

[RT Expr]
name

Context-relative name (starting with a '/') of the web application resource to be loaded and made available.


ロードされ利用可能となるべき Web アプリケーション リソース の Context-relative な("/"で始まる)名前 。

[Required] [RT Expr]
size - Collection または Map の要素数を含む bean を定義します。

Given a reference to an array, Collection or Map, creates a new bean, of type java.lang.Integer, whose value is the number of elements in that collection. You can specify the collection to be counted in any one of the following ways:


配列、コレクション、または Map への参照を与え、java.lang.Integer 型の 新しい bean を作成します。 その値は、コレクションの要素数です。 カウントされるコレクションを指定するには、次の方法の一つで行います:

  • As a runtime expression specified as the value of the collection attribute.

  • 実行時式とする場合は、collection 属性の値として指定します。
  • As a JSP bean specified by the name attribute.

  • JSP bean とする場合は、name 属性によって指定します。
  • As the property, specified by the property attribute, of the JSP bean specified by the bean attribute.

  • プロパティとする場合は、bean 属性で指定した JSP bean の property 属性によって指定します。
Attribute NameDescription
collection

A runtime expression that evaluates to an array, a Collection, or a Map.


配列、Collection、または Map として評価される実行時式。

[RT Expr]
id

The name of a page scope JSP bean, of type java.lang.Integer, that will be created to contain the size of the underlying collection being counted.


カウントされるコレクションのサイズを含むために作成されるページスコープ JSP bean (java.lang.Integer 型) の名前。

[Required] [RT Expr]
name

The name of the JSP bean (optionally constrained to the scope specified by the scope attribute) that contains the collection to be counted (if property is not specified), or whose property getter is called to return the collection to be counted (if property is specified.


(propertyが指定されない場合に) カウントされるコレクションを含んでいるか、 (propertyを指定した場合に)カウントされるコレクションを 戻すためにプロパティゲッターが呼ばれる、(オプションで scope 属性でスコープが制限された) JSP bean の名前 。

[RT Expr]
property

The name of the property, of the bean specified by the name attribute, whose getter method will return the collection to be counted.


name 属性によって指定した bean の ゲッター メソッドがカウントされるコレクションを戻す bean の プロパティ名。

[RT Expr]
scope

The bean scope within which to search for the JSP bean specified by the name attribute. If not specified, the available scopes are searched in ascending sequence.


name 属性によって指定した JSP bean を探索する bean スコープ範囲。 指定されない場合は、利用可能なスコープは昇順に検索されます。

[RT Expr]
struts - 指定したStruts内部コンフィグレーション オブジェクトを bean として取り出します。

Retrieve the value of the specified Struts internal configuration object, and define it as a scripting variable and as a page scope attribute accessible to the remainder of the current page. You must specify exactly one of the formBean, forward, and mapping attributes to select the configuration object to be exposed.


指定した Struts 内部コンフィグレーションオブジェクトを取り出し、 現在のページの残りにアクセスするためのページスコープ属性の変数として定義します。 取り出すコンフィグレーションオブジェクトを選択するために、 formBeanforward、および mapping 属性のうち一つを必ず指定してください。

If a problem occurs while retrieving the specified configuration object, a request time exception will be thrown.


指定した コンフィグレーションオブジェクトの取り出し中に問題が発生した場合は、 リクエスト時に例外がスローされます。

Attribute NameDescription
id

Specifies the name of the scripting variable (and associated page scope attribute) that will be made available with the value of the specified Struts internal configuration object.


指定した Struts 内部コンフィグレーション オブジェクトの値と共に有効となる変数(と、関連するページスコープ属性)の名前を指定します。

[Required] [RT Expr]
formBean

Specifies the name of the Struts ActionFormBean definition object to be exposed.


取り出すべき Struts ActionFormBean 定義 オブジェクト の名前を指定します。

[RT Expr]
forward

Specifies the name of the global Struts ActionForward definition object to be exposed.


取り出すべき グローバル Struts ActionForward 定義 オブジェクト の名前を指定します。

[RT Expr]
mapping

Specifies the matching path of the Struts ActionMapping definition object to be exposed.


取り出すべき Struts ActionMapping 定義 オブジェクト に一致するパスを指定します。

[RT Expr]
write - 指定した bean プロパティの値を現在の JspWriter として表現します。

Retrieve the value of the specified bean property, and render it to the current JspWriter as a String. If there is a PropertyEditor configured for the property value's class, the getAsText() method will be called. Otherwise, the usual toString() conversions will be applied.


指定した bean プロパティの値を取り出し、Stringとして現在の JspWriterに与えます。 プロパティ値のクラス用に構成されている PropertyEditor がある場合、 getAsText() メソッドが呼ばれます。 それ以外の場合は、通常 toString()での変換が適用されます。

If a problem occurs while retrieving the specified bean property, a request time exception will be thrown.


指定したbean プロパティの取り出し中に問題が発生した場合は、 リクエスト時に例外がスローされます。

Attribute NameDescription
filter

If this attribute is set to true, the rendered property value will be filtered for characters that are sensitive in HTML, and any such characters will be replaced by their entity equivalents. By default, filtering is performed - to disable it, you must explicitly set this attribute to false.


この属性がtrueにセットされる場合、 表現されたプロパティ値は HTML内でセンシティブな文字のためにフィルターされます。 そしてこのような全ての文字は、等価な文字で置き換えられます。 デフォルトでは、フィルタリングが行われます。 無効にするためには、この属性に明示的に false をセットする必要があります。

[RT Expr]
ignore

If this attribute is set to true, and the bean specified by the name and scope attributes does not exist, simply return without writing anything. The default value is false, which will cause a runtime exception to be thrown, consistent with the other tags in this tag library.


この属性がtrueにセットされ、namescope属性で指定した bean が存在しない場合、 なにもせずにリターンします。 デフォルト値は false (このタグ ライブラリの中のほかのタグと矛盾しないように実行時例外がスローされます)。

[RT Expr]
name

Specifies the attribute name of the bean whose property is accessed to retrieve the value specified by property (if specified). If property is not specified, the value of this bean itself will be rendered.


property (指定がある場合) によって指定した値を取り出すために、プロパティがアクセスされる bean の属性名を指定します。 property が指定されない場合、この bean 自身の値が表現されます。

[Required] [RT Expr]
property

Specifies the name of the property to be accessed on the bean specified by name. This value may be a simple, indexed, or nested property reference expression. If not specified, the bean identified by name will itself be rendered. If the specified property returns null, no output will be rendered.


name によって指定した bean 上でアクセスされる プロパティの名前を指定します。 この値はシンプル、インデックス付き、 またはネストされたプロパティ参照式になります。 指定されない場合は、name によって識別された bean は それ自身を表現します。 指定したプロパティがヌルを戻す場合、何も表現されません。

[RT Expr]
scope

Specifies the variable scope searched to retrieve the bean specified by name. If not specified, the default rules applied by PageContext.findAttribute() are applied.


name によって指定した bean を取り出すために検索されるスコープを指定します。 指定されない場合、PageContext.findAttribute() によって適用されたデフォルトのルールが適用されます。

[RT Expr]

[訳注: これは土橋 昇司が翻訳しました。日本語訳に対するコメントがあれば、こちらに送って下さい。]
Copyright (c) 2000-2002, Apache Software Foundation