Class DDdependableFinder
- java.lang.Object
-
- org.apache.derby.impl.sql.catalog.DDdependableFinder
-
- All Implemented Interfaces:
java.io.Externalizable,java.io.Serializable,DependableFinder,Formatable,TypedFormat
- Direct Known Subclasses:
DDColumnDependableFinder
public class DDdependableFinder extends java.lang.Object implements DependableFinder, Formatable
Class for most DependableFinders in the core DataDictionary. This class is stored in SYSDEPENDS for the finders for the provider and dependent. It stores no state, its functionality is driven off its format identifier.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private intformatId
-
Constructor Summary
Constructors Constructor Description DDdependableFinder(int formatId)Public constructor for Formatable hoo-hah.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) DependablefindDependable(DataDictionary dd, UUID dependableObjectID)Find the dependable for getDependable.DependablegetDependable(DataDictionary dd, UUID dependableObjectID)Get the dependable for the given UUIDjava.lang.StringgetSQLObjectType()The name of the class of Dependables as a "SQL Object" which this Finder can find.intgetTypeFormatId()Get the formatID which corresponds to this class.voidreadExternal(java.io.ObjectInput in)Read this object from a stream of stored objects.java.lang.StringtoString()voidwriteExternal(java.io.ObjectOutput out)Write this object to a stream of stored objects.
-
-
-
Method Detail
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
readExternal
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundExceptionRead this object from a stream of stored objects. Nothing to do. Our persistent representation is just a 2-byte format id.- Specified by:
readExternalin interfacejava.io.Externalizable- Parameters:
in- read this.- Throws:
java.io.IOExceptionjava.lang.ClassNotFoundException
-
writeExternal
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOExceptionWrite this object to a stream of stored objects. Again, nothing to do. We just stamp the output stream with our Format id.- Specified by:
writeExternalin interfacejava.io.Externalizable- Parameters:
out- write bytes here.- Throws:
java.io.IOException
-
getTypeFormatId
public final int getTypeFormatId()
Get the formatID which corresponds to this class.- Specified by:
getTypeFormatIdin interfaceTypedFormat- Returns:
- the formatID of this class
-
getSQLObjectType
public java.lang.String getSQLObjectType()
Description copied from interface:DependableFinderThe name of the class of Dependables as a "SQL Object" which this Finder can find. This is a value like "Table" or "View". Every DependableFinder can find some class of Dependables.- Specified by:
getSQLObjectTypein interfaceDependableFinder- Returns:
- String type of the "SQL Object" which this Finder can find.
- See Also:
DependableFinder.getSQLObjectType()
-
getDependable
public final Dependable getDependable(DataDictionary dd, UUID dependableObjectID) throws StandardException
Get the dependable for the given UUID- Specified by:
getDependablein interfaceDependableFinder- Parameters:
dd- DataDictionary to use for lookup.dependableObjectID- the ID of a Dependable. Used to locate that Dependable.- Returns:
- the associated Dependable
- Throws:
StandardException- thrown on error
-
findDependable
Dependable findDependable(DataDictionary dd, UUID dependableObjectID) throws StandardException
Find the dependable for getDependable. Can return a null references, in which case getDependable() will thrown an exception.- Throws:
StandardException
-
-