There are several motivations for data encapsulation.
- You want to make it clear to others what data an application manages.
- You want to use the same encapsulation patterns of object-oriented systems.
- You want to be able to prevent other applications from changing your data.
- You want to use consistent role-based access control for your applications data.
- You want to make it easy for all applications to share data management code for tasks such as ID assignment, versioning and linking.
Each XRX application stores all its user-managed data in a sub-collection of the application called data. For example if your application manages business terms the collection path to the terms might be:
Each XRX application stores its own data. When this application's main collection is removed, all the data that it manages is also automatically removed by the simple nature of the collection structure.