ClassTableName¶
-
public final class
ClassTableName
¶ Util class, that provides methods connected to the table name generation.
Methods¶
getTableName¶
-
public static String
getTableName
(String table, String suffix)¶ Builds table name for the underlying database, based on the provided values. Replaces all occurences of hyphen (“-”) and space (” ”) with the underscore (“_”) and makes all characters uppercase.
Parameters: - table – the base table name
- suffix – suffix to use, after the base name
Returns: parsed table name
getTableName¶
-
public static String
getTableName
(Entity entity)¶ Builds table name for the underlying database, based on the given entity. Replaces all occurences of hyphen (“-”) and space (” ”) with the underscore (“_”) and makes all characters uppercase.
Parameters: - entity – entity to build table name for
Returns: parsed table name
getTableName¶
-
public static String
getTableName
(Entity entity, EntityType type)¶ Builds table name for the underlying database, based on the given entity. Replaces all occurences of hyphen (“-”) and space (” ”) with the underscore (“_”) and makes all characters uppercase.
Parameters: - entity – entity to build table name for
- type – the type of an entity; will be added to the end of the name, if other than “STANDARD”
Returns: parsed table name
getTableName¶
-
public static String
getTableName
(String className, String module, String namespace, String tableName, EntityType entityType)¶ Builds table name for the underlying database, based on the provided values. Replaces all occurences of hyphen (“-”) and space (” ”) with the underscore (“_”) and makes all characters uppercase.
Parameters: - className – fully qualified or simple name of the class
- module – entity module (defaults to “MDS”)
- namespace – namespace of the entity
- tableName – base table name; if not empty, this method will simply append the type of an entity to the base name
- entityType – the type of the entity; will be added to the end of the name, if other than “STANDARD”
Returns: parsed table name