|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.griphyn.vdl.dbschema.DatabaseSchema
org.griphyn.vdl.dbschema.AnnotationSchema
public class AnnotationSchema
This class provides basic functionalities to interact with the backend database, such as insertion, deletion, and search. While the main database layout for storing definitions is derived from the "chunk" schema with minor improvements, the database layout of the annotations is shown in the following figure:

The central five elements that can receive annotations, all depend on the same sequence generator for their primary key. Their secondary key references the definition in question, or otherwise qualifies the element to annotate. Note that logical filenames can be annotated outside of any definitions.
Grouped along the outer edges, five primary data type tables store annotations efficiently. The distinction into separate data types is necessary to enable efficient searches and appropriate operations. Their primary key is also a foreign key referencing the five central elements.
| Field Summary | |
|---|---|
protected static String[] |
c_lfn_names
Name of the four parameter tables in human readable format. |
protected Cache |
m_cache
A cache for definitions to avoid reloading from the database. |
protected boolean |
m_deferDeleteCommit
Communication between saveDefinition and deleteDefinition in update mode. |
private VDLxParser |
m_parser
An instance of the VDLx XML parser. |
| Fields inherited from class org.griphyn.vdl.dbschema.DatabaseSchema |
|---|
m_dbdriver, m_dbschemaprops |
| Fields inherited from interface org.griphyn.vdl.dbschema.VDC |
|---|
PROPERTY_PREFIX |
| Fields inherited from interface org.griphyn.vdl.dbschema.Annotation |
|---|
CLASS_CALL, CLASS_DECLARE, CLASS_DERIVATION, CLASS_FILENAME, CLASS_TRANSFORMATION |
| Constructor Summary | |
|---|---|
AnnotationSchema(String dbDriverName)
Default constructor for the "chunk" schema. |
|
| Method Summary | |
|---|---|
ResultSet |
backdoor(String query)
A too generic method to search annotation (and anything) in the database. |
boolean |
containsDefinition(Definition definition)
Search the database for the existence of a definition. |
boolean |
deleteAnnotation(String primary,
Object secondary,
int kind,
String key)
Deletes an annotation with the specified key. |
boolean |
deleteAnnotationCall(String fqdi,
int index,
String key)
Deletes a specific key for a call statement. |
boolean |
deleteAnnotationDeclare(String fqdi,
String farg,
String key)
Deletes a specific key in an annotated formal argument. |
boolean |
deleteAnnotationDerivation(String fqdi,
String key)
Deletes a specific key in an annotated derivation. |
boolean |
deleteAnnotationFilename(String filename,
String key)
Deletes a specific key in an annotated filename. |
private List |
deleteAnnotationFromDefinition(long id)
Deletes the joined annotations when a definition is being deleted. |
private boolean |
deleteAnnotationKey(long id,
int kind)
Deletes an annotation in a type table with the specified annotation id. |
boolean |
deleteAnnotationTransformation(String fqdi,
String key)
Deletes a specific key in an annotated transformation. |
private boolean |
deleteAnnotationValue(long id)
Deletes an annotation value with the specified annotation id. |
private boolean |
deleteAnnotationValue(long id,
Tuple annotation)
Deletes an annotation in a type table with the specified annotation id. |
boolean |
deleteDefinition(Definition definition)
Delete a specific Definition objects from the database. |
List |
deleteDefinition(String namespace,
String name,
String version,
int type)
Delete Definition objects from the database. |
List |
deleteDefinitionEx(String namespace,
String name,
String version,
int type)
Delete one or more definitions from the backend database. |
private int |
deleteLFNsForDefinitionId(long did)
Deletes all logical filenames that are associated with a particular definition. |
private long |
getAnnotationIdCall(long did,
int pos,
String key)
Retrieves the annotation id of a given call within a transformation. |
private long |
getAnnotationIdDeclare(long did,
String farg,
String key)
Retrieves the annotation id of a given transformation formal argument. |
private long |
getAnnotationIdDerivation(long did,
String key)
Retrieves the annotation id of a given derivation id. |
private long |
getAnnotationIdFilename(String lfn,
String key)
Retrieves the annotation id of a given logical filename. |
private long |
getAnnotationIdTransformation(long did,
String key)
Retrieves the annotation id of a given transformation. |
protected Long |
getDefinitionId(Definition d)
Obtains the primary key id for a given definition. |
protected List |
getDefinitionId(String namespace,
String name,
String version,
int type)
Obtains the list of primary key ids for a matching definitions. |
protected List |
getDefinitionIdEx(String namespace,
String name,
String version,
int type)
Obtains the list of primary key ids for a matching definitions. |
List |
getFQDNList(int type)
Searches the database for a list of fully-qualified names of the definitions sorted in ascending order. |
List |
getNamespaceList(int type)
Searches the database for a list of namespaces of the definitions Sorted in ascending order. |
protected Long |
getSpecificDefinitionId(String namespace,
String name,
String version,
int type)
Obtains the primary key id for a given definition. |
List |
loadAnnotation(String primary,
Object secondary,
int kind)
Retrieves all annotations from an annotatable classes with the specified tuple. |
Tuple |
loadAnnotation(String primary,
Object secondary,
int kind,
String key)
Retrieves a specific annotation from an annotatable classes with the specified tuple. |
private TupleBoolean |
loadAnnotationBoolean(long id,
String key)
Obtains the value at a specific id from the boolean annotations. |
List |
loadAnnotationCall(String fqdi,
int index)
Lists all annotations for a call statement. |
Tuple |
loadAnnotationCall(String fqdi,
int index,
String key)
Obtains the value to a specific key for a call statement. |
private TupleDate |
loadAnnotationDate(long id,
String key)
Obtains the value at a specific id from the date annotations. |
List |
loadAnnotationDeclare(String fqdi,
String farg)
Lists all annotations for a formal argument. |
Tuple |
loadAnnotationDeclare(String fqdi,
String farg,
String key)
Obtains the value to a specific key in an annotated formal argument. |
List |
loadAnnotationDerivation(String fqdi)
Lists all annotations for a derivation. |
Tuple |
loadAnnotationDerivation(String fqdi,
String key)
Obtains the value to a specific key in an annotated derivation. |
List |
loadAnnotationFilename(String filename)
Lists all annotations for a logical filename. |
Tuple |
loadAnnotationFilename(String filename,
String key)
Obtains the value to a specific key in an annotated filename. |
private Tuple |
loadAnnotationFinal(long id,
String key)
Tries to retrieve a tuple value from its annotation id by walking over all tables, most likely one first. |
private TupleFloat |
loadAnnotationFloat(long id,
String key)
Obtains the value at a specific id from the float annotations. |
private TupleInteger |
loadAnnotationInteger(long id,
String key)
Obtains the value at a specific id from the integer annotations. |
private TupleString |
loadAnnotationString(long id,
String key)
Obtains the value at a specific id from the string annotations. |
List |
loadAnnotationTransformation(String fqdi)
Lists all annotations for a transformation. |
Tuple |
loadAnnotationTransformation(String fqdi,
String key)
Obtains the value to a specific key in an annotated transformation. |
private Definition |
loadDefinition(long id)
Load a single Definition from the backend database into a Java object by its primary key id. |
Definition |
loadDefinition(String namespace,
String name,
String version,
int type)
Loads a single Definition from the backend database into an Java object. |
private VDLxParser |
parserInstance()
Instantiates an XML parser for VDLx on demand. |
long |
saveAnnotation(String primary,
Object secondary,
int kind,
Tuple annotation,
boolean overwrite)
Annotates any of the annotatable classes with the specified tuple. |
long |
saveAnnotationCall(String fqdi,
int index,
Tuple annotation,
boolean overwrite)
Annotates a transformation call with a tuple. |
long |
saveAnnotationDeclare(String fqdi,
String formalname,
Tuple annotation,
boolean overwrite)
Annotates a transformation argument with a tuple. |
long |
saveAnnotationDerivation(String fqdi,
Tuple annotation,
boolean overwrite)
Annotates a derivation with a tuple. |
long |
saveAnnotationFilename(String filename,
Tuple annotation,
boolean overwrite)
Annotates a logical filename with a tuple. |
long |
saveAnnotationTransformation(String fqdi,
Tuple annotation,
boolean overwrite)
Annotates a transformation with a tuple. |
private boolean |
saveAnnotationValue(long id,
Tuple annotation)
Inserts a tuple into the correct type-table for annotations. |
boolean |
saveDefinition(Definition definition,
boolean overwrite)
Saves a Definition, that is either a Transformation or Derivation, into the backend database. |
private void |
saveScalar(long id,
Scalar scalar,
Set already,
PreparedStatement[] stmt,
int[] count)
Saves all logical filenames from a Scalar object. |
List |
searchAnnotation(int kind,
Object arg,
QueryTree tree)
Search for LFNs or Definitions that has certain annotations |
ResultSet |
searchAnnotation(List select,
String table,
Map where,
String order)
A not very generic method to search annotation (and anything) in the database. |
List |
searchDefinition(String namespace,
String name,
String version,
int type)
Search the database for definitions by ns::name:version triple and by type (either Transformation or Derivation). |
List |
searchDefinitionEx(String namespace,
String name,
String version,
int type)
Search the database for definitions by ns::name:version triple and by type (either Transformation or Derivation). |
List |
searchFilename(String lfn,
int link)
Searches the database for all derivations that contain a certain LFN. |
List |
searchLFN(String lfn,
int link)
Searches the database for all LFNs that match a certain pattern. |
private String |
what(Definition d)
Compiles the name of a DV/TR for log messages. |
| Methods inherited from class org.griphyn.vdl.dbschema.DatabaseSchema |
|---|
cachingMakesSense, close, finalize, loadSchema, loadSchema, longOrNull, makeNotNull, stringOrNull |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final String[] c_lfn_names
protected boolean m_deferDeleteCommit
private VDLxParser m_parser
protected Cache m_cache
| Constructor Detail |
|---|
public AnnotationSchema(String dbDriverName)
throws ClassNotFoundException,
NoSuchMethodException,
InstantiationException,
IllegalAccessException,
InvocationTargetException,
SQLException,
IOException
dbDriverName - is the database driver name
ClassNotFoundException
NoSuchMethodException
InstantiationException
IllegalAccessException
InvocationTargetException
SQLException
IOException| Method Detail |
|---|
private VDLxParser parserInstance()
public Definition loadDefinition(String namespace,
String name,
String version,
int type)
throws SQLException
loadDefinition in interface VDCnamespace - namespace, null will be converted into empty stringname - name, null will be converted into empty stringversion - version, null will be converted into empty stringtype - type of the definition (TR or DV), must not be -1.
SQLExceptionDefinition.TRANSFORMATION,
Definition.DERIVATION,
saveDefinition( Definition, boolean )
private Definition loadDefinition(long id)
throws SQLException
id - is a long which represent the primary id.
SQLExceptionloadDefinition( String, String, String, int ),
saveDefinition( Definition, boolean )private String what(Definition d)
d - is a definition
public boolean saveDefinition(Definition definition,
boolean overwrite)
throws SQLException
Please note that updating a definition will remove all the meta- data that was defined for the definition.
saveDefinition in interface VDCdefinition - is the new Definition to store.overwrite - true, if existing defitions will be overwritten by
new ones with the same primary (or secondary) key (-set), or false,
if a new definition will be rejected on key matches.
SQLExceptionDefinition,
Transformation,
Derivation,
loadDefinition( String, String, String, int )
private void saveScalar(long id,
Scalar scalar,
Set already,
PreparedStatement[] stmt,
int[] count)
throws SQLException
id - is the definition id in the DEFINITION tablescalar - is a Scalar instance of which the LFNs are to be saved.already - is a set of filenames that were already added during
this sessionstmt - is an array of the ids of the prepared statements for
the different tables.count - count the number of entries in a prepared statement.
SQLExceptionsaveDefinition( Definition, boolean )
protected Long getSpecificDefinitionId(String namespace,
String name,
String version,
int type)
throws SQLException
namespace - is the specific namespace, null will be mapped to ""name - is the specific name, null will be mapped to ""version - is the specific version, null will be mapped to ""type - is the type identifier, -1 is not allowed.
SQLExceptiongetDefinitionId( String, String, String, int )
protected Long getDefinitionId(Definition d)
throws SQLException
d - is a definition specification.
SQLExceptiongetSpecificDefinitionId( String, String, String, int ),
getDefinitionId( String, String, String, int )
protected List getDefinitionId(String namespace,
String name,
String version,
int type)
throws SQLException
namespace - namespace, null to match any namespacename - name, null to match any nameversion - version, null to match any versiontype - definition type (TR or DV)
SQLExceptionDefinition.TRANSFORMATION,
Definition.DERIVATION,
getDefinitionId( Definition )
protected List getDefinitionIdEx(String namespace,
String name,
String version,
int type)
throws SQLException
namespace - namespace, null to match any namespacename - name, null to match any nameversion - version, null to match any versiontype - definition type (TR or DV)
SQLExceptionDefinition.TRANSFORMATION,
Definition.DERIVATION,
getDefinitionId( Definition )
public boolean containsDefinition(Definition definition)
throws SQLException
containsDefinition in interface VDCdefinition - the definition object to search for
SQLException
private List deleteAnnotationFromDefinition(long id)
throws SQLException
id - is the definition id to remove
SQLException
private int deleteLFNsForDefinitionId(long did)
throws SQLException
did - is the definition id to remove LFNs for
SQLException
public boolean deleteDefinition(Definition definition)
throws SQLException
deleteDefinition in interface VDCdefinition - is the definition specification to delete
SQLExceptionDefinition.TRANSFORMATION,
Definition.DERIVATION
public List deleteDefinition(String namespace,
String name,
String version,
int type)
throws SQLException
deleteDefinition in interface VDCnamespace - namespace, null to match any namespacename - name, null to match any nameversion - version, null to match any versiontype - definition type (TR or DV)
SQLExceptionDefinition.TRANSFORMATION,
Definition.DERIVATION
public List searchDefinition(String namespace,
String name,
String version,
int type)
throws SQLException
searchDefinition in interface VDCnamespace - namespace, null to match any namespacename - name, null to match any nameversion - version, null to match any versiontype - type of definition (TR/DV, or both)
SQLExceptionDefinition.TRANSFORMATION,
Definition.DERIVATION
public List searchFilename(String lfn,
int link)
throws SQLException
searchFilename in interface VDClfn - the LFN namelink - the linkage type of the LFN
SQLExceptionLFN.NONE,
LFN.INPUT,
LFN.OUTPUT,
LFN.INOUT
private long getAnnotationIdTransformation(long did,
String key)
throws SQLException
did - is the definition id of the transformationkey - is the key to search for.
SQLException - if some database operation fails.
private long getAnnotationIdDerivation(long did,
String key)
throws SQLException
did - is the definition id of the derivationkey - is the key to search for.
SQLException - if some database operation fails.
private long getAnnotationIdDeclare(long did,
String farg,
String key)
throws SQLException
did - is the definition id of the transformationfarg - is the formal argument namekey - is the key to search for.
SQLException - if some database operation fails.
private long getAnnotationIdCall(long did,
int pos,
String key)
throws SQLException
did - is the definition id of the transformationpos - is the position of the call statementkey - is the key to search for.
SQLException - if some database operation fails.
private long getAnnotationIdFilename(String lfn,
String key)
throws SQLException
lfn - is the logical filename.key - is the key to search for.
SQLException - if some database operation fails.
public boolean deleteAnnotation(String primary,
Object secondary,
int kind,
String key)
throws SQLException,
IllegalArgumentException
deleteAnnotation in interface Annotationprimary - is the primary object specifier for the class.
According to the type, this is either the FQDI, or the filename.secondary - is a helper argument for annotations to calls
and formal arguments, and should be null for all other classes.
For calls, the argument must be packed into Integer.kind - defines the kind/class of object to annotate.key - is the annotation key.
SQLException, - if something went wrong during database
access.
SQLException
IllegalArgumentException
private boolean deleteAnnotationValue(long id)
throws SQLException
id - is the annotation id for which to delete
SQLException, - if something went wrong during database
access.
SQLException
private boolean deleteAnnotationKey(long id,
int kind)
throws SQLException
id - is the annotation id for which to deletekind - is the class of object.
SQLException, - if something went wrong during database
access.
SQLException
private boolean deleteAnnotationValue(long id,
Tuple annotation)
throws SQLException
id - is the annotation id for which to deleteannotation - is the annotation which determines the type
SQLException, - if something went wrong during database
access.
SQLException
public boolean deleteAnnotationTransformation(String fqdi,
String key)
throws SQLException,
IllegalArgumentException
deleteAnnotationTransformation in interface Annotationfqdi - is the FQDI of the transformationkey - is the key to search for
SQLException
IllegalArgumentExceptionTransformation
public boolean deleteAnnotationDerivation(String fqdi,
String key)
throws SQLException,
IllegalArgumentException
deleteAnnotationDerivation in interface Annotationfqdi - is the FQDI of the derivationkey - is the key to search for
SQLException
IllegalArgumentExceptionDerivation
public boolean deleteAnnotationDeclare(String fqdi,
String farg,
String key)
throws SQLException,
IllegalArgumentException
deleteAnnotationDeclare in interface Annotationfqdi - is the FQDI of the transformationfarg - is the name of the formal argumentkey - is the key to search for
SQLException
IllegalArgumentExceptionDeclare
public boolean deleteAnnotationCall(String fqdi,
int index,
String key)
throws SQLException,
IllegalArgumentException
deleteAnnotationCall in interface Annotationfqdi - is the FQDI of the transformationindex - is the number of the call to annotate.key - is the key to search for
SQLException
IllegalArgumentExceptionCall
public boolean deleteAnnotationFilename(String filename,
String key)
throws SQLException,
IllegalArgumentException
deleteAnnotationFilename in interface Annotationfilename - is the name of the file that was annotated.key - is the key to search for
SQLException
IllegalArgumentExceptionLFN
private boolean saveAnnotationValue(long id,
Tuple annotation)
throws SQLException
id - is the annotation id for which to insert.annotation - is the annotation to insert. Only the type
and value will be taken, as the key was inserted elsewhere.
SQLException - if something during the database access
went awry.
public long saveAnnotationTransformation(String fqdi,
Tuple annotation,
boolean overwrite)
throws SQLException,
IllegalArgumentException
saveAnnotationTransformation in interface Annotationfqdi - is the FQDI to annotateannotation - is the value to placeoverwrite - is a predicate on replace or maintain.
SQLException
IllegalArgumentExceptionTransformation
public long saveAnnotationDerivation(String fqdi,
Tuple annotation,
boolean overwrite)
throws SQLException,
IllegalArgumentException
saveAnnotationDerivation in interface Annotationfqdi - is the FQDI to annotateannotation - is the value to placeoverwrite - is a predicate on replace or maintain.
SQLException
IllegalArgumentExceptionDerivation
public long saveAnnotationDeclare(String fqdi,
String formalname,
Tuple annotation,
boolean overwrite)
throws SQLException,
IllegalArgumentException
saveAnnotationDeclare in interface Annotationfqdi - is the FQDI to annotateformalname - is the name of the formal argument to annotoate.annotation - is the value to placeoverwrite - is a predicate on replace or maintain.
SQLException
IllegalArgumentExceptionDeclare
public long saveAnnotationCall(String fqdi,
int index,
Tuple annotation,
boolean overwrite)
throws SQLException,
IllegalArgumentException
saveAnnotationCall in interface Annotationfqdi - is the FQDI to annotateindex - is the number of the call to annotate.annotation - is the value to placeoverwrite - is a predicate on replace or maintain.
SQLException
IllegalArgumentExceptionCall
public long saveAnnotationFilename(String filename,
Tuple annotation,
boolean overwrite)
throws SQLException,
IllegalArgumentException
saveAnnotationFilename in interface Annotationfilename - is the FQDI to annotateannotation - is the value to placeoverwrite - is a predicate on replace or maintain.
SQLException
IllegalArgumentExceptionLFN
public long saveAnnotation(String primary,
Object secondary,
int kind,
Tuple annotation,
boolean overwrite)
throws SQLException,
IllegalArgumentException
saveAnnotation in interface Annotationprimary - is the primary object specifier for the class.
According to the type, this is either the FQDI, or the filename.secondary - is a helper argument for annotations to calls
and formal arguments, and should be null for all other classes.
For calls, the argument must be packed into Integer.kind - defines the kind/class of object to annotate.annotation - is the value to place into the class.overwrite - is a predicate on replace or maintain.
SQLException
IllegalArgumentExceptionsaveAnnotationTransformation( String, Tuple, boolean ),
saveAnnotationDerivation( String, Tuple, boolean ),
saveAnnotationCall( String, int, Tuple, boolean ),
saveAnnotationDeclare( String, String, Tuple, boolean ),
saveAnnotationFilename( String, Tuple, boolean )
private TupleBoolean loadAnnotationBoolean(long id,
String key)
throws SQLException
id - is the annotation idkey - is used to create the tuple
SQLException
private TupleInteger loadAnnotationInteger(long id,
String key)
throws SQLException
id - is the annotation idkey - is used to create the tuple
SQLException
private TupleFloat loadAnnotationFloat(long id,
String key)
throws SQLException
id - is the annotation idkey - is used to create the tuple
SQLException
private TupleDate loadAnnotationDate(long id,
String key)
throws SQLException
id - is the annotation idkey - is used to create the tuple
SQLException
private TupleString loadAnnotationString(long id,
String key)
throws SQLException
id - is the annotation idkey - is used to create the tuple
SQLException
private Tuple loadAnnotationFinal(long id,
String key)
throws SQLException
id - is the annotation id to search forkey - is the key for tuple creation.
SQLException
public Tuple loadAnnotationTransformation(String fqdi,
String key)
throws SQLException,
IllegalArgumentException
loadAnnotationTransformation in interface Annotationfqdi - is the FQDI of the transformationkey - is the key to search for
SQLException
IllegalArgumentExceptionTransformation
public Tuple loadAnnotationDerivation(String fqdi,
String key)
throws SQLException,
IllegalArgumentException
loadAnnotationDerivation in interface Annotationfqdi - is the FQDI of the derivationkey - is the key to search for
SQLException
IllegalArgumentExceptionDerivation
public Tuple loadAnnotationDeclare(String fqdi,
String farg,
String key)
throws SQLException,
IllegalArgumentException
loadAnnotationDeclare in interface Annotationfqdi - is the FQDI of the transformationfarg - is the name of the formal argumentkey - is the key to search for
SQLException
IllegalArgumentExceptionDeclare
public Tuple loadAnnotationCall(String fqdi,
int index,
String key)
throws SQLException,
IllegalArgumentException
loadAnnotationCall in interface Annotationfqdi - is the FQDI of the transformationindex - is the number of the call to annotate.key - is the key to search for
SQLException
IllegalArgumentExceptionCall
public Tuple loadAnnotationFilename(String filename,
String key)
throws SQLException,
IllegalArgumentException
loadAnnotationFilename in interface Annotationfilename - is the name of the file that was annotated.key - is the key to search for
SQLException
IllegalArgumentExceptionLFN
public Tuple loadAnnotation(String primary,
Object secondary,
int kind,
String key)
throws SQLException,
IllegalArgumentException
loadAnnotation in interface Annotationprimary - is the primary object specifier for the class.
According to the type, this is either the FQDI, or the filename.secondary - is a helper argument for annotations to calls
and formal arguments, and should be null for all other classes.
For calls, the argument must be packed into Integer.kind - defines the kind/class of object to annotate.key - is the key to look for.
SQLException
IllegalArgumentExceptionloadAnnotationTransformation( String, String ),
loadAnnotationDerivation( String, String ),
loadAnnotationCall( String, int, String ),
loadAnnotationDeclare( String, String, String ),
loadAnnotationFilename( String, String )
public List loadAnnotationTransformation(String fqdi)
throws SQLException,
IllegalArgumentException
loadAnnotationTransformation in interface Annotationfqdi - is the FQDI of the transformation
SQLException
IllegalArgumentExceptionTransformation
public List loadAnnotationDerivation(String fqdi)
throws SQLException,
IllegalArgumentException
loadAnnotationDerivation in interface Annotationfqdi - is the FQDI of the derivation
SQLException
IllegalArgumentExceptionDerivation
public List loadAnnotationDeclare(String fqdi,
String farg)
throws SQLException,
IllegalArgumentException
loadAnnotationDeclare in interface Annotationfqdi - is the FQDI of the transformationfarg - is the name of the formal argument
SQLException
IllegalArgumentExceptionDeclare
public List loadAnnotationCall(String fqdi,
int index)
throws SQLException,
IllegalArgumentException
loadAnnotationCall in interface Annotationfqdi - is the FQDI of the transformationindex - is the number of the call to annotate.
SQLException
IllegalArgumentExceptionCall
public List loadAnnotationFilename(String filename)
throws SQLException,
IllegalArgumentException
loadAnnotationFilename in interface Annotationfilename - is the logical filename.
SQLException
IllegalArgumentExceptionLFN
public List loadAnnotation(String primary,
Object secondary,
int kind)
throws SQLException,
IllegalArgumentException
loadAnnotation in interface Annotationprimary - is the primary object specifier for the class.
According to the type, this is either the FQDI, or the filename.secondary - is a helper argument for annotations to calls
and formal arguments, and should be null for all other classes.
For calls, the argument must be packed into Integer.kind - defines the kind/class of object to annotate.
SQLException
IllegalArgumentExceptionloadAnnotationTransformation( String ),
loadAnnotationDerivation( String ),
loadAnnotationCall( String, int ),
loadAnnotationDeclare( String, String ),
loadAnnotationFilename( String )
public List searchAnnotation(int kind,
Object arg,
QueryTree tree)
throws SQLException
searchAnnotation in interface Annotationkind - defines the kind/class of object annotated.arg - is used only for TR ARG and TR CALL. For the former
it is the name of the argument (String), for the latter the position of
the call (Integer).tree - stores the query tree to query the annotation
SQLException - if something goes wrong with the database.QueryTree
public ResultSet searchAnnotation(List select,
String table,
Map where,
String order)
throws SQLException
WARNING: This is a method for internal use only.
select - is the ordered set of column names to select, or
simply a one-value list with an asterisk.table - is the name of the table to select from.where - is a collection of column names and values they must equal.order - is an optional ordering string.
SQLException - if something goes wrong with the database.DatabaseDriver.select( java.util.List, String, java.util.Map, String )
public List deleteDefinitionEx(String namespace,
String name,
String version,
int type)
throws SQLException
null value, or have special characters '%' and '_'.
deleteDefinitionEx in interface Advancednamespace - namespacename - nameversion - versiontype - definition type (TR or DV)
SQLExceptionDefinition.TRANSFORMATION,
Definition.DERIVATION
public List searchDefinitionEx(String namespace,
String name,
String version,
int type)
throws SQLException
searchDefinitionEx in interface Advancednamespace - namespace, null to match any namespacename - name, null to match any nameversion - version, null to match any versiontype - type of definition, see below, or -1 as wildcard
SQLExceptionDefinition.TRANSFORMATION,
Definition.DERIVATION,
loadDefinition( String, String, String, int )
public List searchLFN(String lfn,
int link)
throws SQLException
searchLFN in interface Advancedlfn - the LFN namelink - the linkage type of the LFN
SQLExceptionLFN.NONE,
LFN.INPUT,
LFN.OUTPUT,
LFN.INOUT
public List getNamespaceList(int type)
throws SQLException
getNamespaceList in interface Advancedtype - type of definition, see below, or -1 for both
SQLExceptionDefinition.TRANSFORMATION,
Definition.DERIVATION
public List getFQDNList(int type)
throws SQLException
getFQDNList in interface Advancedtype - type of definition, see below, or -1 for both
SQLExceptionDefinition.TRANSFORMATION,
Definition.DERIVATION
public ResultSet backdoor(String query)
throws SQLException
WARNING: This is a method for internal use only.
query - is an SQL query statement.
SQLException - if something goes wrong with the database.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||