Views

Simple views

Overview

View descriptors diagram

Reference

BasicViewDescriptor

BasicViewDescriptor

This is the abstract base descriptor for all views. Its main purpose, since it cannot be used directly, is to factorize common properties.

BasicViewDescriptor properties
Property Description

actionMap

Action​Map

Assigns the view action map. An action map is generally represented as a toolbar attached to the view. The toolbar follows the structure of the action map :

  • each action list is contained in its own toolbar section which is visually separated from the other sections. This allows for visually grouping related actions as they are grouped in the action lists.
  • each action contained in an action list is represented by a toolbar button using the action image as icon and translated action description as toolTip.
Depending on the UI channel, the view action map may also be replicated in a component contextual menu. In that case, the translated action name is used to label each menu item. The same grouping rules apply for the contextual menu than for the toolbar.

background

String

Sets the background color of the UI component. The color must be defined using its string hexadecimal representation (0xargb encoded).

Default value is null, meaning use UI default.

borderType

EBorder​Type

Sets the border type of the view. This is either a value of the EBorderType enum or its equivalent string representation :

  • NONE for no border
  • SIMPLE for a line border
  • TITLED for a titled border. The view is then labeled with its translated name and and icon. Whenever the view name has not been explicitly set, the model name is used is used.
  • TITLED_ACTIONS like TITLED but with the action map next to it if the UI channel supports it

Default value is EBorderType.NONE, i.e. no border.

collapsed

boolean

Configures wether the view is collapsed by default. Some UI frontends allow the user to collapse views when they are surrounded by a titled border. This is false by default. if set to true, the view will appear collapsed by default if and only if it is collapsible.

collapsible

boolean

Configures wether the UI frontend is alowed to collapse this view. Some UI frontends allow the user to collapse views when they are surrounded by a titled border. This is true by default. if set to false, the view will not collapse.

font

String

Allows to customize the font used by the UI component. The font must be string encoded using the pattern "[name];[style];[size]" :

  • [name] is the name of the font, e.g. arial.
  • [style] is PLAIN, BOLD, ITALIC or a union of BOLD and ITALIC combined with the '|' character, e.g. BOLD|ITALIC.
  • [size] is the size of the font, e.g. 10.
Any of the above pattern section can be left empty, thus falling back to the component default.

Default value is null, meaning use default component font.

foreground

String

Sets the foreground color of the UI component. The color must be defined using its string hexadecimal representation (0xargb encoded).

Default value is null, meaning use UI default.

grantedRoles

Collection​<​String​>​

Assigns the roles that are authorized to use this view. It supports "!" prefix to negate the role(s). Whenever the user is not granted sufficient privileges, the view is replaced by an empty section at runtime. Setting the collection of granted roles to null (default value) disables role based authorization on the view level. The framework then checks for the model roles authorizations and will apply the same restrictions. If both view and model granted roles collections are null, then access is granted to anyone.

modelDescriptor

IModel​Descriptor

Assigns the model descriptor backing the view. The model descriptor serves several purposes :

  • configuration of the view content. For instance whenever a form is assigned a component model descriptor, it will install 1 field per component rendering properties, unless otherwise specified in the view descriptor itself.
  • configuration of the binding layer. There is no need for the developer to configure anything for the binding to occur between the view and the model. Based on their model descriptor, Jspresso will setup all the necessary plumbing to efficiently synchronize model properties with their view counterpart bi-directionally. This synchronization occurs implicitly using the observer pattern and one of the Jspresso key contract is to guarantee this synchronization seamlessly.
Although it is the developer responsibility to make sure the correct model descriptor is assigned to the view, there are cases where the framework will infer it. For instance, a composite view will by default transmit its model descriptor to its children that do not have their model descriptor explicitly set. This allows for setting the model descriptor only on the composite view and keep default null value on the children as an implicit model inheritance enablement.

permId

String

Sets the permanent identifier to this application element. Permanent identifiers are used by different framework parts, like dynamic security or record/replay controllers to uniquely identify an application element. Permanent identifiers are generated by the SJS build based on the element id but must be explicitly set if Spring XML is used.

preferredHeight

Integer

Allows to set a preferred height (in pixels) for the created peer UI component. This will override default and give hints to the UI layouting system.

preferredSize

Dimension

Sets the preferred size.

preferredWidth

Integer

Allows to set a preferred width (in pixels) for the created peer UI component. This will override default and give hints to the UI layouting system.

readOnly

Boolean

Allows to set a view read-only, i.e. none of the view part will allow for updating the underlying model. This is mainly a shortcut to assigning an "always closed" writability gate. One difference though is that, since the framework knows that the view will never be updatable, it may take specific decisions to render properties in a slightly different way, e.g. instead of using a disabled text field, use a label.

Default value is false, i.e. view is updatable.

secondaryActionMap

Action​Map

Assigns the view secondary action map. Same rules as the primary action map apply except that actions in this map should be visually distinguished from the main action map, e.g. placed in another toolbar.

styleName

String

Assigns the style name to use for this view. The way it is actually leveraged depends on the UI channel. It will generally be mapped to some sort of CSS style name.

Default value is null, meaning that a default style is used.

writabilityGates

Collection​<​IGate​>​

Assigns a collection of gates to determine view writability. A view will be considered writable (updatable) if and only if all gates are open. This mechanism is mainly used for dynamic UI authorization based on model state, e.g. a validated invoice should not be editable anymore.

View assigned gates will be cloned for each view instance created and backed by this descriptor. So basically, each view instance will have its own, unshared collection of writability gates.

Jspresso provides a useful set of gate types, like the binary property gate that open/close based on the value of a boolean property of the view model.

By default, view descriptors are not assigned any gates collection, i.e. there is no writability restriction. Note however that view actual writability is the combination of view and model writability.


AbstractCardViewDescriptor

This descriptor serves as abstract base implementation for card view descriptor. A card view is a view stack made of children views (the cards) where only the view (card) at the top of the stack is visible. The actual child view to place on the top of the stack is dynamically determined based on the bound model. This card determination strategy depends on the concrete descriptor sub-types.

One might wonder why a card view is not considered as (and actually does not inherit from) a composite view. The difference is that composite views are used aggregate views that displays - hopefully - different parts (the children views) of the same model. A card view descriptor is rather used to make the same UI region display different views depending on different models (or different model states). Once the model is fixed, the card view behaves exactly as its top card.

One of the most important usage of card views is when it is combine as the detail in a master-detail view. The detail view may then change dynamically based on the selected master.

AbstractCardViewDescriptor properties
Property Description
This class does not have any specific property.

BasicCardViewDescriptor

Describes a multi-purpose card view that is configurable with a custom card determination strategy. Cards are registered with a name key that is used to retrieve the card to display based on the card selector selected name key.

BasicCardViewDescriptor properties
Property Description

cardNameSelector

ICard​Name​Selector

Configures the card determination strategy. This delegate is responsible for selecting the card name key based on the model bound to the view. Every time the bound model changes, the card name selector is triggered to select a new card. The names returned by the card name selector must match the names under which the cards are registered. Whenever the card name selector returns an unknown name, the card view displays an empty view. The card name selector can optionally implement ICardProvider in which case, it will be given a chance to create cards dynamically based on their names.

cardViewDescriptors

Map​<​String​,IView​Descriptor​>​

Registers the card views keyed by their name keys. The names used as key of the Map must match the names that are returned by the registered card name selector.


MobileCardViewDescriptor

A composite view descriptor that aggregates mobile views in cards.

MobileCardViewDescriptor properties
Property Description

forClientTypes

List​<​String​>​

Sets for client types.

position

EPosition

Sets position.


EntityCardViewDescriptor

This card view provides a simple card determination strategy that is based on the bound model type. This strategy pulls up the card whose model descriptor matches the type of the bound model.

EntityCardViewDescriptor properties
Property Description

viewDescriptors

List​<​IView​Descriptor​>​

Registers the list of card view descriptors. Every time the bound model changes, this list is iterated until a card with a matching model is found. The first matching card is displayed. Whenever no registered card matches, an empty view is displayed.


MobileEntityCardViewDescriptor

This card view provides a simple card determination strategy that is based on the bound model type. This strategy pulls up the card whose model descriptor matches the type of the bound model.

MobileEntityCardViewDescriptor properties
Property Description

forClientTypes

List​<​String​>​

Sets for client types.

position

EPosition

Sets position.


PropertyCardViewDescriptor

Describes a model-bound card view that is configurable with a model property used to determine the card yo display.

PropertyCardViewDescriptor properties
Property Description

accessorFactory

IAccessor​Factory

Sets accessor factory.

cardViewDescriptors

Map​<​String​,IView​Descriptor​>​

Registers the card views keyed by their name keys. The names used as key of the Map must match the names that are returned by the registered card name selector.

propertyName

String

Sets the model property name used to determine the card name.


MobilePropertyCardViewDescriptor

Describes a model-bound card view that is configurable with a model property used to determine the card yo display.

MobilePropertyCardViewDescriptor properties
Property Description

forClientTypes

List​<​String​>​

Sets for client types.

position

EPosition

Sets position.


AbstractComponentViewDescriptor

Abstract class for component view descriptors.

AbstractComponentViewDescriptor properties
Property Description

labelFont

String

This property defines the font of the property labels. It might differ from the field component one. The font must be string encoded using the pattern "[name];[style];[size]" :

  • [name] is the name of the font, e.g. arial.
  • [style] is PLAIN, BOLD, ITALIC or a union of BOLD and ITALIC combined with the '|' character, e.g. BOLD|ITALIC.
  • [size] is the size of the font, e.g. 10.
Any of the above pattern section can be left empty, thus falling back to the component default.

This property can be overridden on a field basis using an explicit property view definition.

Default value is null, meaning use default component font.

labelsPosition

ELabel​Position

Instructs Jspresso where to place the fields label. This is either a value of the ELabelPosition enum or its equivalent string representation :

  • ABOVE for placing each field label above the property UI component
  • ASIDE for placing each field label aside the property UI component
  • NONE for completely disabling fields labelling on the view
Default value is ELabelPosition.ASIDE, i.e. fields label next to the property UI component.

propertyViewDescriptors

List​<​IProperty​View​Descriptor​>​

This property allows for configuring the fields of the component view in a very customizable manner, thus overriding the model descriptor defaults. Each property view descriptor contained in the list describes a form field that will be rendered in the UI accordingly.

For instance, a writable property can be made specifically read-only on this component view by specifying its property view descriptor read-only. In that case, the model remains untouched and only the view is impacted.

Following the same scheme, you can assign a list of writability gates on a field to introduce dynamic field editability on the view without modifying the model.

A last, yet important, example of column view descriptor usage is the role-based field set configuration. Whenever you want a field to be available only for certain user roles (profiles), you can configure a field property view descriptor with a list of granted roles. If the user doesn't have the field(s)required role, the forbidden field(s) simply won't be displayed. This allows for high authorization-based versatility.

There are many other usages of defining field property view descriptors (like individual labels color and font), all of them being linked to customizing the form fields without impacting the model.

renderedProperties

List​<​String​>​

This is somehow a shortcut to using the propertyViewDescriptors property. Instead of providing a full-blown list of property view descriptors to configure the component view fields, you just pass-in a list of property names. view fields are then created from this list, keeping model defaults for all fields characteristics.

Whenever the property value is null (default), the fields list is determined from the component descriptor renderedProperties property.

valueFont

String

This property defines the font of the property values. The font must be string encoded using the pattern "[name];[style];[size]" :

  • [name] is the name of the font, e.g. arial.
  • [style] is PLAIN, BOLD, ITALIC or a union of BOLD and ITALIC combined with the '|' character, e.g. BOLD|ITALIC.
  • [size] is the size of the font, e.g. 10.
Any of the above pattern section can be left empty, thus falling back to the component default.

This property can be overridden on a field basis using an explicit property view definition.

Default value is null, meaning use default component font.


BasicComponentViewDescriptor

Component view descriptors are surely one of the most commonly used view descriptors in Jspresso. It allows to implement advanced form-like views to interact with a single component model. Component properties that are displayed in the view are organized in an invisible grid. Each field component is labelled with the property name it displays and labels can be configured to be displayed aside or above their peer field. Property fields can be configured to span multiple form columns. Component view offer various straightforward customizations, but the most advanced and powerful one is definitely the propertyViewDescriptors property tat allows to fine-tune each component UI field individually.

The description property is used to compute view tooltips and support the following rules :

  1. if the description is a property name of the underlying model, this property will be used to compute the (dynamic) tooltip (depending on the actual model).
  2. if the description is not a property name of the underlying model, the the tooltip is considered static and the translation will searched in the application resource bundles.
  3. if the description is the empty string (''), the tooltip is de-activated.
  4. if the description is not set, then the toHtml property (see toHtml property on entities / components definition) is used as dynamic property. And the toHtml falls back to the toString if not set, which falls back to the 1st string rendered property if not set.
Note that on every case above, HTML is supported. This way, you can have really useful tooltips (event multi-line), in order to detail some synthetic data. Moreover, this rule is available for the form tooltip, but also for each individual field (property view) in the form.

BasicComponentViewDescriptor properties
Property Description

columnCount

int

Configures the number of columns on this component view. Property fields that are to be displayed in the view are spread across columns and rows following their defined order. Whenever a row does not contain enough empty cells to receive the next field (either because the last column has been reached or the next field has been configured to span multiple columns and there is not enough cells left in the current row to satisfy the span), a new row is created and the next field is added to the first column on the new row.

Note that column count and span are defined in fields coordinates (the field including the property UI component + its label). The underlying grid is actually finer since it has to cope with the labels; but this is internal implementation details and Jspresso takes care of it, without the developer having to cope with labels placements.

Default value is 1, meaning that all rendered fields will be stacked in a single column.

horizontallyScrollable

boolean

This property allows to define the form horizontal scrolling behaviour. Whenever it is set to true, the corresponding UI component will install a horizontal scroll bar when the available horizontal space is not enough.

Default value is false.

labelsHorizontalPosition

EHorizontal​Position

Configures the label horizontal position. There are special cases when the default label position has to be overridden. This is either a value of the EHorizontalPosition enum or its equivalent string representation :

  • LEFT for left position
  • RIGHT for right position

Default value is LEFT.

propertyWidths

Map​<​String​,Object​>​

This property allows to simply define property spans in the underlying grid without having to extensively define the propertyViewDescriptors property. It must be configured with a Map containing only the properties that need to span more than 1 column. The other properties will follow the default span of 1.

The Map is :

  • keyed by the name of the property
  • valued by the number of columns of the property span
Default value is null, meaning all property fields have a span of 1.

renderedChildProperties

Map​<​String​,List​>​

Whenever a rendered property is not scalar, this property allows to override which of the referenced component fields should be displayed :

  • as columns when the rendered property is a collection property
  • as fields when the rendered property is a reference property
The property must be configured with a Map which is :
  • keyed by the non-scalar property name
  • valued by the list of the property names to render for the child element(s)

A null value (default), means that all non-scalar properties will be rendered using default rendered properties as specified in their referenced model descriptor.

Please note that this is quite unusual to embed non-scalar properties directly in a component view. Although permitted, you won't have as much flexibility in the content layouting as you would have when using composite views; so the latter is by far recommended.

verticallyScrollable

boolean

This property allows to define the form vertical scrolling behaviour. Whenever it is set to true, the corresponding UI component will install a vertical scroll bar when the available vertical space is not enough.

Default value is false.

widthResizeable

boolean

This property allows to define the form horizontal fill behaviour. Whenever it is set to true, the corresponding UI component will fill all its available horizontal space.

Default value is true.


MobileComponentViewDescriptor

A mobile form view descriptor.

MobileComponentViewDescriptor properties
Property Description

excludedReadingProperties

List​<​String​>​

Sets filtered reading properties. Allows to configure the properties that will be excluded from the read-only page.

excludedWritingProperties

List​<​String​>​

Sets filtered writing properties. Allows to configure the properties that will be excluded from the editor page.

forClientTypes

List​<​String​>​

Sets for client types.

position

EPosition

Sets position.


AbstractTreeViewDescriptor

This descriptor is use to design a tree view. The way to define a tree view in Jspresso is a matter of assembling tree level descriptors hierarchically. A tree level descriptor is a group of sibling nodes that usually represent a component collection property. Each individual tree node collection can be secured by using role-based authorization (i.e. grantedRoles) on its descriptor.

AbstractTreeViewDescriptor properties
Property Description

childDescriptor

ITree​Level​Descriptor

Configures the first tree level as being a single collection of sibling nodes. For instance, if the child tree level is mapped to a collection (collA) containing 5 elements (collA_Elt-1 to 5), the tree would look like :

 rootItem
   collA_Elt-1
   collA_Elt-2
   collA_Elt-3
   collA_Elt-4
   collA_Elt-5
 

In the example above, you should notice that there is no need for the tree to install an intermediary node to visually group the collection elements since the collection is alone on its level.

This property is only used if the rootSubtreeDescriptor is not explicitly set. In the latter case, nested subtrees are determined from the rootSubtreeDescriptor.

childrenDescriptors

List​<​ITree​Level​Descriptor​>​

Configures the first tree level as being a list of collections of sibling nodes (subtrees). For instance, if the children tree levels are mapped to 2 collection properties (collA, collB) each containing 3 elements (collA_Elt-1 to 3 and collB_Elt-1 to 3), the tree would look like :

 rootItem
   collA
     collA_Elt-1
     collA_Elt-2
     collA_Elt-3
   collB
     collB_Elt-1
     collB_Elt-2
     collB_Elt-3
 

In the example above, you should notice intermediate collection property grouping nodes (collA and collB in italic). They automatically appeared to clearly group the tree nodes belonging to the different collections.

This property is only used if the rootSubtreeDescriptor is not explicitly set. In the latter case, nested subtrees are determined from the rootSubtreeDescriptor.

displayIcon

boolean

Configures if the tree view should show icon based on the icon image url provider. Defaults to true.

iconImageURLProvider

Icon​Provider

The icon image URL provider is the delegate responsible for inferring a tree node icon based on its underlying model. By default (i.e. when iconImageURLProvider is null), Jspresso will use the underlying component descriptor icon, if any. Using a custom icon image URL provider allows to implement finer rules like using different icons based on the underlying object state. There is a single method to implement to achieve this :

String getIconImageURLForObject(Object userObject);

itemSelectionAction

IAction

This property allows to bind an action that gets triggered every time the selection changes on the tree view. The action context passed to the action when it is executed is the same as if it had been registered on the tree view.

maxDepth

int

This property is used only when the tree (or sub-tree) is declared recursively, i.e. a tree level belongs to its own children hierarchy. Default value is 10, meaning that a maximum number of 10 levels can be nested.

renderedProperty

String

This property allows to define the model property used to label the root node.

This property is only used if the rootSubtreeDescriptor is not explicitly set. In the latter case, renderedProperty is determined from the rootSubtreeDescriptor.

rootSubtreeDescriptor

ITree​Level​Descriptor

This property allows to explicitly define the tree root level as any other level. Most of the time, you will prefer using the following shortcut properties :

  • childDescriptor
  • childrenDescriptors
  • renderedProperty
Whenever rootSubtreeDescriptor is explicitly set, the properties above are simply ignored since all values are determined from rootSubtreeDescriptor.

rowAction

IAction

Registers an action that is implicitly triggered every time a row is activated (e.g. double-clicked for current UI channels) on the collection view UI peer. The context of the action execution is the same as if the action was registered in the view action map.


BasicTreeViewDescriptor

This descriptor is use to design a tree view. The way to define a tree view in Jspresso is a matter of assembling tree level descriptors hierarchically. A tree level descriptor is a group of sibling nodes that usually represent a component collection property. Each individual tree node collection can be secured by using role-based authorization (i.e. grantedRoles) on its descriptor.

BasicTreeViewDescriptor properties
Property Description

expanded

boolean

Setting this property to true configures the created tree to appear with its node expanded. A value of false (default) means that the tree nodes are initially collapsed.


MobileTreeViewDescriptor

This descriptor is use to design a tree view. The way to define a tree view in Jspresso is a matter of assembling tree level descriptors hierarchically. A tree level descriptor is a group of sibling nodes that usually represent a component collection property. Each individual tree node collection can be secured by using role-based authorization (i.e. grantedRoles) on its descriptor.

MobileTreeViewDescriptor properties
Property Description

forClientTypes

List​<​String​>​

Sets for client types.

position

EPosition

Sets position.

showArrow

boolean

Sets show arrow.


BasicActionViewDescriptor

This type of view allows to make an action available as a view and thus participate in the UI composition as a visual component. An action view can then be embedded in surrounding a composite view. It literally takes the action away from the toolbar/context menu it is located when registered in an action map and makes it a primary citizen of the UI.

BasicActionViewDescriptor properties
Property Description

action

IDisplayable​Action

Assigns the action to display as a view. The action will typically be rendered as a button in the UI. Whenever you want to size the icon used to display the action (and thus the button peer), you might use the preferredWidth / preferredHeight properties.

actionList

Action​List

Assigns the action list to display as a view. The action will typically be rendered as a button bar in the UI.

renderingOptions

ERendering​Options

Indicates how the action should be rendered. This is either a value of the ERenderingOptions enum or its equivalent string representation :

  • LABEL_ICON for label and icon
  • LABEL for label only
  • ICON for icon only.

Default value is ERenderingOptions.ICON, i.e. icon only.


MobileActionViewDescriptor

A mobile action view descriptor.

MobileActionViewDescriptor properties
Property Description

forClientTypes

List​<​String​>​

Sets for client types.

position

EPosition

Sets position.


BasicCollectionViewDescriptor

This is the abstract base descriptor of all views used to display a collection of elements. A collection view must be backed by a collection descriptor model. Most of the time, the model will be a collection property descriptor so that the collection to display is directly inferred from the collection property value through the binding layer.

BasicCollectionViewDescriptor properties
Property Description

autoSelectFirstRow

boolean

Configures the default selection that gets applied when the content of the collection view changes. Whenever set to true, the 1st row will be automatically selected, whereas nothing happens when set to false.

The default value depends on the selection mode of the collection view. When a cumulative selection mode is used, autoSelectFirstRow defaults to false. It defaults to true otherwise.

itemSelectionAction

IAction

Registers an action that is implicitly triggered every time the selection changes on the collection view UI peer. The context of the action execution is the same as if the action was registered in the view action map.

modelDescriptor

IModel​Descriptor

{@inheritDoc}

paginationViewDescriptor

IView​Descriptor

Configures a view that will control the pagination (if any) on this collection view. When constructed, the collection view will be decorated with the pagination view. The pagination view will be bound to the same model as the one providing the collection of the collection view.

rowAction

IAction

Registers an action that is implicitly triggered every time a row is activated (e.g. double-clicked for current UI channels) on the collection view UI peer. The context of the action execution is the same as if the action was registered in the view action map.

selectionMode

ESelection​Mode

Sets the selection mode of the collection view. This is either a value of the ESelectionMode enum or its equivalent string representation :

  • MULTIPLE_INTERVAL_SELECTION for allowing any type of selection
  • MULTIPLE_INTERVAL_CUMULATIVE_SELECTION for allowing any type of selection with toggle behaviour
  • SINGLE_INTERVAL_SELECTION for allowing only contiguous interval selection
  • SINGLE_INTERVAL_CUMULATIVE_SELECTION for allowing only contiguous interval selection with toggle behaviour
  • SINGLE_SELECTION for allowing only a single item selection
  • SINGLE_CUMULATIVE_SELECTION for allowing only a single item selection with toggle behaviour

Default value is ESelectionMode.MULTIPLE_INTERVAL_SELECTION, i.e. any type of selection allowed.

selectionModelDescriptor

IModel​Descriptor

Sets the selectionModelDescriptor.


AbstractListViewDescriptor

This type of descriptor is used to implement a list view. A list view is a single column, un-editable collection view used to display a collection of components. Each item is displayed using a string representation that can be customized using the renderedProperty property. List views are rarely used since one might prefer its much more advanced cousin, i.e. the table view.

Despite its low usage as an individual UI component, the list view is also used by Jspresso to describe tree parts. A collection of sibling tree nodes can actually be considered as being a list view and can be described as such. In the latter case, the renderedProperty property will be used to label the tree nodes.

AbstractListViewDescriptor properties
Property Description

displayIcon

boolean

Configures if the list view should show icon based on the icon image url provider. Defaults to true.

iconImageURLProvider

Icon​Provider

The icon image URL provider is the delegate responsible for inferring a tree node icon based on its underlying model. By default (i.e. when iconImageURLProvider is null), Jspresso will use the underlying component descriptor icon, if any. Using a custom icon image URL provider allows to implement finer rules like using different icons based on the underlying object state. There is a single method to implement to achieve this :

String getIconImageURLForObject(Object userObject);

renderedProperty

String

Configures the model property to be rendered in the list. Whenever this property is left to null (default value), the toStringProperty of the element component descriptor is used.


BasicListViewDescriptor

This type of descriptor is used to implement a list view. A list view is a single column, un-editable collection view used to display a collection of components. Each item is displayed using a string representation that can be customized using the renderedProperty property. List views are rarely used since one might prefer its much more advanced cousin, i.e. the table view.

Despite its low usage as an individual UI component, the list view is also used by Jspresso to describe tree parts. A collection of sibling tree nodes can actually be considered as being a list view and can be described as such. In the latter case, the renderedProperty property will be used to label the tree nodes.

BasicListViewDescriptor properties
Property Description
This class does not have any specific property.

MobileListViewDescriptor

This type of descriptor is used to implement a list view. A list view is a single column, un-editable collection view used to display a collection of components. Each item is displayed using a string representation that can be customized using the renderedProperty property. List views are rarely used since one might prefer its much more advanced cousin, i.e. the table view.

Despite its low usage as an individual UI component, the list view is also used by Jspresso to describe tree parts. A collection of sibling tree nodes can actually be considered as being a list view and can be described as such. In the latter case, the renderedProperty property will be used to label the tree nodes.

MobileListViewDescriptor properties
Property Description

autoSelectFirstRow

boolean

Not supported in mobile environment.

{@inheritDoc}

forClientTypes

List​<​String​>​

Sets for client types.

position

EPosition

Sets position.

showArrow

boolean

Sets show arrow.


AbstractRepeaterViewDescriptor

This descriptor is used to implement a repeater view. A repeater view displays a collection of components, each one in an arbitrary view that is repeated as necessary. Repeater view supports selection by clicking one of the sections, so it can be used in a master-detail view. It also supports row action by double-clicking one of the sections.

AbstractRepeaterViewDescriptor properties
Property Description

repeatedViewDescriptor

IView​Descriptor

Configures the view to be repeated as many times as necessary to match the element count in the model collection.


BasicRepeaterViewDescriptor

This descriptor is used to implement a repeater view. A repeater view displays a collection of components, each one in an arbitrary view that is repeated as necessary.

BasicRepeaterViewDescriptor properties
Property Description
This class does not have any specific property.

MobileRepeaterViewDescriptor

This descriptor is used to implement a repeater view. A repeater view displays a collection of components, each one in an arbitrary view that is repeated as necessary.

MobileRepeaterViewDescriptor properties
Property Description

autoSelectFirstRow

boolean

Not supported in mobile environment.

{@inheritDoc}

forClientTypes

List​<​String​>​

Sets for client types.

position

EPosition

Sets position.


BasicTableViewDescriptor

This descriptor is used to implement a table view. This is certainly the most commonly used collection descriptor in Jspresso. A table view displays a collection of components (one row per component in the collection) detailed by a set of properties (one column per displayed component property).

The table view will automatically adapt its columns depending on the underlying property descriptors, e.g. :

  • columns for read-only properties won't be editable
  • columns that are assigned writability gates will compute the editability of their cells based on each cell's gates
  • columns will adapt their renderer/editor based on the underlying property type, e.g. a calendar component will be used for dates
  • column titles will be filled with property names translations based on the user locale
  • mandatory properties will be visually indicated
  • ...
A table view provides sensible defaults regarding its configuration, but it can be refined using either the simple renderedProperties or the more advanced yet lot more powerful columnViewDescriptors properties.

The description property is used to compute view tooltips and support the following rules :

  1. if the description is a property name of the underlying model, this property will be used to compute the (dynamic) tooltip (depending on the actual model).
  2. if the description is not a property name of the underlying model, the the tooltip is considered static and the translation will searched in the application resource bundles.
  3. if the description is the empty string (''), the tooltip is de-activated.
  4. if the description is not set, then the toHtml property (see toHtml property on entities / components definition) is used as dynamic property. And the toHtml falls back to the toString if not set, which falls back to the 1st string rendered property if not set.
Note that on every case above, HTML is supported. This way, you can have really useful tooltips (event multi-line), in order to detail some synthetic data. Moreover, this rule is available for the table rows tooltip, but also for each individual column (property view) in the table.

BasicTableViewDescriptor properties
Property Description

columnReorderingAllowed

boolean

Configures if the table view should allow for column reordering. The default value is true.

columnViewDescriptors

List​<​IProperty​View​Descriptor​>​

This property allows for configuring the columns of the table view in a very customizable manner, thus overriding the model descriptor defaults. Each property view descriptor contained in the list describes a table column that will be rendered in the UI accordingly.

For instance, a writable property can be made specifically read-only on this table view by specifying its column property view descriptor read-only. In that case, the model remains untouched and only the view is impacted.

Following the same scheme, you can assign a list of writability gates on a column to introduce dynamic cell editability on the view without modifying the model.

A last, yet important, example of column view descriptor usage is the role-based column set configuration. Whenever you want a column to be available only for certain user roles (profiles), you can configure a column property view descriptor with a list of granted roles. If the user doesn't have the column(s)required role, the forbidden columns simply won't be displayed. This allows for high authorization-based versatility.

There are many other usages of defining column property view descriptors all of them being linked to customizing the table columns without impacting the model.

horizontallyScrollable

boolean

This property allows to define the table horizontal scrolling behaviour. Whenever it is set to false, the corresponding table UI component will adapt its columns to fit the available horizontal space.

Default value is true, i.e. table columns will have their default size and tha table will scroll horizontally as needed.

renderedProperties

List​<​String​>​

This is somehow a shortcut to using the columnViewDescriptors property. Instead of providing a full-blown list of property view descriptors to configure the table columns, you just pass-in a list of property names. Table columns are then created from this list, keeping model defaults for all column characteristics.

Whenever the property value is null (default), the column list is determined from the collection element component descriptor renderedProperties property.

singleClickEdit

boolean

Configures the table view to enter edition on single clicks instead of double clicks.

sortable

boolean

This property allows to define the table horizontal sorting behaviour. Whenever it is set to false, the corresponding table UI component will not allow manual sorting of its rows.

Default value is true, i.e. table allows for its rows to be sorted.

sortingAction

IDisplayable​Action

Configures the action to be activated when a sort is triggered by the user. It should be used with caution and rarely be overridden from the default.


BasicMapViewDescriptor

This descriptor is used to implement a map view.

BasicMapViewDescriptor properties
Property Description

defaultZoom

Integer

Sets default zoom to display when there is no route and a single marker.

mapContentProperty

String

Sets map content property. The targeted property should return a Json string that describes the markers and the routes to display on the map.

markerAction

IDisplayable​Action

Sets marker action.

routeAction

IDisplayable​Action

Sets route action.

zoneAction

IDisplayable​Action

Sets zone action.


MobileMapViewDescriptor

A mobile map view descriptor.

MobileMapViewDescriptor properties
Property Description

forClientTypes

List​<​String​>​

Sets for client types.

inline

boolean

Sets inline.

position

EPosition

Sets position.


BasicPropertyViewDescriptor

This view descriptor serves 2 purposes :

  • configure complex, component based views : refine columns of table views and fields of component (form) views.
  • display a single property as an autonomous view, i.e. not as a table column or a form field.
The second usage might be a little bit unusual, but here is a use-case scenario : display a text area which maps a text property that contains XML content. This text area must be displayed in a split pane and provide actions to interact directly with the FS (save content to a file, load content from a file, ...). In that case, defining a property view alone on the text property of the owning component might be a good solution.

BasicPropertyViewDescriptor properties
Property Description

action

IAction

Configures the action to be triggered when acting on this property. There are 2 cases :

  1. If the property is read-only, then assigning an action turns the property into a clickable hyperlink
  2. If the property is read-write, the registered action will be triggered when the user changes the value of the field. Note that in that case, the action is executed after the model has been updated. However the old property value can be retrieved from the context action param.

focusGainedAction

IAction

Sets focus gained action.

focusLostAction

IAction

Sets focus lost action.

forClientTypes

List​<​String​>​

Sets for client types.

horizontalAlignment

EHorizontal​Alignment

This property allows to control the property alignment in views that support it. This is either a value of the EHorizontalAlignment enum or its equivalent string representation :

  • LEFT for left alignment
  • CENTER for center alignment
  • RIGHT for right alignment

Default value is null, meaning use property type default.

labelBackground

String

When the property has to be labelled (e.g. in a component view), this property defines the background color of the corresponding label. It might differ from the field component one. The color must be defined using its string hexadecimal representation (0xargb encoded).

Default value is null, meaning use UI default.

labelFont

String

When the property has to be labelled (e.g. in a component view), this property defines the font of the corresponding label. It might differ from the field component one. The font must be string encoded using the pattern "[name];[style];[size]" :

  • [name] is the name of the font, e.g. arial.
  • [style] is PLAIN, BOLD, ITALIC or a union of BOLD and ITALIC combined with the '|' character, e.g. BOLD|ITALIC.
  • [size] is the size of the font, e.g. 10.
Any of the above pattern section can be left empty, thus falling back to the component default.

Default value is null, meaning use default component font.

labelForeground

String

When the property has to be labelled (e.g. in a component view), this property defines the foreground color of the corresponding label. It might differ from the field component one. The color must be defined using its string hexadecimal representation (0xargb encoded).

Default value is null, meaning use UI default.

labelHorizontalPosition

EHorizontal​Position

Configures the label horizontal position. There are special cases when the default label position has to be overridden. This is either a value of the EHorizontalPosition enum or its equivalent string representation :

  • LEFT for left position
  • RIGHT for right position

Default value is LEFT.

renderedChildProperties

List​<​String​>​

Whenever the property descriptor backing the view is not scalar, this property allows to override which of the referenced component fields should be displayed :

  • as columns when the rendered property is a collection property
  • as fields when the rendered property is a reference property
The property must be configured with a List containing the property names to render for the child element(s).

A null value (default), means that the non-scalar property will be rendered using default rendered properties as specified in its referenced model descriptor.

Please note that this is quite unusual to embed non-scalar properties directly in a property view. Although permitted, you won't have as much flexibility in the content layouting as you would have when using composite views; so the latter is by far recommended.

sortable

boolean

Configure the sortability of a property view when used to defines a table column for instance. Whenever it is not explicitly set, it falls back to the model property sortability. If no model descriptor is set, defaults to true.

width

Integer

When the property has to be displayed in a grid-like layout (e.g. in a component view), this property defines the umber of grid columns the corresponding UI component will span.

Default value is null, meaning use default span of 1.


BasicDatePropertyViewDescriptor

This specialized property view descriptor is used in order to be able to refine the "format" that is used to parse and format dates.

BasicDatePropertyViewDescriptor properties
Property Description

formatPattern

String

Sets format pattern. Allows to override the default one.


BasicEnumerationPropertyViewDescriptor

This specialized property view descriptor is used in order to be able to refine the "values" that are taken from the model enumeration. You can configure a set of allowed values from which the user can choose.

BasicEnumerationPropertyViewDescriptor properties
Property Description

allowedValues

Set​<​String​>​

Returns an optional forbidden set of values to restrict the model ones. Only values belonging to the allowed ones should actually be made available as a choice.

enumIconDimension

Dimension

Sets the icon dimension.

enumIconHeight

int

Sets the enumeration icon height.

enumIconWidth

int

Sets the enumeration icon width.

forbiddenValues

Set​<​String​>​

Returns an optional forbidden set of values to restrict the model ones. Only values not belonging to the forbidden ones should actually be made available as a choice.

orientation

EOrientation

Configures whether radio values be rendered horizontally or vertically. HORIZONTAL if radio values should be rendered horizontally and VERTICAL otherwise. Default value is VERTICAL.

radio

boolean

Configures the rendering of the enumeration property as radio buttons if supported instead of combo box. Default value is false.


BasicHtmlViewDescriptor

This type of view descriptor is used to display a a string property containing HTML text. The objective is to be able to configure scrollability of the HTML component.

BasicHtmlViewDescriptor properties
Property Description

editorConfiguration

String

Sets editor configuration.

horizontallyScrollable

boolean

Sets the horizontallyScrollable.

verticallyScrollable

boolean

Configures the view to be either vertically cropped or scrollable when the display area is too small to display it.


BasicImageViewDescriptor

This type of view descriptor is used to display a binary property or a string property containing an URL as an image. By default, binary properties are rendered as button fields that allow to upload, download and query size of the binary content. This button field visually indicate whether the binary property is empty or not. Whenever you know that the underlying property is used to store image content, you can explicitly define an image view backed by the binary property descriptor and use it in your UI. Jspresso will then display the image whose content is stored in the binary property directly in the UI.

BasicImageViewDescriptor properties
Property Description

drawable

boolean

Configures whether this image view can be modified by the user drawing in the screen, e.g. a POD signature. Defaults to false.

keepRatio

boolean

Sets keep ratio.

scaledHeight

Integer

Sets scaled height. This property, when set to a positive integer will force the image height to be resized to the target value. If only one of the 2 scaled dimensions is set, then the image is scaled by preserving its aspect ratio.

scaledWidth

Integer

Sets scaled width. This property, when set to a positive integer will force the image width to be resized to the target value. If only one of the 2 scaled dimensions is set, then the image is scaled by preserving its aspect ratio.

scrollable

boolean

Configures the image view to be either cropped or scrollable when the display area is too small to display it. A value of true (default) means that the image view will be made scrollable.


BasicNestedComponentPropertyViewDescriptor

This specialized property view descriptor is used in order to display a nested component view.

BasicNestedComponentPropertyViewDescriptor properties
Property Description

nestedComponentViewDescriptor

IComponent​View​Descriptor

Sets nested component view descriptor.


BasicNumberPropertyViewDescriptor

This specialized property view descriptor is used in order to be able to refine the "format" that is used to parse and format numbers.

BasicNumberPropertyViewDescriptor properties
Property Description

formatPattern

String

Sets format pattern. Allows to override the default one.


BasicStaticTextViewDescriptor

This type of view descriptor is used to display a static text in a form as if it was a property.

BasicStaticTextViewDescriptor properties
Property Description

i18nTextKey

String

Configures the key to be used for getting the translated static text.

multiLine

boolean

Configures the static text to display as multi line. This is false by default.

readOnly

Boolean

Sets read only.


BasicStringPropertyViewDescriptor

This type of view descriptor is used to display a string property. The objective is to be able to configure an action bound to character typing.

BasicStringPropertyViewDescriptor properties
Property Description

characterAction

IDisplayable​Action

Configures an action that gets triggered every time the text is changed in the field.


BasicReferencePropertyViewDescriptor

This specialized property view descriptor is used in order to be able to refine the "List of values" action that gets automatically installed by Jspresso when a reference property is displayed. You can then customize this action when defining the corresponding column in a table view or field in a component view.

BasicReferencePropertyViewDescriptor properties
Property Description

autoCompleteEnabled

boolean

Sets auto complete enabled. I set to false, then the field will always be read-only whereas the LOV action button will follow enabled / disabled rules.

lovAction

IDisplayable​Action

Allows to override the default "List of values" action attached to this reference property view.

A null value (default) keeps the standard action.


BasicTimePropertyViewDescriptor

This specialized property view descriptor is used in order to be able to refine the "format" that is used to parse and format times.

BasicTimePropertyViewDescriptor properties
Property Description

formatPattern

String

Sets format pattern. Allows to override the default one.


BasicTreeLevelDescriptor

BasicTreeLevelDescriptor

This is the base descriptor for all tree levels. A tree level is a collection of sibling nodes that belong to the same formal collection (usually a component collection property). This base descriptor does not accept nested subtrees so it is only used to describe a collection of leaf nodes. If you need to describe intermediary tree levels, yous will use one of the 2 subtypes :

  • BasicSimpleTreeLevelDescriptor to define a collection of tree nodes that accept a single subtree
  • BasicCompositeTreeLevelDescriptor to define a collection of tree nodes that accept a list of subtrees
Defining a tree level is mainly a matter of defining its representation as an individual list of components (i.e. the nodeGroupDescriptor property).

BasicTreeLevelDescriptor properties
Property Description

grantedRoles

Collection​<​String​>​

Assigns the roles that are authorized to use this subtree. It supports "!" prefix to negate the role(s). Whenever the user is not granted sufficient privileges, the subtree is simply hidden. Setting the collection of granted roles to null (default value) disables role based authorization on the node group level. The framework then checks for the model roles authorizations and will apply the same restrictions. If both view and model granted roles collections are null, then access is granted to anyone.

nodeGroupDescriptor

IList​View​Descriptor

Describes the collection of sibling nodes (node group) as a if it were a list view. This is how you instruct Jspresso the type of the components that are used as model behind the tree nodes and which model property is used to compute the node labels. Most of the other properties defined on the node group descriptor itself are ignored (font, color, selection action, ...) since a tree group is not a "real" view but just a mean of defining a subtree. All these properties that are ignored on the tree group can be defined on the tree view itself.

permId

String

Sets the permanent identifier to this application element. Permanent identifiers are used by different framework parts, like dynamic security or record/replay controllers to uniquely identify an application element. Permanent identifiers are generated by the SJS build based on the element id but must be explicitly set if Spring XML is used.


BasicCompositeTreeLevelDescriptor

This descriptor is used to describe a collection of sibling nodes that each nest multiple subtrees. The children subtrees are each placed under an intermediary grouping node. For instance, given a composite tree level mapping a collection of As and whose children are 2 tree levels mapping respectively a collection Ys and Zs, the tree would look like :

 parent
   A-1
     collY
       Y-1.1
       Y-1.2
     collZ
       Z-1.1
       Z-1.2
       Z-1.3
   A-2
     collY
       Y-2.1
       Y-2.2
       Y-2.3
     collZ
       Z-2.1
   A-3
     collY
       Y-3.1
       Y-3.2
     collZ
       Z-3.1
       Z-3.2
 

You can notice the intermediary grouping nodes that are installed to visually separate the 2 collection families (Y and Z).

BasicCompositeTreeLevelDescriptor properties
Property Description

childrenDescriptors

List​<​ITree​Level​Descriptor​>​

Assigns the list children tree level descriptors. A null value (default) makes this tree level a leaf tree level and is strictly equivalent to declaring a BasicTreeLevelDescriptor instead.


BasicSimpleTreeLevelDescriptor

This descriptor is used to describe a collection of sibling nodes that only nest a single subtree. The child subtree is directly placed under each node without any intermediary grouping node. For instance, given a simple tree level mapping a collection of As and whose child is a tree level mapping a collection of Bs, the tree would look like :

 parent
   A-1
     B-1.1
     B-1.2
     B-1.3
   A-2
     B-2.1
   A-3
     B-3.1
     B-3.2
 
BasicSimpleTreeLevelDescriptor properties
Property Description

childDescriptor

ITree​Level​Descriptor

Assigns the single child tree level descriptor. A null value (default) makes this tree level a leaf tree level and is strictly equivalent to declaring a BasicTreeLevelDescriptor instead.


Composite views

Overview

View descriptors diagram

Reference

BasicCompositeViewDescriptor

BasicCompositeViewDescriptor

This is the abstract base class for all composite views. A composite view is a view that arranges a collection of nested views in a predefined layout. Nested views can also be composite views which makes it possible to build complex UIs out of simple combinations. Composite views are also the foundation of master-detail views by allowing a nested view to take its model out of the selection of the previous one. This behaviour can be activated using the cascadingModels property that "cascades" the view models based on the selected elements. Whenever this behaviour is not activated, all nested views share the same model than their parent composite unless specified otherwise.

BasicCompositeViewDescriptor properties
Property Description

cascadingModels

boolean

Enables the model "cascading" behaviour. This allows for instance to link 2 nested tables where the 2nd table model is the selected row of the first table (or null if selection is empty). Using cascadingModel=true is only necessary when tracking view selection on the master nested view. You don't need it if, for instance, the master nested view is a single model view like a component view. In the latter case, you can bind a table detail view just by adding it to the same composite without having to set cascadingModel=true.

Default value is false, i.e. al nested views share the same model than the outer composite unless explicitly specified differently.

horizontallyScrollable

boolean

This property allows to define the form horizontal scrolling behaviour. Whenever it is set to true, the corresponding UI component will install a horizontal scroll bar when the available horizontal space is not enough.

Default value is false.

verticallyScrollable

boolean

This property allows to define the form vertical scrolling behaviour. Whenever it is set to true, the corresponding UI component will install a vertical scroll bar when the available vertical space is not enough.

Default value is false.


AbstractMobilePageViewDescriptor

Abstract base class for mobile page view descriptors.

AbstractMobilePageViewDescriptor properties
Property Description

backAction

IDisplayable​Action

Sets back action.

enterAction

IDisplayable​Action

Sets enter action.

forClientTypes

List​<​String​>​

Sets for client types.

i18nDescription

String

Sets i 18 n description.

i18nHeader

String

Sets i 18 n header.

i18nName

String

Sets i 18 n name.

mainAction

IDisplayable​Action

Sets main action.

pageEndAction

IDisplayable​Action

Sets page end action.

position

EPosition

Sets position.

swipeLeftAction

IDisplayable​Action

Sets swipe left action.

swipeRightAction

IDisplayable​Action

Sets swipe right action.


MobileCardPageViewDescriptor

A card view descriptor that aggregates other pages as card.

MobileCardPageViewDescriptor properties
Property Description

cascadingModels

boolean

Sets cascading models. This operation is not supported on mobile pages.

pagesCardViewDescriptor

ICard​View​Descriptor

Sets pages.


MobileCompositePageViewDescriptor

A composite view descriptor that aggregates view sections on a single page.

MobileCompositePageViewDescriptor properties
Property Description

cascadingModels

boolean

Sets cascading models. This operation is not supported on mobile pages.

editorPage

Mobile​Composite​Page​View​Descriptor

Sets editing page.

inlineEditing

boolean

Sets inline editing.

pageSectionDescriptors

List​<​IMobile​View​Descriptor​>​

Sets page sections.


MobileNavPageViewDescriptor

Navigation page view descriptors that are able to navigate to another page based on a selection component.

MobileNavPageViewDescriptor properties
Property Description

cascadingModels

boolean

Sets cascading models. This operation is not supported on mobile lists.

headerSectionDescriptors

List​<​IMobile​View​Descriptor​>​

Sets header section descriptors.

nextPageViewDescriptor

IMobile​Page​View​Descriptor

Sets next page.

selectionViewDescriptor

IView​Descriptor

Sets selection view. Supports only tree or list.


BasicBorderViewDescriptor

A border view is a composite view that arranges its children to the north, west, east, south and center. Depending its position in the container, the resizing rules apply differently :

  • north and south are resized horizontally and kept to their preferred size vertically
  • west and east are resized vertically and kept to their preferred size horizontally
  • center is resized both horizontally and vertically
Default cascading order for master-detail is :

north -> west -> center -> east -> south

BasicBorderViewDescriptor properties
Property Description

centerViewDescriptor

IView​Descriptor

Sets the child view to layout in the center zone. The child view will be resized both horizontally and vertically.

eastViewDescriptor

IView​Descriptor

Sets the child view to layout in the east zone. The child view will be resized vertically.

northViewDescriptor

IView​Descriptor

Sets the child view to layout in the north zone. The child view will be resized horizontally.

southViewDescriptor

IView​Descriptor

Sets the child view to layout in the south zone. The child view will be resized horizontally.

westViewDescriptor

IView​Descriptor

Sets the child view to layout in the west zone. The child view will be resized vertically.


MobileBorderViewDescriptor

A composite view descriptor that aggregates mobile views.

MobileBorderViewDescriptor properties
Property Description

backAction

IDisplayable​Action

Sets back action.

eastViewDescriptor

IView​Descriptor

Not supported in mobile environment.

{@inheritDoc}

enterAction

IDisplayable​Action

Sets enter action.

forClientTypes

List​<​String​>​

Sets for client types.

i18nHeader

String

Sets i 18 n header.

mainAction

IDisplayable​Action

Sets main action.

pageEndAction

IDisplayable​Action

Sets page end action.

position

EPosition

Sets position.

swipeLeftAction

IDisplayable​Action

Sets swipe left action.

swipeRightAction

IDisplayable​Action

Sets swipe right action.

westViewDescriptor

IView​Descriptor

Not supported in mobile environment.

{@inheritDoc}


BasicConstrainedGridViewDescriptor

This composite view arranges its children in a grid where cell behaviour and dimensions are configured using cell constraints. A cell constraint is a simple data structure holding the following properties :

  • row: the row to which the cell belongs
  • column: the column to which the cell belongs
  • width: the number of columns the cell spans horizontally (default value is 1)
  • height: the number of rows the cell spans vertically (default value is 1)
  • heightResizable: whether the cell should be resized to take all the available space vertically
  • widthResizable: whether the cell should be resized to take all the available space horizontally
Default cascading order follows the order of nested view registrations in the container.

BasicConstrainedGridViewDescriptor properties
Property Description

cells

Map​<​IView​Descriptor​,Cell​Constraints​>​

Registers the nested children views along with their cell constraints. They are set as a Map that is :

  • keyed by the children views
  • valued by the cell constraints to apply to each nested view


BasicEvenGridViewDescriptor

This composite view arranges its children in a grid where cells are distributed evenly. All cells are resized horizontally and vertically to fill its available space.

The number of cells in a row / column is determined by the combination of the drivingDimension and drivingDimensionCellCount properties. the cells are spread along the driving dimension (row or column) until the maximum number of cells in the dimension has been reached. Then a new row (or column) is added. The process repeats until all the cells have been added.

This container does not allow for individual cell configuration like row/column spanning. Whenever cell disposition has to be customized more finely, a BasicConstrainedGridViewDescriptor should be used instead.

Default cascading order follows the order of nested view registrations in the container.

BasicEvenGridViewDescriptor properties
Property Description

cells

List​<​IView​Descriptor​>​

Registers the nested views to display as grid cells.

drivingDimension

EAxis

Configures the driving dimension of the grid. This is either a value of the EAxis enum or its equivalent string representation :

  • ROW for distributing cells along rows then columns
  • COLUMN for distributing cells along columns then rows
Default value is EAxis.ROW, i.e. distribute cells along rows then columns.

drivingDimensionCellCount

int

This property configures the maximum number of cells in the driving dimension (row or column). Nested views are distributed along the driving axis until this maximum number has been reached. A new row or column is then created to host the remaining cells.


MobileEvenGridViewDescriptor

A composite view descriptor that aggregates mobile views.

MobileEvenGridViewDescriptor properties
Property Description

backAction

IDisplayable​Action

Sets back action.

drivingDimension

EAxis

Not supported in mobile environment.

{@inheritDoc}

drivingDimensionCellCount

int

Not supported in mobile environment.

{@inheritDoc}

enterAction

IDisplayable​Action

Sets enter action.

forClientTypes

List​<​String​>​

Sets for client types.

i18nHeader

String

Sets i 18 n header.

mainAction

IDisplayable​Action

Sets main action.

pageEndAction

IDisplayable​Action

Sets page end action.

position

EPosition

Sets position.

swipeLeftAction

IDisplayable​Action

Sets swipe left action.

swipeRightAction

IDisplayable​Action

Sets swipe right action.


BasicSplitViewDescriptor

This composite view arranges its children in a container split either horizontally or vertically. An horizontal split disposes its 2 children left and right whereas a vertical split disposes its 2 children top and bottom. The dividing bar can typically be moved by the user to distribute the available space.

Default cascading order for master-detail is :

left -> right or top -> bottom depending on the split orientation.

BasicSplitViewDescriptor properties
Property Description

leftTopViewDescriptor

IView​Descriptor

Sets the left (horizontal split) of top (vertical split) nested view.

orientation

EOrientation

Configures the split orientation of the container. This is either a value of the EOrientation enum or its equivalent string representation :

  • VERTICAL for splitting the container vertically and arranging the views top and bottom
  • HORIZONTAL for splitting the container horizontally and arranging the views left and right
Default value is EOrientation.VERTICAL, i.e. the container is split vertically.

rightBottomViewDescriptor

IView​Descriptor

Sets the right (horizontal split) of bottom (vertical split) nested view.

separatorPosition

Integer

Sets separator position.


BasicTabViewDescriptor

This composite view arranges its children in tabs. Each tab potentially displays a label (that is translated based on the name of the view in the tab), an icon (based on the icon of the view in the tab) and a toolTip (based on the description of the view in the tab).

Default cascading order follows the order of nested view registrations in the container.

BasicTabViewDescriptor properties
Property Description

lazy

boolean

When set to true, this parameter configures the tabs to be lazy bound (binding occurs only for the selected tab). This feature is only supported for tab views with cascadingModel set to false. default value is true.

renderingOptions

ERendering​Options

Indicates how the tabs should be rendered. This is either a value of the ERenderingOptions enum or its equivalent string representation :

  • LABEL_ICON for label and icon
  • LABEL for label only
  • ICON for icon only.

Default value is ERenderingOptions.LABEL_ICON, i.e. label and icon.

selectFirstTab

boolean

If true, the tab view will select its the first tab each time its model changes. Default value is {@false}.

tabSelectionAction

IAction

Registers an action that is implicitly triggered every time the tab selection changes on the tab view UI peer. The context of the action execution is the same as if the action was registered in the view action map.

tabs

List​<​IView​Descriptor​>​

Registers the list of views to be displayed as tabs. The tabs order follows the children views order of this list.


MobileTabViewDescriptor

A composite view descriptor that aggregates mobile views.

MobileTabViewDescriptor properties
Property Description

carouselMode

boolean

Sets carousel mode.

cascadingModels

boolean

Not supported in mobile environment.

{@inheritDoc}

forClientTypes

List​<​String​>​

Sets for client types.

position

EPosition

Sets position.


results matching ""

    No results matching ""