|
The behavior logic descriptor example is shown below.
BEHAVIOR DESCRIPTORS |
id |
type |
data-source |
value |
define-id |
define-class |
define-scope |
details |
| debtorFlag |
less-than |
{customerBean.balance} |
0 |
|
|
|
|
The definition reside in this descriptor, but it would be referenced in other descriptors like element and segment. this logic could then be applied for the presentation attributes, like visible (render) or enable.
A list of
these operations is provided below, and their equivalents on the Struts
platform.
dWebSpec Logical Behavior
Type |
Struts Tag |
equal |
logic:equal |
not-equal |
logic:notEqual |
greater-equal |
logic:greaterEqual |
greater-than |
logic:greaterThan |
less-equal |
logic:lessEqual |
less-than |
logic:lessThan |
empty |
logic:empty |
not-empty |
logic:notEmpty |
present |
logic:present |
not-present |
logic:notPresent |
expression |
c:if test="${
logical-expression }" |
The applications of these behaviors are to the segment and
elements; discussions on their implementations are discussed in the related
descriptors.
For some applications, example being the enable state of elements, the entries in the descriptor is used to compose the logic expression.
These translations would be as shown below. This would then be applied as expression for the attribute.
| Attribute | data-source | logic-type | value |
| Examples | (object.property | gt | 40) |
More details are available in the attributes descriptions
type
id
data-source
value
define-id
define-class
define-scope
|