SJS Domain reference
Reference for SJS Domain
Root
Domain
- mandatory :
projectName
- allowed next element :
Entity, Interface, Component, external, paramSet
This root descriptor is used in the file application.groovy generated during the initialization of the project by Jspresso. There is generally no need to change it.
Property | Description |
---|---|
projectName
|
Project name |
mute
|
Lets say if SJS is verbose or not during the generation process |
includeDirectory
|
indicates in which directory are the include files |
Component
Entity
- allowed previous element :
Domain
- allowed next element :
string, text, imageUrl, password, integer, date, bool, decimal, time, duration, percent, enumeration, typeEnumeration, range, refId, color, binary, image, java, any, sourcecode, html, reference, list, set, paramSet
- Jspresso :
BasicEntityDescriptor
This descriptor key to the description of the application model. It is used to describe a model entity.
The description of an entity can be very simple :
Entite('person'){ string_32 'name' string_32 'firstName' integer age }
or be richer to meet more complex needs :
Entity('Department', extend: 'OrganizationalUnit', icon: 'department-48x48.png', rendered: ['ouId', 'name', 'manager', 'contact', 'createTimestamp', 'lastUpdateTimestamp']) { reference 'company', ref: 'Company', reverse: 'Company-departments', mandatory: true, composition: true set 'teams', ref: 'Team', composition: true }
Note :
Concurrent access conflicts are automatically manage by Jspresso through optimistic locking
Property | Description |
---|---|
extend
|
Registers this Entity with a collection of ancestors. It directly translates the components inheritance hierarchy since the component property descriptors are the union of the declared property descriptors of the component and of its ancestors one. A component may have multiple ancestors which means that complex multiple-inheritance hierarchy can be mapped Interface('Nameable') { string_64 'name', mandatory: true } Entity('City', extend: 'Nameable'){...} |
description
|
Sets the description of this descriptor. Most of the descriptor descriptions are used in conjunction with the Jspresso i18n layer so that the description property set here is actually an i18n key used for translation. Description is mainly used for UI (in tooltips for instance) but may also be used for project technical documentation, contextual help, ... |
icon
|
Sets the icon image URL of this descriptor. Supported URL protocols include :
Interface('Traceable', icon: 'traceable-48x48.png'){...} |
iconWidth
|
Allows to define a custom width for the icon. In that case, the default dimension computed by the view factory is ignored. |
iconHeight
|
Allows to define a custom height for the icon. In that case, the default dimension computed by the view factory is ignored. |
rendered
|
This property allows to define which of the component properties are to be rendered by default when displaying a UI based on this component family. For instance, a table will render 1 column per rendered property of the component. Any type of property can be used except collection properties. Since this is a List queriable properties are rendered in the same order. Whenever this property is null (default value) Jspresso determines the default set of properties to render based on their types, e.g. ignores collection properties. Note that this property is not inherited by children descriptors, i.e. even if an ancestor defines an explicit set of rendered properties, its children ignore this setting. Entity('Employee', rendered: ['name', 'firstName', 'ssn', 'age']){...} |
queryable
|
This property allows to define which of the component properties are to be used in the filter UIs that are based on this component family (a QBE screen for instance). Since this is a List queriable properties are rendered in the same order. Whenever this this property is null (default value), Jspresso chooses the default set of queryable properties based on their type. For instance, collection properties and binary properties are not used but string, numeric, reference, ... properties are. A computed property cannot be used since it has no data store existance and thus cannot be queried upon. Note that this property is not inherited by children descriptors, i.e. even if an ancestor defines an explicit set of queryable properties, its children ignore this setting Entity('Employee', queryable: ['name', 'firstName', 'ssn', 'age']){...} |
uncloned
|
Configures the properties that must not be cloned when this component is duplicated. For instance, tracing informations like a created timestamp should not be cloned; a SSN neither. For a given component, the uncloned properties are the ones it defines augmented by the ones its ancestors define. There is no mean to make a component property clonable if one of the ancestor declares it un-clonable. Entity('Employee', uncloned: ['managedOu', 'ssn']){...} |
ordering
|
Ordering properties are used to sort un-indexed collections of instances of components backed by this descriptor. This sort order can be overridden on the finer collection property level to change the way a specific collection is sorted. This property consist of a Map whose entries are composed with the property name as key and the sort order for this property as String "ASCENDING" or "DESCENDING" Entity('Employee', ordering: [name: "ASCENDING"]){...} |
pageSize
|
Whenever a collection of this component type is presented in a pageable UI, this property gives the size (number of component instances) of one page. This size can usually be refined at a lower level (e.g. at reference property descriptor for "lists of values"). A null value (default) disables paging for this component. Entity('Employee', pageSize: 10){...} |
autoQuery
|
Whenever this component is used as a query filter, this enables / disables auto-query when typing or loosing focus on a filter field. |
sqlName
|
Instructs Jspresso to use this name when translating this component type name to the data store namespace. This includes , but is not limited to, database table names. By default Jspresso uses its default naming policy Entity('Employee', sqlName: "T_EMPLOYEE"){...} |
grantedRoles
|
Assigns the roles that are authorized to manipulate components backed by this descriptor. This will directly influence the UI behaviour and even composition. Note that this authorization enforcement does not prevent programatic access that is of the developer responsbility. Entity('Employee',grantedRoles: ['administrator', 'manager']){...} |
booleanWritabilityGates
|
Assigns a collection of gates to determine component writability. A component will be considered writable (updatable) if and only if all booleanGates gates are open. entity 'invoice', booleanWritabilityGates: ['val1', '!val2']
|
booleanReadabilityGates
|
Assigns a collection of gates to determine component readability. A component will be considered readable (updatable) if and only if all booleanGates gates are open. entity 'invoice', booleanWritabilityGates: ['val1', '!val2']
|
rolesWritabilityGates
|
Assigns a collection of gates to determine component writability. A component will be considered writable (updatable) if and only if all RolesGates gates are open. entity 'invoice', rolesWritabilityGates: ['role1', '!role2']
|
rolesReadabilityGates
|
Assigns a collection of gates to determine component readability. A component will be considered readable (updatable) if and only if all RolesGates gates are open. entity 'invoice', rolesReadabilityGates: ['role1', '!role2']
|
enumWritabilityGates
|
Assigns a collection of gates to determine component writability. A component will be considered writable (updatable) if and only if all enum gates are open. entity 'invoice', enumWritabilityGates: ['prop1':['VAL1','VAL2'], '!prop2':['VAL3']]
|
enumReadabilityGates
|
Assigns a collection of gates to determine component readability. A component will be considered readable (updatable) if and only if all enum gates are open. entity 'invoice', enumReadabilityGates: ['prop1':['VAL1','VAL2'], '!prop2':['VAL3']]
|
regexWritabilityGates
|
Assigns a collection of gates to determine component writability. A component will be considered writable (updatable) if and only if all regex gates are open. entity 'invoice', regexWritabilityGates: ['prop1':'[A-Z]*', '!prop2':'[a-z]*']
|
regexReadabilityGates
|
Assigns a collection of gates to determine component readability. A component will be considered readable (updatable) if and only if all regex gates are open. entity 'invoice', regexReadabilityGates: ['prop1':'[A-Z]*', '!prop2':'[a-z]*']
|
serviceWritabilityGates
|
Assigns a collection of gates to determine component writability. A component will be considered writable (updatable) if and only if all service gates are open. entity 'invoice', serviceWritabilityGates: ['ensureValid']
|
serviceReadabilityGates
|
Assigns a collection of gates to determine component readability. A component will be considered readable (updatable) if and only if all service gates are open. entity 'invoice', serviceReadabilityGates: ['!checkError']
|
extension
|
Instructs the framework that a delegate class is attached to this component to implements getters for his computes properties. Properties defined with a computed = true are computed whith a setter defined in that delegate class. Delegate instances are stateful. This allows for some caching of computing intensive properties. Delegate instances are lazily created when needed, i.e. when the computed property is accessed either programmatically or by the binding layer. The delegate class must implement the IComponentExtension <T> interface (where <T> is assignable from the owning component class) and provide a public constructor taking exactly 1 parameter : the component instance. Jspresso provides an adapter class to inherit from : AbstractComponentExtension<T> . This helper class provides the methods to access the enclosing component from the delegate implementation as well as the Spring context it comes from, when needed. Entity('Employee', extension: 'EmployeeExtension'){ integer 'age', useExtension: true } |
processor
|
Class name in which all class processors associated with the properties of this component are grouped Entity('Employee', processor:'EmployeePropertyProcessors'){...} |
interceptors
|
List of lifecycle interceptor instances that will be triggered on the different phases of the component lifecycle : when the component is instanciated in memory or when the component is created, updated, loaded or deleted in the data store. Interface('Traceable', interceptors: 'TraceableLifecycleInterceptor'){...} |
interceptorBeans
|
This is the same as the interceptors list except that interceptor instances are declared using their identfiers. This allows to use externally configured instances instead of instances that are created at runtime using their default constructor. |
services
|
Much the same as serviceDelegateBeanNames except that instead of providing a map valued with Spring bean names, you provide a map valued with fully qualified class names. These class must :
|
serviceBeans
|
Registers the collection of service delegate instances attached to this component. These delegate instances will automatically be triggered whenever a method of the service interface it implements get executed.For instance :
|
parent
|
Parent property allows to used an other descriptor as a model to override certain properties. This ability directly resulting from Spring configuration is generally not used in the model |
toString
|
Allows to customize the string representation of a component instance. The property name assigned will be used when displaying the component instance as a string. It may be a computed property that composes several other properties in a human friendly format. Whenever this property is null, the following rule apply to determine the toString property :
|
toHtml
|
Allows to customize the HTML representation of a component instance. The property name assigned will be used when displaying the component instance as HTML. It may be a computed property that composes several other properties in a human friendly format. Whenever this property is null, the toStringProperty is used. Note that this property is not inherited by children descriptors, i.e. even if an ancestor defines an explicit toHtmlProperty property, its children ignore this setting. |
autoComplete
|
Allows to customize the property used to autocomplete reference fields on this component. Whenever this property is null, the following rule apply to determine the lovProperty :
|
purelyAbstract
|
This property is used to indicate that the entity type described is to be considered abstract. Jspresso will prevent any instanciation through its generic actions or internal mecanisms. Trying to do so will result in a low level exception and reveals a coding (assembling) error. However, an abstract entity will have a concrete representation in the data store that depends on the inheritance mapping strategy used . As of now, Jspresso uses the join-subclass inheritance mapping strategy when generating the Hibernate mapping so an abstract entity will end up as a table in the data store. Entity('OrganizationalUnit', purelyAbstract: true){...} Entity('Department', extend: 'OrganizationalUnit'){...} |
Interface
- extend :
Entity
- Inherited properties :
extend, description, icon, iconWidth, iconHeight, rendered, queryable, uncloned, ordering, pageSize, autoQuery, sqlName, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, extension, processor, interceptors, interceptorBeans, services, serviceBeans, parent, toString, toHtml, autoComplete, purelyAbstract
- allowed previous element :
Domain
- allowed next element :
string, text, imageUrl, password, integer, date, bool, decimal, time, duration, percent, enumeration, typeEnumeration, range, refId, color, binary, image, java, any, sourcecode, html, reference, list, set, paramSet
- Jspresso :
BasicInterfaceDescriptor
This descriptor is a mean of factorizing state/behaviour among components, entities or even sub-interfaces. This is a much less coupling mecanism than actual entity inheritance and can be used across entities that don't belong the the same inheritance hierarchy, or even accross types (entities, components, interfaces).
Interface('Nameable') { string_64 'name', mandatory: true } Interface('Traceable', interceptors: 'TraceableLifecycleInterceptor', uncloned: ['createTimestamp', 'lastUpdateTimestamp'], icon: 'traceable-48x48.png') { date_time 'createTimestamp', paramSets: 'readOnly', parent: 'City' date_time 'lastUpdateTimestamp', readOnly: true } Entity('Employee', extend: ['Nameable', 'Traceable']){ ... }
Property | Description |
---|---|
This class does not have any specific property. |
Component
- extend :
Entity
- Inherited properties :
extend, description, icon, iconWidth, iconHeight, rendered, queryable, uncloned, ordering, pageSize, autoQuery, sqlName, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, extension, processor, interceptors, interceptorBeans, services, serviceBeans, parent, toString, toHtml, autoComplete, purelyAbstract
- allowed previous element :
Domain
- allowed next element :
string, text, imageUrl, password, integer, date, bool, decimal, time, duration, percent, enumeration, typeEnumeration, range, refId, color, binary, image, java, any, sourcecode, html, reference, list, set, paramSet
- Jspresso :
BasicComponentDescriptor
structures that are to be reused but don't have enough focus for being considered as entities. For instance MoneyAmount component could be composed of a decimal and a reference to a Money entity. This structure could then be reused in other elements of the domain like an Invoice or an Article. Jspresso terminology for these type of structures is "Inlined Component". Another example could be reused of contact informations
Component('ContactInfo') { string_256 'address' reference 'city', ref: 'City' string_32 'phone' string_128 'email', regex: "*", regexSample: '[email protected]' } Entity('Employee') { ... reference 'contact', ref: 'ContactInfo' ... }
Property | Description |
---|---|
This class does not have any specific property. |
Common
common
This descriptor is an internal s SJS descriptor which is never used by the application.It s used by SJS to factorize commons properties.
Property | Description |
---|---|
description
|
Sets the description of this descriptor. Most of the descriptor descriptions are used in conjunction with the Jspresso i18n layer so that the description property set here is actually an i18n key used for translation. Description is mainly used for UI (in tooltips for instance) but may also be used for project technical documentation, contextual help, ... |
icon
|
Allows to define an icon to represent this property. |
iconWidth
|
Allows to define a custom width for the icon. In that case, the default dimension computed by the view factory is ignored. |
iconHeight
|
Allows to define a custom height for the icon. In that case, the default dimension computed by the view factory is ignored. |
i18nNameKey
|
Sets i18n key used for translation if it is different from the description |
mandatory
|
Declare a property as mandatory. This will enforce mandatory checks when the owning component is persisted as well as when the properties updated individually. Moreover, this information allows the views bound to the property to be configured accordingly, e.g. display the property with a slightly modified label indicating it is mandatory. This constraint is also enforced programmatically. |
readOnly
|
Enforces a property to be read-only. This is only enforced at the UI level, i.e. the property can still be updated programmatically. The UI may take decisions like changing textfields into labels if it knows the underlying property is read-only |
preferredWidth
|
This property allows for setting an indication of width for representing this property in a view. Default value is null, so that the view factory will make its decision based on the type and/or other characteristics of the property (e.g. max length). |
computed
|
Properties defined with a useExtension = true are computed with a getter. This getter is defined in the delegate class attached by the extension property to the Entity, Component or Interface. |
sqlName
|
Instructs Jspresso to use this name when translating this component type name to the data store namespace. This includes , but is not limited to, database table names. By default Jspresso uses its default naming policy |
parent
|
parent property allows to used an other descriptor as a model and to override certain properties. |
id
|
id created an identifier for the property. This identifier can then be referenced by other descriptors using refId |
grantedRoles
|
Assigns the roles that are authorized to manipulate the property backed by this descriptor. This will directly influence the UI behaviour and even composition (e.g. show/hide columns or fields). Setting the collection of granted roles to null (default value) disables role based authorization on this property level. Note that this authorization enforcement does not prevent programmatic access that is of the developer responsbility. |
booleanWritabilityGates
|
Assigns a collection of gates to determine component writability. A component will be considered writable (updatable) if and only if all booleanGates gates are open. entity 'invoice', booleanWritabilityGates: ['val1', '!val2']
|
booleanReadabilityGates
|
Assigns a collection of gates to determine component readability. A component will be considered readable (updatable) if and only if all booleanGates gates are open. entity 'invoice', booleanReadabilityGates: ['val1', '!val2']
|
rolesWritabilityGates
|
Assigns a collection of gates to determine component writability. A component will be considered writable (updatable) if and only if all RolesGates gates are open. entity 'invoice', rolesWritabilityGates: ['role1', '!role2']
|
rolesReadabilityGates
|
Assigns a collection of gates to determine component readability. A component will be considered readable (updatable) if and only if all RolesGates gates are open. entity 'invoice', rolesReadabilityGates: ['role1', '!role2']
|
enumWritabilityGates
|
Assigns a collection of gates to determine property writability. A property will be considered writable (updatable) if and only if all enum gates are open. entity 'invoice', enumWritabilityGates: ['prop1':['VAL1','VAL2'], '!prop2':['VAL3']]
|
enumReadabilityGates
|
Assigns a collection of gates to determine property readability. A property will be considered readable (updatable) if and only if all enum gates are open. entity 'invoice', enumReadabilityGates: ['prop1':['VAL1','VAL2'], '!prop2':['VAL3']]
|
regexWritabilityGates
|
Assigns a collection of gates to determine property writability. A property will be considered writable (updatable) if and only if all regex gates are open. entity 'invoice', regexWritabilityGates: ['prop1':'[A-Z]*', '!prop2':'[a-z]*']
|
regexReadabilityGates
|
Assigns a collection of gates to determine property readability. A property will be considered readable (updatable) if and only if all regex gates are open. entity 'invoice', regexReadabilityGates: ['prop1':'[A-Z]*', '!prop2':'[a-z]*']
|
serviceWritabilityGates
|
Assigns a collection of gates to determine property writability. A property will be considered writable (updatable) if and only if all service gates are open. entity 'invoice', serviceWritabilityGates: ['ensureValid']
|
serviceReadabilityGates
|
Assigns a collection of gates to determine property readability. A property will be considered readable (updatable) if and only if all service gates are open. entity 'invoice', serviceReadabilityGates: ['!checkError']
|
unicityScope
|
Makes this property part of a unicity scope. All tuples of properties belonging to the same unicity scope are enforced to be unique in the component type scope. This concretely translates to unique constraints in the datastore spanning the properties composing the unicity scope. Note that, for performance reasons, unicity scopes are only enforced by the persistence layer. |
delegateWritable
|
Instructs the framework that a delegate-computed property is writable. Most of the time, a computed property is read-only. Whenever a computed property is made writable through the use of delegateWritable=true, the delegate class must also provide a setter for the computed property. Defult value is false. |
processors
|
Registers a list of property processor instances that will be triggered on the different phases of the property modification, i.e. :
|
initializationMapping
|
This property allows to pre-initialize UI filters that are based on this reference property. This includes :
|
paramSets
|
paramSets makes it possible to use a list of paramSet. The properties declared in the paramSet come to be added to the properties of the current descriptor. The properties brought by the paramSet can be overridden by the current descriptor. If a property is overridden with the null value the property is ignored. |
versionControl
|
This property allows to fine tune wether this component property participates in optimistic versioning. It mainly allows to declare some properties that should be ignored regarding optimistic versioning thus lowering the risk of version conflicts between concurrent users. Of course, this feature has to be used with care since it may generate phantom updates to the data store. Default value is true so that any change in the described property increases the owning component version. |
computedFurther
|
Forces a property to be considered as a computed property by the framework. A computed property will be completely ignored by the persistence layer and its management is left to the developer. Properties declared with computed = true are considered computed. However, there is sometimes a need to declare a property at some level (e.g. in an interface descriptor) and let lower level implementation decide how to handle this common property. In that case, you can declare this property computedFurther=true Default value is false |
sortable
|
Enforces a property sortability. This is only enforced at the UI level, i.e. the property can still be used for sorting programmatically. |
alternativeSortProperty
|
Allows to configure an alternative property used to sort this one. |
cacheable
|
Configures the fact that this property can be cached. This is only used for computed properties. Note that the cached value will be reset whenever a firePropertyChange regarding this property is detected to be fired. Default value is false in order to prevent un-desired side-effects if computed property change notification is not correctly wired. |
filterComparable
|
Configures the fact that this property uses a comparator when installed n a filter view. By default, number, date, time, and duration properties behave this way. |
filterOnly
|
Gets whether this property is only used in filters, i.e. it is not persistent and only serves for storing criteria data that can be further leveraged by criteria refiners. Using {@code filterOnly} properties relieves the developer from having to declare fake computed properties. |
class
|
Allows to override the default framework descriptor class for advanced usage. |
BasicType
string
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicStringPropertyDescriptor
Field Declaration of type String. To be used with _n where the value n determine the maximum string length
string_32 'name' string_10 'zipCode'
Property | Description |
---|---|
maxLength
|
Configures the maximum string. Not needed with SJS which uses string_n |
regex
|
regex pattern (regular expression) to be applied to validate the string string_128 'email', regex: "[\w\-\.]*@[\w\-\.]", regexSample: '[email protected]' |
regexSample
|
Sample of a valid value for the regex pattern (see regex) |
upperCase
|
This is a shortcut to implement the common use-case of handling upper-case only properties. all incoming values will be transformed to uppercase as if a property processor was registered to perform the transformation. |
translatable
|
Configures the string property to be translatable. Jspresso will then implement a translation store for the property so that it can be displayed in the connected user language. This is particularly useful for non-european character sets like chinese, indian, and so on. In that case, only the raw, untranslated property value is stored in the object itself. the various translationsare stored in an extra store. translated properties support searching, ordering,... exactly like non-translatable properties. |
truncate
|
Configures whether the underlying string property should be truncated automatically if too long. Default value is false. |
defaultValue
|
Sets the default value for the field |
text
- extend :
string
- Inherited properties :
maxLength, regex, regexSample, upperCase, translatable, truncate, defaultValue, description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicTextPropertyDescriptor
Field declaration of type text. To be used with _n where the value n determine the maximum text length
Property | Description |
---|---|
fileFilter
|
This property allows to configure the file filter that has to be displayed whenever a file system operation is initiated from the UI to operate on this property. This includes :
|
fileName
|
Configures the default file name to use when downloading the property content as a file. |
contentType
|
Configures the default content type to use when downloading the property content as a file. |
queryMultiline
|
This property allows to control if the text property view should be transformed into a multi-line text view in order to allow for multi-line text in filters. Default value is false. |
imageUrl
- extend :
string
- Inherited properties :
maxLength, regex, regexSample, upperCase, translatable, truncate, defaultValue, description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicImageUrlPropertyDescriptor
Describes a property used for image URL values. This instructs Jspresso to display the property value as an image instead of raw text content.
Property | Description |
---|---|
scaledWidth
|
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. |
scaledHeight
|
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. |
keepRatio
|
Whenever keepRatio is explicitely set to false, the image, if not scrollable, will resize according to its container without respectig its height / width ratio. |
password
- extend :
string
- Inherited properties :
maxLength, regex, regexSample, upperCase, translatable, truncate, defaultValue, description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicPasswordPropertyDescriptor
Describes a property used for password values. For obvious security reasons, this type of properties will hardly be part of a persistent entity. However it is useful for defining transient view models, e.g. for implementing a change password action. Jspresso will automatically adapt view fields accordingly, using password fields, to interact with password properties.
Property | Description |
---|---|
This class does not have any specific property. |
integer
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicIntegerPropertyDescriptor
Describes an integer property. The property is either represented as an Integer or a Long depending on the property value.
Property | Description |
---|---|
minValue
|
Configures the upper bound of the allowed values. Default value is null, meaning unbound |
maxValue
|
Configures the lower bound of the allowed values. Default value is null, meaning unbound |
usingLong
|
Configures the property to be managed using java.lang.Long. Default value is false which means java.lang.Integer will be used. |
thousandsGrouping
|
A boolean value indicating if the number should be formatted with thousands grouped |
defaultValue
|
Sets the default value for the field |
format
|
Configures a specific pattern to display this date |
date
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicDatePropertyDescriptor
Describes a date based property. Wether the date property should include time information or not, can be configured using date or date_time declaration
Property | Description |
---|---|
type
|
Configures if date property should include time information or not. Not needed with SJS which uses date or date_time |
timeZoneAware
|
Sets wether this date property should have its string representation vary depending on the client timezone. Default value is false, meaning that the date is considered as a string. It is in fact expressed in the server timezone. |
secondsAware
|
Sets whether this date should include seconds information when configured as date_time. |
millisecondsAware
|
Sets whether this date should include milliseconds information when configured as date_time. |
format
|
Configures a specific pattern to display this date |
defaultValue
|
Sets the default value for the field |
bool
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicBooleanPropertyDescriptor
Describes a boolean property
Property | Description |
---|---|
defaultValue
|
Sets the default value for the field |
decimal
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicDecimalPropertyDescriptor
Describes a decimal property. Property value is either stored as a Double or as a BigDecimal depending on the usingBigDecimal property
Property | Description |
---|---|
minValue
|
Configures the upper bound of the allowed values. Default value is null, meaning unbound |
maxValue
|
Configures the lower bound of the allowed values. Default value is null, meaning unbound |
usingBigDecimal
|
Configures the property to be managed usin java.math.BigDecimal. Default value is false which means java.lang.Double will be used. |
maxFractionDigit
|
Configures the precision of the decimal property. Default value is null which means unlimited. |
thousandsGrouping
|
A boolean value indicating if the number should be formatted with thousands grouped |
defaultValue
|
Sets the default value for the field |
format
|
Configures a specific pattern to display this decimal |
time
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicTimePropertyDescriptor
Describes a property used to hold time only values. These properties use a Date to store their value but only the time part of the value is relevant
Property | Description |
---|---|
secondsAware
|
Sets whether this time should include seconds information. |
millisecondsAware
|
Sets whether this time should include milliseconds information. |
format
|
Configures a specific pattern to display this time |
defaultValue
|
Sets the default value for the field |
duration
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicDurationPropertyDescriptor
Describes a property used to store a duration value. Duration is stored in the form of a number of milliseconds. duration properties are cleanly handled by Jspresso UI layer for both displaying / editing duration properties in a convenient human format.
Property | Description |
---|---|
secondsAware
|
Sets whether this duration should include seconds information. |
millisecondsAware
|
Sets whether this duration should include milliseconds information. |
maxMillis
|
Configures the maximum duration value this property accepts in milliseconds. Default value is null, meaning unbound. |
defaultValue
|
Sets the default value for the field |
percent
- extend :
decimal
- Inherited properties :
minValue, maxValue, usingBigDecimal, maxFractionDigit, thousandsGrouping, defaultValue, format, description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicPercentPropertyDescriptor
This is a specialization of decimal descriptor to handle percentage values. The impact of using this descriptor is only on the UI level that will be configured accordingly, i.e. displaying/editing properties as percentage instead of their raw decimal values.
Property | Description |
---|---|
This class does not have any specific property. |
enumeration
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicEnumerationPropertyDescriptor
descriptor for properties whose values are enumerated strings. An example of such a property is gender whose value can be M (for "Male") or F (for "Female"). Actual property values can be codes that are translated for inclusion in the UI. Such properties are usually rendered as combo-boxes.
Property | Description |
---|---|
enumName
|
This property allows to customize the i18n keys used to translate the enumeration values, thus keeping the actual values shorter. For instance consider the gender enumeration, composed of the M (for "Male") and F (for "Female") values. Setting an enumeration name to "GENDER" will instruct Jspresso to look for translations named "GENDER_M" and "GENDER_F". This would allow for using M and F in other enumeration domains with different semantics and translations. |
maxLength
|
Sets the max size of the values. |
valuesAndIcons
|
Defines the list of values as well as an icon image URL per value this enumeration contains. The incoming Map is keyed by the actual enumeration values and valued by the icon image URLs. Enumeration values are translated in the UI using the following scheme : [enumerationName]_[value]. |
values
|
Defines the list of values this enumeration contains. Enumeration values are translated in the UI using the following scheme : [enumerationName]_[value]. |
defaultValue
|
Sets the property default value. When a component owning this property is instanciated, its properties are initialized using their default values. By default, a property default value is null. This incoming value can be either the actual property default value (as an Object) or its string representation whose parsing will be delegated to the property descriptor. |
queryMultiselect
|
This property allows to control if the enumeration property view should be transformed into a multi-selectable property view in order to allow for value disjunctions in filters. Default value is false. |
typeEnumeration
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
TypeEnumerationPropertyDescriptor
This is a special enumeration descriptor that allows to build the enumeration out of a list of component descriptors. Enumeration values and icons are the names and icons of the registered component descriptors. For instance, this can be useful in the UI if you want to visually indicate the actual type of a element contained in a polymorphic collection
Property | Description |
---|---|
enumName
|
This property allows to customize the i18n keys used to translate the enumeration values, thus keeping the actual values shorter. For instance consider the gender enumeration, composed of the M (for "Male") and F (for "Female") values. Setting an enumeration name to "GENDER" will instruct Jspresso to look for translations named "GENDER_M" and "GENDER_F". This would allow for using M and F in other enumeration domains with different semantics and translations. |
maxLength
|
Sets the max size of the values. |
components
|
Registers the list of component descriptors to build the enumeration values/icons from their names and icons. |
queryMultiselect
|
This property allows to control if the enumeration property view should be transformed into a multi-selectable property view in order to allow for value disjunctions in filters. Default value is false. |
range
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
RangeEnumerationPropertyDescriptor
This is a special enumeration descriptor that allows to build the enumeration values out of a list of integer values. Obviously, no icon is provided for a given value
Property | Description |
---|---|
rangeName
|
This property allows to customize the i18n keys used to translate the enumeration values, thus keeping the actual values shorter. For instance consider the gender enumeration, composed of the M (for "Male") and F (for "Female") values. Setting an enumeration name to "GENDER" will instruct Jspresso to look for translations named "GENDER_M" and "GENDER_F". This would allow for using M and F in other enumeration domains with different semantics and translations. |
minValue
|
The enumeration minimum bound. Default value is 0. |
maxValue
|
The enumeration maximum bound. Default value is 10. |
rangeStep
|
The step to use for constructing the enumeration values, starting from minValue up to maxValue. Default value is 1. |
queryMultiselect
|
This property allows to control if the enumeration property view should be transformed into a multi-selectable property view in order to allow for value disjunctions in filters. Default value is false. |
refId
- mandatory :
id
- allowed previous element :
Entity, Interface, Component
allows to point on a reference
Property | Description |
---|---|
id
|
Qualifies the type of element this property refers to. |
color
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicColorPropertyDescriptor
Describes a property used for storing a color. Color values are stored in the property as their string hexadecimal representation (0xrgba encoded). Jspresso cleanly handles color properties in views for both visually displaying and editing them without any extra effort. Moreover the ColorHelper helper class eases colors manipulation and helps converting to/from their hexadecimal representation.
Property | Description |
---|---|
defaultValue
|
Sets the default value for the field |
binary
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicBinaryPropertyDescriptor
Describes a property used to store a binary value in the form of a byte array
Property | Description |
---|---|
maxLength
|
Sets the max size of the byte array. |
fileFilter
|
This property allows to configure the file filter that has to be displayed whenever a file system operation is initiated from the UI to operate on this property. This includes :
|
fileName
|
Configures the default file name to use when downloading the property content as a file. |
contentType
|
Configures the default content type to use when downloading the property content as a file. |
image
- extend :
binary
- Inherited properties :
maxLength, fileFilter, fileName, contentType, description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicImageBinaryPropertyDescriptor
Describes a property used for image binary values. This instructs Jspresso to display the property value as an image instead of raw binary content.
Property | Description |
---|---|
scaledWidth
|
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. |
scaledHeight
|
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. |
keepRatio
|
Whenever keepRatio is explicitely set to false, the image, if not scrollable, will resize according to its container without respectig its height / width ratio. |
formatName
|
Sets format name. When set to something not null (e.g. PNG, JPG, ...), the image is transformed to the specified format before being stored. |
java
- extend :
binary
- Inherited properties :
fileFilter, fileName, contentType, description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicJavaSerializablePropertyDescriptor
Describes a property used to store any java Serializable object. The property value is serialized/deserialized to/from the datastore. The operation is completely transparent to the developer, i.e. the developer never plays with the serialized form.
Property | Description |
---|---|
class
|
Configures the actual serializable property type through its fully qualified name. |
maxLength
|
Sets the max size of the object in Byte. |
any
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicObjectPropertyDescriptor
This descriptore is used to describe an arbitrary object property for which the type can be explicitely declared.
Property | Description |
---|---|
class
|
Configures the actual property type through its fully qualified name. |
sourcecode
- extend :
text
- Inherited properties :
fileFilter, fileName, contentType, queryMultiline, maxLength, regex, regexSample, upperCase, translatable, truncate, defaultValue, description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicSourceCodePropertyDescriptor
Describes a property as handing sourcecode content. This instructs Jspresso to display the property value as sourcecode, using syntax coloring for instance, instead of displaying unformatted raw content. The language used to format the property text content may be defined explicitely using the language property.
Property | Description |
---|---|
language
|
Explicitely sets the language this sourcecode property should contain. This is only a hint fo Jspresso to configure the UI components accordingly to interact with this property. |
html
- extend :
text
- Inherited properties :
fileFilter, fileName, contentType, queryMultiline, maxLength, regex, regexSample, upperCase, translatable, truncate, defaultValue, description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicHtmlPropertyDescriptor
Describes a property as handing HTML content. This instructs Jspresso to display the property value as HTML instead of raw text content.
Property | Description |
---|---|
This class does not have any specific property. |
Association
reference
- extend :
common
- Inherited properties :
description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- mandatory :
ref
- allowed previous element :
Entity, Interface, Component
- Jspresso :
BasicReferencePropertyDescriptor
This descriptor is used to describe a reference to an other component (entities, interfaces or components)
Property | Description |
---|---|
ref
|
Qualifies the type of element this property refers to. It may point to any type of component descriptor, i.e. entity, interface or component descriptor. |
reverse
|
Allows to make a relationship bi-directional. By default, when a relationdhip end is defined, it is only navigable from the owning component to the described end (default value is null). Assigning a reverse relationship ends instructs the framework that the relationship is bi-derectional. This implies several complementary features :
|
composition
|
Instructs the framework that this property has to be treated as a composition, in the UML terminology. This implies that reachable entities that are referenced by this property follow the owning entity lifecycle. For instance, when the owning entity is deleted, the referenced entities in composition properties are also deleted. Whenever this property is not explicitely set by the developer, Jspresso uses sensible defaults :
|
fetch
|
By default Jspresso apply a lazy loading stategy, by setting fetch=true Jspresso will ask hibernate to load the child entity when parent is loaded. This option has to be used carfully, if you define too many non-lazy associations in your object model, Hibernate will fetch the entire database into memory in every transaction. |
batch
|
This property allows to finely tune batching strategy of the ORM on this relationship end. Whenever possible, the ORM will use a IN clause in order to fetch multiple instances relationships at once. The batch size determines the size of th IN clause. |
fkName
|
Allows to customize the geneated foreign key (if any) name. |
rendered
|
This property allows to define which of the component properties are to be rendered by default when displaying a list of value on this component family. For instance, a table will render 1 column per rendered property of the component. Any type of property can be used except collection properties. Since this is a List queriable properties are rendered in the same order. Whenever this property is null (default value) Jspresso determines the default set of properties to render based on the referenced component descriptor. |
queryable
|
This property allows to define which of the component properties are to be used in the list of value filter that are based on this component family. Since this is a List queriable properties are rendered in the same order. Whenever this this property is null (default value), Jspresso chooses the default set of queryable properties based on the referenced component descriptor. |
list
- extend :
reference
- Inherited properties :
ref, reverse, composition, fkName, rendered, queryable, description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- mandatory :
ref
- allowed previous element :
Entity, Interface, Component
This descriptor is used to describe a collection of components (entities, interfaces or components). A list allows for duplicates and preserves the order of the elements in the datastore through an implicit index column.
Property | Description |
---|---|
ordering
|
Ordering properties are used to sort this collection property if and only if it is un-indexed (not a List). The sort order set on the collection property can refine the default one that might have been set on the referenced collection level. This property consist of a Map whose entries are composed with :
|
manyToMany
|
Forces the collection property to be considered as a many to many (N-N) end. When a relationship is bi-directional, setting both ends as being collection properties turns manyToMany=true automatically. But when the relationship is not bi-directional, Jspresso has no mean to determine if the collection property is 1-N or N-N. Setting this property allows to inform Jspresso about it. Default value is false. |
fetch
|
By default Jspresso apply a lazy loading stategy, by setting fetch=true Jspresso will ask hibernate to load the child entity when parent is loaded. This option has to be used carfully, if you define too many non-lazy associations in your object model, Hibernate will fetch the entire database into memory in every transaction. |
batch
|
This property allows to finely tune batching strategy of the ORM on this relationship end. Whenever possible, the ORM will use a IN clause in order to fetch multiple instances relationships at once. The batch size determines the size of th IN clause. |
nullElement
|
This property allows to declare if the collection property allows for null element, i.e. holes in lists. |
set
- extend :
list
- Inherited properties :
ordering, manyToMany, fetch, batch, nullElement, ref, reverse, composition, fkName, rendered, queryable, description, icon, iconWidth, iconHeight, i18nNameKey, mandatory, readOnly, preferredWidth, computed, sqlName, parent, id, grantedRoles, booleanWritabilityGates, booleanReadabilityGates, rolesWritabilityGates, rolesReadabilityGates, enumWritabilityGates, enumReadabilityGates, regexWritabilityGates, regexReadabilityGates, serviceWritabilityGates, serviceReadabilityGates, unicityScope, delegateWritable, processors, initializationMapping, paramSets, versionControl, computedFurther, sortable, alternativeSortProperty, cacheable, filterComparable, filterOnly, class
- mandatory :
ref
- allowed previous element :
Entity, Interface, Component
This descriptor is used to describe a collection of components (entities, interfaces or components).. A set do not allow for duplicates and do not preserve the order of the elements in the datastore.
Property | Description |
---|---|
This class does not have any specific property. |
Support
external
- allowed previous element :
Domain
This descriptor allowed declaring references which are not described in the SJS description of the application. since all references are controlled by SJS, it is necessary to declare the external references.
Property | Description |
---|---|
id
|
list identifiers of descriptors external(id: ['com.appli.model.content.aCatalog', 'com.appli.model.content.aMenu']) |
paramSet
- allowed previous element :
Domain, Entity, Interface, Component
paramSet allows to create a reusable groups of properties in SJS declarations.
paramSet 'myCommon', readOnly:true, mandatory:true
paramSet can be used by declaration SJS using the attribute paramSets
Property | Description |
---|---|
This class does not have any specific property. |
namespace
- allowed previous element :
Domain, Entity, Interface, Component
namespace allows to declare and open a namespace scope. The use of namespaces allows simplifying the declarations SJS referring to resources with a complex path.
namespace('org.jspresso.hrsample'){...}
This declaration allows, for example, to replace the following statement
Entity('City', icon: 'classpath:org/jspresso/hrsample/images/city-48x48.png'){...}
by
('City',icon:'city-48x48.png') {...}
With namespaces, conventions on the organization of the Jspresso's directories are used. In this exemple, images are in the subdirectory /images of the project
Property | Description |
---|---|
This class does not have any specific property. |
include
- allowed previous element :
Domain, Entity, Interface, Component
include allows to use multi SJS sources files and to include them into each other.
include('fileName')
Property | Description |
---|---|
This class does not have any specific property. |