|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--uk.ac.ic.doc.automed.STR
The STR library<<
| Field Summary | |
static java.lang.String |
STR_DataSourceName
|
| Constructor Summary | |
STR()
|
|
| Method Summary | |
static boolean |
atDebugLevel(int level)
Return true if the debug level set by setDebugLevel(int) is
at least at a certain level. |
static boolean |
atSectionDebugLevel(int section,
int level)
Tests whether the section of code has been set to at least the debug level specified. |
static void |
copySchemaObject(int obidToCopy,
int sid)
Deprecated. contents of intentional schemas will no longer be stored in the STR. The materialization code does not use this method. This method is called when the contents of an intentional schema are being materialized. The temporary copy of the object has the same OBID as the original, it just exists in the new SID as well as the original (via the objectSchema table). |
static int |
createAccessMethod(int sid,
java.lang.String url,
int pid,
java.lang.String dbDriver,
java.lang.String username)
Add the access methods of a schema to the STR. Precondition: The schema whose access methods are being added must already exist in the schemas table. |
static int |
createIntSchema(java.lang.String name)
Adds an intentional schema to the STR. Returns an integer that specifies the schema identifier (SID) assigned to the new schema. |
static int |
createProtocol(java.lang.String name)
Add the given protocol to the STR. |
static int |
createSchema(java.lang.String name,
boolean isES,
boolean isEDB,
boolean isDataSrc)
Adds a new schema to the STR. |
static int |
createSchemaObject(int sid,
int cid,
java.lang.String value)
Adds a new schema object to the STR. |
static void |
createScheme(int obid,
int pos,
int sobid)
Adds a scheme to the STR. |
static void |
createTransformation(java.lang.String action,
int fromObj,
int toObj,
int fromSchema,
int toSchema,
java.lang.String function,
java.lang.String constraint)
Adds a transformation to the STR. |
static void |
debugPrintStackTrace(java.lang.Throwable throwable,
int level)
Print an throwable's stack trace, but only at a certain debug level |
static java.lang.String |
flattenSchemes(java.lang.Object[] schemes)
Converts an Object array representation of a schema
object's scheme into a String representation. |
static int[] |
getAccessMethodBySID(int sid)
Returns all the access method identifiers (AMID) that point to the access methods for the specified schema. |
static java.lang.String |
getAccessMethodDBDriver(int amid)
Returns the database driver of the specified access method. |
static int |
getAccessMethodPID(int amid)
Returns the protocol identifier (PID) of the specified access method. |
static int |
getAccessMethodSID(int amid)
Returns the schema identifier (SID) to which the specified access method connects. |
static java.lang.String |
getAccessMethodURL(int amid)
Returns the URL of the specified access method. |
static java.lang.String |
getAccessMethodUsername(int amid)
Returns the username of the specified access method. |
static java.lang.String[] |
getAllProtocols()
Returns the name of all the protocols found in the STR. |
static java.lang.String[] |
getAllSchemaNames()
Returns the name of all the schemas found in the STR. |
static java.lang.Object[][] |
getAllSchemeNames(int sid)
Returns an Object array of all objects' schemes of a
schema. |
static java.lang.String |
getAllSchemeNamesString(int sid)
Returns the scheme representation (of type String)
of all objects' schemes of a schema. |
static java.lang.String |
getCloseSchemeBracket()
Return String used to close schemes |
static java.lang.String |
getDataSourceName()
Returns the name of the repository in the local database. |
static int |
getDebugLevel()
Return the value of the debug level at set by setDebugLevel(int) |
static java.lang.Object[] |
getObjectSchemeNames(int obid)
Returns an Object array of an object's scheme. |
static java.lang.String |
getObjectSchemeNamesString(int obid)
Returns the scheme representation (of type String})
of an object's scheme. |
static java.lang.String |
getOpenSchemeBracket()
Return String used to open schemes |
static int |
getProtocolByName(java.lang.String name)
Returns the protocol identifier (PID) of the specified protocol name. |
static java.lang.String |
getProtocolName(int pid)
Returns the name of the given protocol identifier (PID). |
static int |
getSchemaByName(java.lang.String name)
Returns the schema identifier (SID) of the schema specified by name. Assumption:schema names are unique. |
static int[] |
getSchemaIDs()
Returns the IDs of all the schemas found in the STR. |
static java.awt.Point |
getSchemaLabelPos(int sid)
|
static java.lang.String |
getSchemaName(int sid)
Returns the name of the schema with the given schema identifier. |
static java.lang.String[] |
getSchemaNames()
Returns the name of all the schemas found in the STR. |
static int |
getSchemaObjectCID(int obid)
Returns the construct identifier (CID) of the schema object. |
static java.awt.Point |
getSchemaObjectLabelPos(int obid)
|
static java.awt.Point |
getSchemaObjectPos(int obid)
|
static int[] |
getSchemaObjects(int sid)
Returns the object identifiers (OBID) in ascending order of all the schema objects that belong to a particular schema. |
static int[] |
getSchemaObjectsByCID(int cid)
Returns the object identifiers (OBID) in ascending order of all the schema objects that are instances of a certain construct type, in order of the OBID to which they belong |
static int |
getSchemaObjectSID(int obid)
Returns the schema identifier (SID) that a schema object belongs to. |
static java.lang.String |
getSchemaObjectValue(int obid)
Returns the name (value) of the schema object. |
static java.awt.Point |
getSchemaPos(int sid)
|
static int[] |
getSchemaSIDs()
Returns the schema identifier (SID) of all the schemas found in the STR. |
static int[] |
getSchemeOBIDList(int sobid)
Returns a list of all schema object identifiers (OBID) by which a particular schema object is referenced. |
static int |
getSchemePos(int obid,
int sobid)
Returns the position of a referenced schema object in the scheme of a particular schema object. |
static int[] |
getSchemePosList(int obid)
Returns a list of positions in the scheme of a particular schema object. |
static int |
getSchemeSOBID(int obid,
int pos)
Returns the object identifier (SOBID) of the referenced schema object in the specified schema object's scheme at the given position. |
static int[] |
getSchemeSOBIDList(int obid)
Returns a list of all schema object identifiers (SOBID) referenced by a particular schema object. |
static int |
getSectionDebugLevel(int section)
Gets the debug level which the section of code has been set to. |
static java.lang.String |
getSTR_DataSourceName()
Deprecated. use getDataSourceName() |
static java.lang.String |
getTranAction(int fromSchema,
int toSchema)
Returns the action of transformation between two schemas. |
static java.lang.String |
getTranConstraint(int fromSchema,
int toSchema)
Returns the constraint of a transformation between two schemas. |
static int |
getTranFromObject(int fromSchema,
int toSchema)
Returns the schema object to be transformed in a transformation. |
static int[] |
getTranFromSchema(int toSchema)
Returns a list of schema identifiers (SID) from which a particular schema can be derived. |
static java.lang.String |
getTranFunction(int fromSchema,
int toSchema)
Returns the function of a transformation between two schemas. |
static java.util.Vector |
getTransformations()
Returns a vector representing all transformations in the repository |
static int[][] |
getTransformationsByOBID(int obid)
Returns the pairs of schema identifiers (SID) of all the schema transformations that involve the supplied OBID |
static int |
getTranToObject(int fromSchema,
int toSchema)
Returns the schema object as a result of a transformation. |
static int[] |
getTranToSchema(int fromSchema)
Returns a list of schema identifiers (SID) which are derived from a particular schema. |
static boolean |
isSchemaCached(int sid)
Deprecated. the isCached field in the schema table is no longer in use. Determines whether or not the objects of the specified schema are cached. |
static boolean |
isSchemaDataSource(int sid)
Determines whether or not the specified schema represents a data source. |
static boolean |
isSchemaExtDB(int sid)
Determines whether or not the specified schema represents an extensional database. |
static boolean |
isSchemaExtSchema(int sid)
Determines whether or not the specified schema is an extensional schema. |
static boolean |
isSchemaObjectTemp(int obid,
int sid)
Deprecated. the isTemp field in the object table is no longer in use. Determines whether or not the schema object is temporary. |
static void |
main(java.lang.String[] args)
|
static void |
removeAccessMethod(int amid)
Removes an access method from the STR. |
static void |
removeAccessMethodBySID(int sid)
Removes all access methods for the given schema identifier (SID). |
static void |
removeAllSchemes(int obid)
Removes all the schemes associated with the given schema object. |
static void |
removeProtocol(int pid)
Removes the name of a protocol from the STR. |
static void |
removeSchema(int sid)
Removes a schema from the STR. |
static void |
removeSchemaObject(int obid)
Removes a schema object from the STR. |
static void |
removeScheme(int obid,
int pos)
Removes a particular position of an object's scheme from the STR. |
static void |
removeTransformation(int fromSchema,
int toSchema)
Removes a transformation from the STR. |
static void |
setAccessMethodDBDriver(int amid,
java.lang.String dbDriver)
Sets the database driver of a particular access method. |
static void |
setAccessMethodPID(int amid,
int pid)
Sets the protocol identifier (PID) of a particular access method. |
static void |
setAccessMethodSID(int amid,
int sid)
Sets the schema identifier (SID) of a particular access method. |
static void |
setAccessMethodURL(int amid,
java.lang.String url)
Sets the URL of a particular access method. |
static void |
setAccessMethodUsername(int amid,
java.lang.String username)
Sets the username of a particular access method. |
static void |
setCloseSchemeBracket(java.lang.String cs)
Set the String |
static void |
setDataSourceName(java.lang.String str)
Sets the name of the Schema Transformation Repository in the local database. |
static void |
setDebugLevel(int level)
Control the printing of debug information printed on the command line |
static void |
setOpenSchemeBracket(java.lang.String os)
Set the String |
static void |
setProtocolName(int pid,
java.lang.String name)
Sets the name of the protocol specified by the given protocol identifier (PID). |
static void |
setSchemaCached(int sid,
boolean value)
Deprecated. the isCached field in the schema table is no longer in use. |
static void |
setSchemaDataSource(int sid,
boolean value)
Sets whether or not a schema is a data source. |
static void |
setSchemaExtDB(int sid,
boolean value)
Sets whether or not a schema is an extentional database. |
static void |
setSchemaExtSchema(int sid,
boolean value)
Sets whether or not a schema is an extentional schema. |
static void |
setSchemaLabelPos(int sid,
int x,
int y)
|
static void |
setSchemaName(int sid,
java.lang.String name)
Sets the name of schema. |
static void |
setSchemaObjectCID(int obid,
int cid)
Sets the construct identifier (CID) of the schema object. |
static void |
setSchemaObjectLabelPos(int obid,
int x,
int y)
|
static void |
setSchemaObjectPos(int obid,
int x,
int y)
|
static void |
setSchemaObjectSID(int obid,
int sid)
Sets the schema identifier (SID) to which a particular schema object belongs. |
static void |
setSchemaObjectValue(int obid,
java.lang.String value)
Sets the name/value of the schema object. |
static void |
setSchemaPos(int sid,
int x,
int y)
|
static void |
setSchemeSOBID(int obid,
int pos,
int sobid)
Sets the referenced schema object in a specific position of the scheme of a schema object. |
static void |
setSectionDebugLevel(int section,
int level)
Set the level of debug info output to the console for a numbered section of code. |
static void |
setSTR_DataSourceName(java.lang.String str)
Deprecated. use setDataSourceName() |
static void |
setTranAction(int fromSchema,
int toSchema,
java.lang.String action)
Sets the action of a transformation between two schemas. |
static void |
setTranConstraint(int fromSchema,
int toSchema,
java.lang.String constraint)
Sets the constraint of a transformation between two schemas. |
static void |
setTranFromObject(int fromSchema,
int toSchema,
int fromObj)
Sets the object identifier (OBID) of the schema object to be transformed in a transformation |
static void |
setTranFunction(int fromSchema,
int toSchema,
java.lang.String function)
Sets the function of a transformation between two schemas. |
static void |
setTranToObject(int fromSchema,
int toSchema,
int toObj)
Sets the object identifier (OBID) of the schema object as a result of a transformation. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static java.lang.String STR_DataSourceName
| Constructor Detail |
public STR()
| Method Detail |
public static void setDebugLevel(int level)
level - value to set the debug level at, according to the following
scale:
-1: no debug information, and no reporting of errors the system
finds in its execution if the system can ignore them
0: no debug information (default), but report on errors that the
system has ignored during its execution
1: only debug information that is to explain to users what is going on
5: standard information for software development work on repository
8: detailed information for software development work on repository
10: all debug informationpublic static int getDebugLevel()
setDebugLevel(int)
public static boolean atDebugLevel(int level)
setDebugLevel(int) is
at least at a certain level. For example, this is used in code of the
form if (atDebugLevel(5)) ... to ensure that something is
only executed when the system has been set at debug level 5 or more
level - threshold value of debug level for which being "at a debug
level" is true
public static void setSectionDebugLevel(int section,
int level)
section - The section of code to set the level for. Setting
the debug level for section 0 sets the global debug levellevel - The debug level for the section of codepublic static int getSectionDebugLevel(int section)
section - The section of code for which the debug level is wanted.
Getting section 0 returns the global debug level
public static boolean atSectionDebugLevel(int section,
int level)
section - The section of code to check the debug level forlevel - The debug level for which is returned true if the
section has been set to a least this value
public static final void debugPrintStackTrace(java.lang.Throwable throwable,
int level)
throwable - that is to be reported onpublic static java.lang.String getDataSourceName()
public static java.lang.String getSTR_DataSourceName()
public static void setDataSourceName(java.lang.String str)
STR by default.
str - the name of the Schema Transformation Repository in the local database.public static void setSTR_DataSourceName(java.lang.String str)
public static int createSchema(java.lang.String name,
boolean isES,
boolean isEDB,
boolean isDataSrc)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
name - name of the new schema.isES - set to true if the new schema is
an extentional schema; false otherwise.
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int createIntSchema(java.lang.String name)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
name - name of the intentional schema.
STRException
java.sql.SQLException - if the name of the new schema is already in use.
DataSourceRepositoryException
java.io.IOException
public static java.lang.String[] getAllSchemaNames()
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int getSchemaByName(java.lang.String name)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
name - name of schema.
STRException - if no record for
the specified name is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getSchemaName(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema.
STRException - if no record for
the specified SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.awt.Point getSchemaPos(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaPos(int sid,
int x,
int y)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.awt.Point getSchemaLabelPos(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaLabelPos(int sid,
int x,
int y)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static boolean isSchemaExtSchema(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema.
true if the schema is an extensional schema;
false otherwise.
STRException - if no record for
the specified SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static boolean isSchemaExtDB(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema.
true if the schema represents an extensional
database; false otherwise.
STRException - if no record for
the specified SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static boolean isSchemaDataSource(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema.
true if the schema represents a data source;
false otherwise.
STRException - if no record for
the specified SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static boolean isSchemaCached(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema.
true if the objects of the specified schema are
cached; false otherwise.
STRException - if no record for
the specified SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaName(int sid,
java.lang.String name)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema.name - new name of the schema.
STRException - if no record for
the specified SID is found in the STR.
java.sql.SQLException - if the specified name is already in use.
DataSourceRepositoryException
java.io.IOException
public static void setSchemaExtSchema(int sid,
boolean value)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema.value - set to true if the schema is an
extentional schema; false otherwise.
STRException - if no record for
the specified SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaExtDB(int sid,
boolean value)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema.value - set to true if the schema is an
extentional database; false otherwise.
STRException - if no record for
the specified SID is found in the STR; or if the specified
schema is not already an extentional schema with value
set to true.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaDataSource(int sid,
boolean value)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema.value - set to true if the schema is a data
source; false otherwise.
STRException - if no record for
the specified SID is found in the STR; or if the specified
schema is not already an extentional database with value
set to true.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaCached(int sid,
boolean value)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema.value - set to true if the schema objects are
cached; false otherwise.
STRException - if no record for
the specified SID is found in the STR; or if the specified schema is
not an intentional schema with value set to true.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String[] getSchemaNames()
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int[] getSchemaIDs()
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int[] getSchemaSIDs()
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void removeSchema(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema to be removed.
STRException - if no record for
the specified SID is found in the STR; or if data dependency of the
specified schema with other data in the STR exists.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int createSchemaObject(int sid,
int cid,
java.lang.String value)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema to which the schema
object belongs.cid - the construct identifier (CID) of the schema object. (See
ModelDefinitionsRepository.createConstruct(int mid, String name,
int constructClass, boolean isRoot))value - the name of (value given to) the schema object.
STRException - if the specified
SID does not exist in the schema table in the STR; or if an invalid
CID is given for the schema object.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void copySchemaObject(int obidToCopy,
int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obidToCopy - object identifier (OBID) of the schema object to copy.sid - schema identifier (SID) of the schema to which the new object
belongs.
STRException - if the specified
obidToCopy (OBID) does not exist in the object table in the STR; or if
the specified SID does not exist in the schema table in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.Object[] getObjectSchemeNames(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
Object array of an object's scheme.
obid - object identifier (OBID) of the schema object.
STRException - if the specified
obidToCopy (OBID) does not exist in the object table in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getObjectSchemeNamesString(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
String})
of an object's scheme.
obid - object identifier (OBID) of the schema object.
STRException - if the specified
obidToCopy (OBID) does not exist in the object table in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.Object[][] getAllSchemeNames(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
Object array of all objects' schemes of a
schema.
sid - schema identifier (SID) of the schema.
STRException - if the specified
SID does not exist in the schema table in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getAllSchemeNamesString(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
String)
of all objects' schemes of a schema.
sid - schema identifier (SID) of the schema.
STRException - if the specified
SID does not exist in the schema table in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOExceptionpublic static void setOpenSchemeBracket(java.lang.String os)
String that is used to open a scheme name,
such as "<<person>>" or "<<person,name>>". By default
it is set to "<<". Normally this would be set to one of "<",
"<<", or "«" (open double chevron)
public static java.lang.String getOpenSchemeBracket()
public static void setCloseSchemeBracket(java.lang.String cs)
String that is used to close a scheme name,
such as "<<person>>" or "<<person,name>>"
By default it is set to ">>". Normally
this would only be changed to ">", ">>", or
"»" (close double chevron)
public static java.lang.String getCloseSchemeBracket()
public static java.lang.String flattenSchemes(java.lang.Object[] schemes)
throws STRException
Object array representation of a schema
object's scheme into a String representation.
schemes - the Object array representation of the
schema object's scheme.
STRException - if the scheme
is somehow corrupt, and thus there is not a known way of
representing it in the standard scheme format.
public static int getSchemaObjectSID(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of the schema object.
STRException - if no record for
the specified OBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int getSchemaObjectCID(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
ModelDefinitionsRepository.createConstruct(int mid, String name,
int constructClass, boolean isRoot))
obid - object identifier (OBID) of the schema object.
STRException - if no record for
the specified OBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.awt.Point getSchemaObjectPos(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaObjectPos(int obid,
int x,
int y)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.awt.Point getSchemaObjectLabelPos(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaObjectLabelPos(int obid,
int x,
int y)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getSchemaObjectValue(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of the schema object.
STRException - if no record for
the specified OBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int[] getSchemaObjects(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of schema.
STRException - if no record for
the specified SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int[] getSchemaObjectsByCID(int cid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException,
ModelDefinitionsRepositoryException
cid - identifier (CID) of construct.
STRException - if no record for
the specified CID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
ModelDefinitionsRepositoryException
public static int[][] getTransformationsByOBID(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - identifier (OBID) of schema object.
STRException - if no transformations for
the specified OBID are found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static boolean isSchemaObjectTemp(int obid,
int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of the schema object.sid - schema to which the object belongs.
true if the schema object is marked as
temporary; false otherwise.
STRException - if no record for
the specified OBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaObjectSID(int obid,
int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of the schema object.sid - schema identifier (SID) of schema to which OBID should belong.
STRException - if no record for
the specified OBID is found in the STR; or if no record for the
specified SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaObjectCID(int obid,
int cid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of schema object.cid - construct identifier (CID) of schema object.
STRException - if no record for
the specified OBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemaObjectValue(int obid,
java.lang.String value)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of schema object.value - new value assigned to schema object.
STRException - if no record for
the specified OBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void removeSchemaObject(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of the schema object to be removed.
STRException - if no record for
the specified OBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void createScheme(int obid,
int pos,
int sobid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of schema object.pos - position of the scheme of the schema object.sobid - object identifier (SOBID) of the referenced schema object
to be placed in the specified position in the scheme.
STRException - if no record for
the specified OBID or SOBID is found in the STR; or if a
record already exists for the specified OBID and schemePos.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int[] getSchemePosList(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
STRException,
java.io.IOException
obid - object identifier (OBID) of schema object.
STRException - if no record for
the specified OBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int[] getSchemeSOBIDList(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of schema object.
STRException - if no record for
the specified OBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int[] getSchemeOBIDList(int sobid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sobid - object identifier (SOBID) of referenced schema object.
STRException - if no record for
the specified SOBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int getSchemeSOBID(int obid,
int pos)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of schema object.pos - position of the schema object's scheme.
STRException - if no record for
the specified OBID and pos is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int getSchemePos(int obid,
int sobid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of schema object.sobid - object identifier (SOBID) of referenced schema object.
STRException - if no record for
the specified OBID or SOBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setSchemeSOBID(int obid,
int pos,
int sobid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of schema object.pos - position of the scheme of the schema object.sobid - object identifier (SOBID) of the referenced schema
object to be put in the specified position.
STRException - if no record for
the specified OBID and pos is found in the STR; or if no record
for the specified SOBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void removeAllSchemes(int obid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of the schema object.
STRException - if no record for
the specified OBID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void removeScheme(int obid,
int pos)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
obid - object identifier (OBID) of schema object.pos - position of the scheme of the schema object to be removed.
STRException - if no record for
the specified OBID and schemePos is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void createTransformation(java.lang.String action,
int fromObj,
int toObj,
int fromSchema,
int toSchema,
java.lang.String function,
java.lang.String constraint)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
action - action of the transformation, its value can be one of
"add", "del", "ren",
"ext", "con", and ident.fromObj - object identifier (OBID) of schema object to be transformed.toObj - object identifier (OBID) of schema object as the result
of transformation.fromSchema - schema identifier (SID) of schema to be transformed.toSchema - schema identifier (SID) of schema as the result of transformation.function - query which expresses how data of the transformed
object can be derived from the original object.
STRException - if a transformation
has already been defined from the specified fromSchema to toSchema;
or if the specified fromObj or toObj is not a valid OBID; or if
fromSchema or toSchema is not a valid SID.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int[] getTranFromSchema(int toSchema)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
toSchema - schema identifier (SID) of schema as a result of a
transformation.
STRException - if no record for
the specified toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int[] getTranToSchema(int fromSchema)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.
STRException - if no record
for the specified fromSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getTranAction(int fromSchema,
int toSchema)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema transformed.
"add", "del", "ren",
"ext", "con", and ident.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getTranFunction(int fromSchema,
int toSchema)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema as a result of a
transformation.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getTranConstraint(int fromSchema,
int toSchema)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema as a result of a
transformation.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int getTranFromObject(int fromSchema,
int toSchema)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema as a result of a
transformation.
null.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int getTranToObject(int fromSchema,
int toSchema)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema as a result of a
transformation.
null.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setTranAction(int fromSchema,
int toSchema,
java.lang.String action)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema as a result of a
transformation.action - action of the transformation - one of 'add',
'del', 'ren', 'ext',
'con', and 'ident'.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR; or if
the specified action is not a valid action (i.e., if it is not
one of 'add', 'del', 'ren',
'ext', 'con', and 'ident').
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setTranFromObject(int fromSchema,
int toSchema,
int fromObj)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema as a result of a
transformation.fromObj - object identifier (OBID) of schema object to be transformed.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setTranToObject(int fromSchema,
int toSchema,
int toObj)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema as a result of a
transformation.toObj - object identifier (OBID) of schema object as the result of
transformation.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setTranFunction(int fromSchema,
int toSchema,
java.lang.String function)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema as a result of a
transformation.function - query which expresses how data of the transformed
object can be derived from the original object.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setTranConstraint(int fromSchema,
int toSchema,
java.lang.String constraint)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema as a result of a
transformation.constraint - the constraint of the transformation.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void removeTransformation(int fromSchema,
int toSchema)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
fromSchema - schema identifier (SID) of source schema.toSchema - schema identifier (SID) of schema as a result of a
transformation.
STRException - if no record for
the specified fromSchema and toSchema SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int createAccessMethod(int sid,
java.lang.String url,
int pid,
java.lang.String dbDriver,
java.lang.String username)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of the schema whose access method
entry is being created.url - URL of database to connect to.pid - protocol identifier (PID) of the protocol used for the
access method.dbDriver - database driver for connecting to the database.username - username for connecting to the database.
STRException - if a record whose
values match the specified values already exists in the accessMethod
table; or if the specified SID or PID is found in the STR.
java.sql.SQLException - if no record for the specified SID or PID is
found in the STR.
DataSourceRepositoryException
java.io.IOException
public static int[] getAccessMethodBySID(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - schema identifier (SID) of schema.
STRException - if no record for
the specified SID is found in the schema table in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int getAccessMethodSID(int amid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - access method identifier (AMID).
STRException - if no record for
the specified AMID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getAccessMethodURL(int amid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - access method identifier (AMID).
STRException - if no record for
the specified AMID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int getAccessMethodPID(int amid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - access method identifier (AMID).
STRException - if no record for
the specified AMID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getAccessMethodDBDriver(int amid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - access method identifier (AMID).
STRException - if no record for
the specified AMID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getAccessMethodUsername(int amid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - access method identifier (AMID).
STRException - if no record for
the specified AMID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setAccessMethodSID(int amid,
int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - the access method identifier (AMID).sid - schema identifier (SID) of the access method.
STRException - if no record for
the specified AMID or SID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setAccessMethodURL(int amid,
java.lang.String url)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - the access method identifier (AMID).url - URL of database that the access method connects to.
STRException - if no record for
the specified AMID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setAccessMethodPID(int amid,
int pid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - the access method identifier (AMID).pid - the protocol identifier (PID) that is used for establishing a
connection to the database.
STRException - if no record for
the specified AMID or PID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setAccessMethodDBDriver(int amid,
java.lang.String dbDriver)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - the access method identifier (AMID).dbDriver - database driver that is used for establishing a
connection to the database.
STRException - if no record for
the specified AMID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setAccessMethodUsername(int amid,
java.lang.String username)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - the access method identifier (AMID).username - username that is used for establishing a
connection to the database.
STRException - if no record for
the specified AMID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void removeAccessMethod(int amid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
amid - the access method identifier (AMID).
STRException - if no record for
the specified AMID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void removeAccessMethodBySID(int sid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
sid - the schema identifier (SID) whose access methods are to
be removed.
STRException - if no record for
the specified AMID is found in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static int createProtocol(java.lang.String name)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
name - the name of the protocol.
STRException
java.sql.SQLException - if a record for the specified name already
exists in the protocol table in the STR.
DataSourceRepositoryException
java.io.IOException
public static int getProtocolByName(java.lang.String name)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
name - name of the protocol.
STRException - if no record for
the specified name is found in the protocol table in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String getProtocolName(int pid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
pid - the protocol identifier (PID).
STRException - if no record for
the specified PID is found in the protocol table in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static java.lang.String[] getAllProtocols()
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
null
if no record is found in the protocol table in the STR.
STRException
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void setProtocolName(int pid,
java.lang.String name)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
java.io.IOException
pid - the protocol identifier (PID).name - new name of the protocol.
STRException - if no record for
the specified PID is found in the protocol table in the STR.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOException
public static void removeProtocol(int pid)
throws STRException,
java.sql.SQLException,
DataSourceRepositoryException,
STRException,
java.io.IOException
pid - the protocol identifier (PID).
STRException - if no record for
the specified PID is found in the protocol table in the STR; or if
data denpendency of the specified protocol with other data in the
STR exists.
java.sql.SQLException
DataSourceRepositoryException
java.io.IOExceptionpublic static void main(java.lang.String[] args)
public static java.util.Vector getTransformations()
throws AutoMedException,
java.sql.SQLException,
java.io.IOException
AutoMedException
java.sql.SQLException
java.io.IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||