| java.lang.Object org.apache.derby.impl.sql.catalog.TDCacheable
All known Subclasses: org.apache.derby.impl.sql.catalog.NameTDCacheable, org.apache.derby.impl.sql.catalog.OIDTDCacheable,
TDCacheable | abstract class TDCacheable implements Cacheable(Code) | | This class implements a Cacheable for a DataDictionary cache of
table descriptors. It is an abstract class - there is more than
one cache of table descriptors per data dictionary, and this class
provides the implementation that's common to all of them. The lookup
key for the cache (the "identity" of the cache item) is provided by
the subclass.
Another design alternative was to make the table descriptors themselves
the cacheable objects. This was rejected because: we would have only
one way of caching table descriptors, and we need at least two (by UUID
and by name); the contents of a table descriptor would have to be
split out into a separate class, so it could be used as the createParameter
to the createIdentity() method; the releasing of the Cacheable would
have to be done when at the end of compilation by traversing the tree -
by creating a separate Cacheable object, we can release the object within
the getTableDescriptor() method after getting the table descriptor out
of it.
|
checkConsistency | protected boolean checkConsistency(TableDescriptor uncachedTD, Object identity, HeaderPrintWriter reportInconsistent) throws StandardException(Code) | | Check the consistency of the table descriptor held by this TDCacheable
versus an uncached table descriptor.
Parameters: uncachedTD - The uncached descriptor to compare to Parameters: identity - The identity of the table descriptor Parameters: reportInconsistent - A HeaderPrintWriter to send complaints to true if the descriptors are the same, false if they're different exception: StandardException - Thrown on error |
getTableDescriptor | public TableDescriptor getTableDescriptor()(Code) | | Get the table descriptor that is associated with this Cacheable
|
|
|