netui-data:pad Tag

<netui-data:pad> Tag

This tag determines the number of items that are rendered by a <netui-data:repeater> tag.

Syntax

<netui-data:pad
    [maxRepeat="integer_or_expression_maxRepeat"]
    [minRepeat="integer_or_expression_minRepeat"]
    [padText="string_padText"] />

Description

This tag determines the number of items that are rendered by a <netui-data:repeater> tag. The <netui-data:pad> tag has the ability to turn an irregular data set in the <netui-data:repeater> tag into a regular data set through the use of the three attributes:

If the padText attribute is unset, the body of the <netui-data:pad> tag is used as the default text.

Attributes

maxRepeatSet the maximum number of items that will be rendered by a <netui-data:repeater> tag. If the size of the data set is greater than this, only this many items will be rendered. This value can be an integer or can be an expression that resolves to an integer.
 
RequiredSupports runtime expression evaluationData bindable
NoNoYes

minRepeatSet the minimum number of items that will be rendered by a <netui-data:repeater> tag. If the size of the data set is smaller than this, the data set will be padded with the value of the padText attribute. This value can be an integer or can be an expression that resolves to an integer.
 
RequiredSupports runtime expression evaluationData bindable
NoNoYes

padTextThe text will be used when padding a <netui-data:repeater> that renders too few times
 
RequiredSupports runtime expression evaluationData bindable
NoNoYes

Sample

In the following example, assume that the <netui-data:repeater> tag iterates over a java.util.List object. The <netui-data:pad> limits the iteration to three cycles, no matter how many elements are actually in the List.
    <netui-data:repeater dataSource="{pageFlow.myList}">
         <netui-data:pad maxRepeat="3"/>
             <netui-data:repeaterItem>
                 <netui:label value="{container.item}" />
             </netui-data:repeaterItem>
     </netui-data:repeater>

Sample Code

[BEA_HOME]/weblogic81/samples/workshop/SamplesApp/WebApp/tagSamples/netui_databinding/pad/

Related Topics

<netui-data:pad> Tag Sample

<netui-data:repeater> Tag