article:define
Creates a scripting variable and a page-scoped bean from the
specified article. The tag is similar to
article:use
, but unlike
article:use
does not set the current
article.
Syntax
<article:define article="..."? articleId="..."? id="..." name="..."? property="..."? source="..."? sourceId="..."? toScope="..."?/>
Attributes
id
, mandatory, no runtime expressionsName of the scripting-variable we make.
toScope
Identify the JSP scope within which the PresentationArticle-bean will be created. If not specified, then the PresentaionArticle-bean is created in page scope.
Allowed values are:
article
A scriptlet that returns the required article.
Using this attribute excludes the use of the attributes
articleId
,name/property
andsource/sourceId
.articleId
An article id identifying the article to be defined. The value supplied can be an
int
,Integer
orString
.Using
articleId
excludes the use of the attributesarticle
,name/property
andsource/sourceId
.name
The name (key) of a bean from which a new bean/scripting variable is to be created.
There are two ways of using this bean:
Using this attribute excludes the use of the attributes
article
,articleId
andsource/sourceId
.property
The name of a bean property. This attribute is used together with the
name
attribute to locate an article from which a new bean/scripting variable is to be created. Ifname
is specified but this attribute is not specified, then the bean identified by thename
attribute will be used.This attribute cannot be used without the
name
attribute.source
The source of the article to define. This attribute must be used together with
sourceId
.Using this attribute excludes the use of the attributes
article
,articleId
andname/property
.sourceId
The source ID of the article to define. This attribute must be used together with
source
.Using this attribute excludes the use of the attributes
article
,articleId
andname/property
.