Skip Headers

# Descriptor Architecture

Previous

Next

A descriptor stores all the information describing how an instance of a particular object class can be represented in a data source.

TopLink descriptors contain the following information:

- The persistent Java class it describes and the corresponding data source (database tables, XML complex type, or EIS interaction)

- A collection of mappings, which describe how the attributes and relationships for that class are stored in the database

- The primary key information (or equivalent) of the data source

- A list of query keys (or aliases) for field names

- Information for sequence numbers

- A set of optional properties for tailoring the behavior of the descriptor, including support for caching refresh options, identity maps, optimistic locking, the event manager, and the query manager

There is a descriptor type for each data source type that TopLink supports. In some cases, multiple descriptor types are valid for the same data source type. The type of descriptor you use determines the type of mappings that you can define.

Table: Project, Descriptor, and Mapping Support summarizes the relationship between project, descriptor, and mappings.

Project, Descriptor, and Mapping Support

Project | Descriptor | Mapping
--- | --- | ---
Relational Projects | Relational Descriptors Object-Relational Descriptors | Relational Mappings Object-Relational Mappings
EIS Projects | EIS Descriptors | EIS Mappings
XML Projects | XML Descriptors | XML Mappings