Fields in Codejig Builder
Fields are blocks which composite data types are built from. Fields in Codejig Builder are quite similar to fields in Java or any other general purpose development environment. There are three kinds of fields in Codejig Builder: Regular fields, Collections and Dynamic fields.
Any field could be marked as transient. Transient fields aren't stored in database and are mostly used to store and present to user temporary and calculated data.
Regular are the most basic part of composite data types. Regular fields are strongly typed, i.e. can contain only data of the specified type. Field type is defined during creation and can't be changed later. Regular field Regular fields could be either of value-type (primitives, embeddeds) or reference-type (all composite data types except embeddeds). For more detais about data types, see a corresponding article. To understand the difference between value-types and reference-types consider the following example:
Collection field of embedded data type:
- Behaves as value-type (as well as regular field of embedded type)
- Is ordered. Order of items is defined by relativeOrder system shared field (see System defined shared fields for more details). The order can be changed either with code or with ui.
- Its items an be modified in-place directly in owner's form.
- Is a collection of references.
- Is unordered.
- Its items can't be only added or removed, but not modified in-place. For modification we should use an update page of referenced instance.