Specifying Read Only Settings

Use the Read Only check-box on the mapping's General tab (see Figure 5-2) to set a mapping to be read only. TopLink will not consider attributes associated with read-only mappings during update and delete operations.

Because these operations are not actually performed for the mapping, any processes dependent on these operations (such as custom SQL or descriptor events) are not called for read-only. The attributes are still used for read operations.


Note: The primary key mappings must not be read-only.

Mappings defined for the write-lock or class indicator field must be read-only, unless the write-lock is configured not to be stored in the cache and the class indicator is part of the primary key.


Related Topics

About TopLink Descriptors

About TopLink Mapping Types
Working with Common Mapping Properties
Specifying Direct Access and Method Access
Defaulting Null Values
Maintaining Bidirectional Relationships
Specifying Field Names and Multiple Tables
Specifying Collection Properties
Specifying Mapping Information in ejb-jar.xml File
Working with Descriptors

 

Copyright © 1997, 2004, Oracle. All rights reserved.