Oracle TopLink API Reference
10g Release 3 (10.1.3)

B13698-01

oracle.toplink.descriptors
Class RelationalDescriptor

java.lang.Object
  extended byoracle.toplink.publicinterface.Descriptor
      extended byoracle.toplink.internal.descriptors.RootDescriptor
          extended byoracle.toplink.descriptors.ClassDescriptor
              extended byoracle.toplink.descriptors.RelationalDescriptor
All Implemented Interfaces:
java.lang.Cloneable, java.io.Serializable
Direct Known Subclasses:
ObjectRelationalDescriptor

public class RelationalDescriptor
extends ClassDescriptor

Purpose: TopLink has been designed to take advantage of the similarities between relational databases and objects while accommodating for their differences, providing an object oriented wrapper for relational databases. This is accomplished through the use of Descriptors. A descriptor is a pure specification class with all its behaviour deputized to DescriptorEventManager, DescriptorQueryManager and ObjectBuilder. Look at the following variables for the list of specification on the descriptor.

A Descriptor is a set of mappings that describe how an objects's data is to be represented in a relational database. It contains mappings from the class instance variables to the table's fields, as well as the transformation routines necessary for storing and retrieving attributes. As such the descriptor acts as the link between the Java object and its database representaiton.

Every descripor is initialized with the following information:

This descriptor subclass should be used for object-relational mapping, and allows for other datatype mappings to be done in the XML, EIS and OR sibling classes.

See Also:
DescriptorEventManager, DescriptorQueryManager, InheritancePolicy, InterfacePolicy, Serialized Form

Field Summary
 
Fields inherited from class oracle.toplink.publicinterface.Descriptor
DO_NOT_SEND_CHANGES, INVALIDATE_CHANGED_OBJECTS, SEND_NEW_OBJECTS_WITH_CHANGES, SEND_OBJECT_CHANGES, UNDEFINED_OBJECT_CHANGE_BEHAVIOR
 
Constructor Summary
RelationalDescriptor()
          PUBLIC: Return a new descriptor.
 
Method Summary
 void addTableName(java.lang.String tableName)
          PUBLIC: Specify the table name for the class of objects the receiver describes.
 java.lang.String getTableName()
          PUBLIC: Return the name of the descriptor's first table.
 java.util.Vector getTableNames()
          PUBLIC: Return the table names.
 void setDefaultTableName(java.lang.String defaultTableName)
          PUBLIC: The descriptors default table can be configured if the first table is not desired.
 void setTableName(java.lang.String tableName)
          PUBLIC: Specify the table name for the class of objects the receiver describes.
 void setTableNames(java.util.Vector tableNames)
          PUBLIC: Specify the all table names for the class of objects the receiver describes.
 void setTableQualifier(java.lang.String tableQualifier)
          PUBLIC: Set the table Qualifier for this descriptor.
 
Methods inherited from class oracle.toplink.descriptors.ClassDescriptor
addAbstractQueryKey, addConstraintDependencies, addDirectMapping, addDirectMapping, addDirectQueryKey, addMapping, addMultipleTableForeignKeyFieldName, addMultipleTablePrimaryKeyFieldName, addPrimaryKeyField, addPrimaryKeyFieldName, addQueryKey, alwaysConformResultsInUnitOfWork, alwaysRefreshCache, alwaysRefreshCacheOnRemote, applyAmendmentMethod, createCopyPolicy, createInstantiationPolicy, descriptorIsAggregate, descriptorIsAggregateCollection, descriptorIsForInterface, descriptorIsNormal, disableCacheHits, disableCacheHitsOnRemote, dontAlwaysConformResultsInUnitOfWork, dontAlwaysRefreshCache, dontAlwaysRefreshCacheOnRemote, dontDisableCacheHits, dontDisableCacheHitsOnRemote, dontOnlyRefreshCacheIfNewerVersion, getAlias, getAmendmentClass, getAmendmentMethodName, getCacheInvalidationPolicy, getCacheSynchronizationType, getCMPPolicy, getConstraintDependencies, getDescriptorEventManager, getDescriptorInheritancePolicy, getDescriptorQueryManager, getDescriptorType, getFetchGroupManager, getHistoryPolicy, getIdentityMapSize, getInterfacePolicy, getJavaClass, getMappingForAttributeName, getMappings, getObjectChangePolicy, getOptimisticLockingPolicy, getPrimaryKeyFieldNames, getProperties, getProperty, getQueryKeys, getRemoteIdentityMapSize, getReturningPolicy, getSequenceNumberFieldName, getSequenceNumberName, getWrapperPolicy, isAggregateCollectionDescriptor, isAggregateDescriptor, isChildDescriptor, isDescriptorForInterface, isIsolated, onlyRefreshCacheIfNewerVersion, removeProperty, setAlias, setAmendmentClass, setAmendmentMethodName, setCacheInvalidationPolicy, setCacheSynchronizationType, setCMPPolicy, setDescriptorType, setFetchGroupManager, setHistoryPolicy, setIdentityMapClass, setIdentityMapSize, setIsIsolated, setJavaClass, setJavaInterface, setObjectChangePolicy, setOptimisticLockingPolicy, setPrimaryKeyFieldName, setPrimaryKeyFieldNames, setProperty, setReadOnly, setRemoteIdentityMapClass, setRemoteIdentityMapSize, setReturningPolicy, setSequenceNumberFieldName, setSequenceNumberName, setShouldAlwaysConformResultsInUnitOfWork, setShouldAlwaysRefreshCache, setShouldAlwaysRefreshCacheOnRemote, setShouldBeReadOnly, setShouldDisableCacheHits, setShouldDisableCacheHitsOnRemote, setShouldOnlyRefreshCacheIfNewerVersion, setShouldOrderMappings, setWrapperPolicy, shouldAlwaysConformResultsInUnitOfWork, shouldAlwaysRefreshCache, shouldAlwaysRefreshCacheOnRemote, shouldBeReadOnly, shouldDisableCacheHits, shouldDisableCacheHitsOnRemote, shouldOnlyRefreshCacheIfNewerVersion, shouldUseCacheIdentityMap, shouldUseFullIdentityMap, shouldUseHardCacheWeakIdentityMap, shouldUseNoIdentityMap, shouldUseRemoteCacheIdentityMap, shouldUseRemoteFullIdentityMap, shouldUseRemoteHardCacheWeakIdentityMap, shouldUseRemoteNoIdentityMap, shouldUseRemoteSoftCacheWeakIdentityMap, shouldUseRemoteWeakIdentityMap, shouldUseSoftCacheWeakIdentityMap, shouldUseWeakIdentityMap, useAllFieldsLocking, useCacheIdentityMap, useChangedFieldsLocking, useCloneCopyPolicy, useCloneCopyPolicy, useDefaultConstructorInstantiationPolicy, useFactoryInstantiationPolicy, useFactoryInstantiationPolicy, useFactoryInstantiationPolicy, useFullIdentityMap, useHardCacheWeakIdentityMap, useInstantiationCopyPolicy, useMethodInstantiationPolicy, useNoIdentityMap, useRemoteCacheIdentityMap, useRemoteFullIdentityMap, useRemoteHardCacheWeakIdentityMap, useRemoteNoIdentityMap, useRemoteSoftCacheWeakIdentityMap, useRemoteWeakIdentityMap, useSelectedFieldsLocking, useSoftCacheWeakIdentityMap, usesOptimisticLocking, usesSequenceNumbers, useTimestampLocking, useTimestampLocking, useVersionLocking, useVersionLocking, useWeakIdentityMap
 
Methods inherited from class oracle.toplink.publicinterface.Descriptor
getEventManager, getInheritancePolicy, getJavaClassName, getQueryManager, removeMappingForAttributeName, setConstraintDependencies, setMultipleTableInsertOrder, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RelationalDescriptor

public RelationalDescriptor()
PUBLIC: Return a new descriptor.

Method Detail

addTableName

public void addTableName(java.lang.String tableName)
PUBLIC: Specify the table name for the class of objects the receiver describes. If the table has a qualifier it should be specified using the dot notation, (i.e. "userid.employee"). This method is used if there is more than one table.

Overrides:
addTableName in class Descriptor

getTableName

public java.lang.String getTableName()
PUBLIC: Return the name of the descriptor's first table. This method must only be called on single table descriptors.

Overrides:
getTableName in class Descriptor

getTableNames

public java.util.Vector getTableNames()
PUBLIC: Return the table names.

Overrides:
getTableNames in class Descriptor

setDefaultTableName

public void setDefaultTableName(java.lang.String defaultTableName)
PUBLIC: The descriptors default table can be configured if the first table is not desired.

Overrides:
setDefaultTableName in class Descriptor

setTableName

public void setTableName(java.lang.String tableName)
                  throws DescriptorException
PUBLIC: Specify the table name for the class of objects the receiver describes. If the table has a qualifier it should be specified using the dot notation, (i.e. "userid.employee"). This method is used for single table.

Overrides:
setTableName in class Descriptor
Throws:
DescriptorException

setTableNames

public void setTableNames(java.util.Vector tableNames)
PUBLIC: Specify the all table names for the class of objects the receiver describes. If the table has a qualifier it should be specified using the dot notation, (i.e. "userid.employee"). This method is used for multiple tables

Overrides:
setTableNames in class Descriptor

setTableQualifier

public void setTableQualifier(java.lang.String tableQualifier)
PUBLIC: Set the table Qualifier for this descriptor. This table creator will be used for all tables in this descriptor

Overrides:
setTableQualifier in class Descriptor

Copyright © 1998, 2006, Oracle. All Rights Reserved.