JeeWiz Home  
The Model-Driven System Builder

JeeWiz Architect's Guide
 
Contents  >   14.  'Business Object' Reference
 


14.16 DataView Object

SuperclassbaseView
DescriptionThe data view is a means of receiving and supplying data for client-facing components, such as web pages or web services. In other words, a data-view allows information to be moved intelligently between processing tiers, mapping between what the user wants to see and what the data store holds.

A data-view can be inbound (for client input), outbound (present fields read from persistent storage) and combinations of in- and outbound. The data-view also has data aggregation and manipulation features:

  • there can be an underlying entity (the 'initial entity') and attributes of entities related to that can be included in the data-view

  • virtual (calculated) fields can be presented

  • attributes in persistent storage can be calculated from input fields.
Data-views can be updated. In the standard implementation, data-views are read by direct SQL calls (to optimise performance) with the SQL being build automatically, but updated via entity beans or their .NET equivalent (to reuse validation and entity processing logic).

Validation can be specified on the data view or its fields, and this is additional to the validation from information tied to persistent storage.

Data-views are typically processed by one or more session bean methods. Therefore, the data-view is a way of specifying the data required for a UML use case and how that is mapped onto the data tier.

Data views can be related to a number of other data views. For example, an Order/OrderLine screen could require a set of information for the Order and a related set of information for the OrderLine. This is represented as a relationship between data-views, in just the same way that entities or data-base tables are related.

The data-view pattern is a superset of the 'transfer object assembler' Core J2EE pattern.

A value object (also known as the transfer object) is automatically generated for the data-view.
Contained
Lists
1
Name  typeParameter
Type  java:typeParameter
Inherited from  java:referenceType
 
2
Name  import
Type  String
Inherited from  java:referenceType
 
3
Name  field
Type  java:field
Inherited from  internalClass
 
4
Name  method
Type  java:method
Inherited from  internalClass
 
5
Name  implements
Type  String
Inherited from  java:jwclass
 
6
Name  constraint
Type  constraint
Inherited from  internalClass
 
7
Name  style
Type  String
Inherited from  internalClass
 
8
Name  dataViewToAttributeMapper
Type  dataViewToAttributeMapper
Indexed property  name
 
9
Name  rolesReadonly
Type  String
Inherited from  entity
 
10
Name  rolesAllowed
Type  String
Inherited from  entity
 
11
Name  rolesBlocked
Type  String
Inherited from  entity
Validation The 'generateMaintenancePages' flag must not be set if there is no initial entity
Inherited
properties
name from baseView.name

description from java:interfaceMethod.description

template from java:interfaceMethod.template

text from java:method.text

jwpattern (base property)

typeDeclaration from java:referenceType.typeDeclaration

extends from java:referenceType.extends

headerComment from java:referenceType.headerComment

customerHeaderComment from java:referenceType.customerHeaderComment

package from baseViewRelation.package

generateLogLevel from constraint.generateLogLevel

access from baseView.access

annotation from java:interfaceMethod.annotation

abstract from java:method.abstract

static from java:method.static

serializable from java:jwclass.serializable

final from java:method.final

alwaysGenerateTriggers from internalClass.alwaysGenerateTriggers

constraintExceptionType from constraint.constraintExceptionType

uid from constraint.uid

group from businessMethod.group

userNameBase from businessMethod.userNameBase

supportsUpload from baseView.supportsUpload

generateMaintenancePages from baseView.generateMaintenancePages

lookupPageCreated from baseView.lookupPageCreated

generateMaintenanceSession from baseView.generateMaintenanceSession

convertEmptyStringsToNull from baseView.convertEmptyStringsToNull

generateDataviewImplClass from baseView.generateDataviewImplClass

screenPosition from baseView.screenPosition

initialEntity from baseView.initialEntity

sqlStatement from baseView.sqlStatement

additionalWhereClause from baseView.additionalWhereClause

sqlOrder from baseView.sqlOrder

container from baseView.container

dataviewTriggers from baseView.dataviewTriggers

 14.16.1  Property 'lockOnRead'
 14.16.2  Property 'viewIsReferencedByPage'

14.16.1  Property 'lockOnRead'
DescriptionDataview uses "select for update", locking the row for the transaction. Columnar locking (ie. select for update of ... ) is unavailable. Not for use on linked dataviews.
Typeboolean
Defaultfalse

14.16.2  Property 'viewIsReferencedByPage'
DescriptionSet this flag to 'true' by patterns to note that the view is referenced by a page.
Typeboolean
Defaultfalse
 


Copyright (c) 2001-2008 New Technology/enterprise Ltd.