|
www.element4solution.com | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objecte4s.util.E4Object
e4s.db.E4DBIntegrity
public class E4DBIntegrity
Database integrity check functionality. The idea of this module is, that generated classes exists for database column definition. Each of those classes "knows" in which table it is used, and there exists a list of tables and column names using those classes. This includes: Referential checks Referential updates Referential deletes For example, you could declare a class called "addressNumber" and it might be used in a database table called "ADDRESSES" and another table called "EMPLOYEE_ADDRESSES". Before you delete a record, you want to check if a particular number is not used any more in one of the other tables. So you can use the array of used tables, automaticly generated within class tabledef.addressNumber.getUsage() and query the database for all relted tables containing the particular value.
E4DBTypeUsage| Field Summary |
|---|
| Fields inherited from class e4s.util.E4Object |
|---|
CRLF, E4S_CORE_SYSTEM_LANGUAGE, NBSP, NULLSTR, URL_ENCODING_CHARSET |
| Constructor Summary | |
|---|---|
E4DBIntegrity()
|
|
| Method Summary | |
|---|---|
static java.lang.String |
_getSVNVersionString()
|
static void |
bulkDeleteData_internal(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
java.lang.Object value)
|
static void |
bulkDeleteData(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4Long value)
Delete a particular type in all tables where this type is used. |
static void |
bulkDeleteData(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4String value)
Delete a particular type in all tables where this type is used. |
static void |
bulkDeleteData(E4DBTypeUsage[] usage,
E4Long value)
Update a particular type in all tables where this type is used. |
static void |
bulkUpdateData(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4Long old_value,
E4Long new_value)
Update a particular type in all tables where this type is used. |
static void |
bulkUpdateData(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4String old_value,
E4String new_value)
Update a particular type in all tables where this type is used. |
static boolean |
hasAnyData(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4String check_data)
Check, if the data is contained in one or more specified tables. |
static boolean |
hasAnyData(E4DBUsage_Intf[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4Long check_data)
Check, if the data is contained in one or more specified tables. |
static boolean |
hasAnyData(E4DBUsage_Intf[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4Long check_data,
TABLE resulttable)
Check, if the data is contained in one or more specified tables. |
static boolean |
hasAnyData(E4DBUsage_Intf[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4String check_data,
TABLE resulttable)
Check, if the data is contained in one or more specified tables. |
| Methods inherited from class e4s.util.E4Object |
|---|
Calendar, CName, CName, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelNone, E4LabelNone, E4LabelNone, E4LabelNone, E4LabelSys, E4LabelSys, e4sCopyright, e4sVersion, encode, encode, encode, encodeHtml, encodeHtml, encodeHtml, encodeURL, encodeURL, encodeURL, finalize, getLINE, getTRACE, getTRACE, getTRACE, getTRACE, getTRACE, getTRACE, getTraceMemory, HtmlEncode, HtmlEncode, HtmlEncode, isdecimal, isdigit, isnotok, isnotok, isnumeric, isok, isok, isok, isok, lastCallingFunction, lastCallingFunction, lastCallingFunction, lastCallingFunction, lastCallingStack, mkdirs, null2nbsp, null2nbsp, null2nbsp, ok, ok, ok, ok, outPrintln, setLogFile4Trace, setTraceMemory, STACKTRACE, toDebug, toDouble, toFloat, toFloat, toString, TRACE_CALLS, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, wait |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public E4DBIntegrity()
| Method Detail |
|---|
public static boolean hasAnyData(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4String check_data)
throws E4DBException
usage - see the getUsage() function in the generated data-type classes or
build your own list.exclude - you can specify a particular table for exclusion, or null if all tables are validapplobj - the application object, can be nullcheck_data - the string to be checked
E4DBException
public static boolean hasAnyData(E4DBUsage_Intf[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4String check_data,
TABLE resulttable)
throws E4DBException
usage - see the getUsage() function in the generated data-type classes or
build your own list.exclude - you can specify a particular table for exclusion, or null if all tables are validapplobj - the application object, can be nullcheck_data - the string to be checkedresulttable - you can specify a HTML table for result output. Note that this is much
more time consuming, because every occurence must be counted. Set to null if no result
output is required.
E4DBException
public static boolean hasAnyData(E4DBUsage_Intf[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4Long check_data)
throws E4DBException
usage - see the getUsage() function in the generated data-type classes or
build your own list.exclude - you can specify a particular table for exclusion, or null if all tables are validapplobj - the application object, can be nullcheck_data - the string to be checked
E4DBException
public static boolean hasAnyData(E4DBUsage_Intf[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4Long check_data,
TABLE resulttable)
throws E4DBException
usage - see the getUsage() function in the generated data-type classes or
build your own list.exclude - you can specify a particular table for exclusion, or null if all tables are validapplobj - the application object, can be nullcheck_data - the string to be checkedresulttable - you can specify a HTML table for result output. Note that this is much
more time consuming, because every occurence must be counted. Set to null if no result
output is required.
E4DBException
public static void bulkUpdateData(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4String old_value,
E4String new_value)
throws E4DBException
usage - see the getUsage() function in the generated data-type classes or
build your own list.exclude - you can specify a particular table for exclusion, or null if all tables are validapplobj - the application object, can be nullold_value - the string to be replaced fromnew_value - the string to be replaced to
E4DBException
public static void bulkUpdateData(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4Long old_value,
E4Long new_value)
throws E4DBException
usage - see the getUsage() function in the generated data-type classes or
build your own list.exclude - you can specify a particular table for exclusion, or null if all tables are validapplobj - the application object, can be nullold_value - the string to be replaced fromnew_value - the string to be replaced to
E4DBException
public static void bulkDeleteData(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4String value)
throws E4DBException
exclude - you can specify a particular table for exclusion, or null if all tables are validapplobj - the application object, can be nullusage - see the getUsage() function in the generated data-type classes or
build your own list.value - the string to be searched for to identify records deleted
E4DBException
public static void bulkDeleteData(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
E4Long value)
throws E4DBException
exclude - you can specify a particular table for exclusion, or null if all tables are validapplobj - the application object, can be nullusage - see the getUsage() function in the generated data-type classes or
build your own list.value - the string to be searched for to identify records deleted
E4DBException
public static void bulkDeleteData_internal(E4DBTypeUsage[] usage,
E4DBTableName exclude,
E4ApplObj_Intf applobj,
java.lang.Object value)
throws E4DBException
E4DBException
public static void bulkDeleteData(E4DBTypeUsage[] usage,
E4Long value)
throws E4DBException
usage - see the getUsage() function in the generated data-type classes or
build your own list.value - the string to be searched for to identify records deleted
E4DBExceptionpublic static java.lang.String _getSVNVersionString()
|
www.element4solution.com | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||