Type to start searching...

PersistenceMapping

A class’ persistence mapping specifies how its instances will be persisted in a given datasource.

Description
A class has a persistence mapping if it is to be persisted by the object system. The datasource where the class will be persisted is set in the DataSource property on the persistence mapping. The type of the selected datasource will dictate what sort of mapping is presented to the developer in NexJ Studio.
Properties
caching

Caching mode: instance - individual instances are cached, class - all instances are cached.

Instance mode - Queries that are guaranteed to return <= 1 instance are cached if they return 1 instance. A change to a given instance invalidates the cache for that particular instance.

Class mode - All instances of the class are pre-read and cached. Queries are evaluated against this cache. If the query is an instance query (see above) and the cached instance count is > 64, then instance caching is used as well and the query is evaluated against the persistence store on cache miss. A change to an instance of the class or subclass invalidates the whole cache for the class.

Heterogeneous joins (which are used for joining cached instances to a query) work with both types of caching. Caching is turned off for query subtrees that would require heterogeneous joins in the where clause if caching were used.

Valid values based on“string”.
instance
class
classCodeAttribute : identifier

Attribute for determining an instance class.

The attribute value expression must be a unique constant within a given class hierarchy persisted in the same schema object.
Valid values based on“string”.
:?[\p{L}_][\p{L}\p{N}_]*(:[\p{L}_][\p{L}\p{N}_]*)*

Value must begin with a letter or an underscore. Case and length are not restricted. Letters, numbers and underscores are allowed. Colon is used as a scope separator. Spaces and other punctuation characters are not allowed.

classCodeForced : boolean

True to always apply the class code filter.

Use if the underlying schema object stores class codes that are not assigned in the domain model.
dataSource : string

Persistent datasource, in which the instances of this class are stored.

The type of the selected datasource will dictate what sort of mapping is presented to the developer in NexJ Studio.
fragmentAttribute : identifier

String attribute providing the fragment name for unicast replication from the default fragment.

Valid values based on“string”.
:?[\p{L}_][\p{L}\p{N}_]*(:[\p{L}_][\p{L}\p{N}_]*)*

Value must begin with a letter or an underscore. Case and length are not restricted. Letters, numbers and underscores are allowed. Colon is used as a scope separator. Spaces and other punctuation characters are not allowed.

fragmentReplication

Fragment replication model: unicast - default to/from designated, broadcast - default to all.

Valid values based on“string”.
unicast
broadcast
lockingAttribute : identifier

Attribute used for optimistic locking. It must be of integer or long type and have an initializer.

Valid values based on“string”.
:?[\p{L}_][\p{L}\p{N}_]*(:[\p{L}_][\p{L}\p{N}_]*)*

Value must begin with a letter or an underscore. Case and length are not restricted. Letters, numbers and underscores are allowed. Colon is used as a scope separator. Spaces and other punctuation characters are not allowed.

Content
Parents
  • Class - A Class is an abstraction of a business model concept.