Define a field across XML, SQL, and Java. Found inside of class elements.
Attribute | Description | Required |
name | the name of the field (in Java). | Yes |
type | primitive type (see list) or a fully qualified Java class name (if it should be stored it should be in a map-file which is generated along with this one. | |
collection | currently ("vector", "array") types supported. | No |
len | if a string field reqd if database field, and can also be used for generated validation. | Only if a (database class or for validators) and a string |
required | boolean which defines this field to be required (NOT NULL in a db, != null in validator). | No (defaults to false) |
provides the field name in the db and any constraints/constraint-names.
provides the field name in xml.
defines any views this field belongs to.
defines any validations needed on this field.
<field name="name" type="string" len="32"> <sql name="foo_name" /> <validate regex="[a-zA-Z .]*" /> <view in="blotter" /> </field> <field name="otherFoo" type="org.Foo" > <sql name="foo_other_oid" constraint-name="foo_has_other_foo" /> <view in="blotter" foreign-view="blotter" /> </field>
Copyright © 2000,2001,2002 Paul Bethe and Richie Bielak. All rights Reserved.