|
com.im.df/1 5.8 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.im.df.util.DBNameUtils.DefaultValidator
public static class DBNameUtils.DefaultValidator
Default validator for the basic validation of DB a DFItem names
| Constructor Summary | |
|---|---|
DBNameUtils.DefaultValidator(DBNameUtils.VType type)
Creates default validator |
|
DBNameUtils.DefaultValidator(DBNameUtils.VType type,
DFContainer parentContainer)
Creates default validator |
|
DBNameUtils.DefaultValidator(DBNameUtils.VType type,
DFContainer parentContainer,
String ownCurrentName)
Creates default validator |
|
DBNameUtils.DefaultValidator(DBNameUtils.VType type,
int maxLength)
Creates default validator |
|
DBNameUtils.DefaultValidator(DBNameUtils.VType type,
String[] usedNames)
Creates default validator |
|
DBNameUtils.DefaultValidator(DBNameUtils.VType type,
String[] usedNames,
boolean usedNamesCaseSensitive)
Creates default validator |
|
DBNameUtils.DefaultValidator(DBNameUtils.VType type,
String[] usedNames,
boolean usedNamesCaseSensitive,
int maxLength)
Creates default validator |
|
DBNameUtils.DefaultValidator(DBNameUtils.VType type,
String[] usedNames,
int maxLength)
Creates default validator |
|
| Method Summary | |
|---|---|
static DBNameUtils.DefaultValidator |
forItem(DFItem item)
|
int |
getMaxLength()
Get maximum possible dbNames length. |
boolean |
isMustExist()
|
SchemaQualifiedName |
normalizeName(SchemaQualifiedName dbName)
|
String |
normalizeName(String dbName)
Return acceptable db name |
protected String |
normalizeName(String dbName,
boolean doValidation)
|
void |
setMaxLength(int maxLength)
Set maximum possible dbNames length. |
void |
setMustExist(boolean mustExist)
|
String |
validate(String name)
Validate the name. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DBNameUtils.DefaultValidator(DBNameUtils.VType type)
type - Type of the validator - because of proper error messages
public DBNameUtils.DefaultValidator(DBNameUtils.VType type,
int maxLength)
type - Type of the validator - because of proper error messagesmaxLength - Maximum name length
public DBNameUtils.DefaultValidator(DBNameUtils.VType type,
DFContainer parentContainer)
type - Type of the validator - because of proper error messagesparentContainer - Is used for getting the existing DFitems names.
public DBNameUtils.DefaultValidator(DBNameUtils.VType type,
DFContainer parentContainer,
String ownCurrentName)
type - Type of the validator - because of proper error messagesparentContainer - Is used for getting the existing DFitems names.ownCurrentName - Current name of the item (will be accepted as correct)
public DBNameUtils.DefaultValidator(DBNameUtils.VType type,
String[] usedNames)
type - Type of the validator - because of proper error messagesusedNames - This array can be used for extending the basic
validation - Validator then also prevent using the name of existing
element (column, table,...)
public DBNameUtils.DefaultValidator(DBNameUtils.VType type,
String[] usedNames,
boolean usedNamesCaseSensitive)
type - Type of the validator - because of proper error messagesusedNames - This array can be used for extending the basic
validation - Validator then also prevent using the name of existing
element (column, table,...)usedNamesCaseSensitive - The used names are case sensitive?
public DBNameUtils.DefaultValidator(DBNameUtils.VType type,
String[] usedNames,
int maxLength)
type - Type of the validator - because of proper error messagesusedNames - This array can be used for extending the basic
validation - Validator then also prevent using the name of existing
element (column, table,...)maxLength - Maximum name length
public DBNameUtils.DefaultValidator(DBNameUtils.VType type,
String[] usedNames,
boolean usedNamesCaseSensitive,
int maxLength)
type - Type of the validator - because of proper error messagesusedNames - This array can be used for extending the basic
validation - Validator then also prevent using the name of existing
element (column, table,...)usedNamesCaseSensitive - The used names are case sensitive?maxLength - Maximum name length| Method Detail |
|---|
public static DBNameUtils.DefaultValidator forItem(DFItem item)
public void setMustExist(boolean mustExist)
public boolean isMustExist()
public int getMaxLength()
public void setMaxLength(int maxLength)
maxLength - The maximum length for the column/table/... namepublic String validate(String name)
DBNameUtils.Validator
validate in interface DBNameUtils.Validatorpublic String normalizeName(String dbName)
DBNameUtils.Validator
normalizeName in interface DBNameUtils.Validatorpublic SchemaQualifiedName normalizeName(SchemaQualifiedName dbName)
normalizeName in interface DBNameUtils.Validator
protected String normalizeName(String dbName,
boolean doValidation)
|
com.im.df/1 5.8 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||