Package com.querydsl.sql.codegen
Class DefaultNamingStrategy
java.lang.Object
com.querydsl.sql.codegen.AbstractNamingStrategy
com.querydsl.sql.codegen.DefaultNamingStrategy
- All Implemented Interfaces:
NamingStrategy
- Direct Known Subclasses:
ExtendedNamingStrategy
DefaultNamingStrategy is the default implementation of the NamingStrategy
interface. It changes underscore usage into camel case form.- Author:
- tiwe
-
Field Summary
Fields inherited from class com.querydsl.sql.codegen.AbstractNamingStrategy
foreignKeysClassName, foreignKeysVariable, primaryKeysClassName, primaryKeysVariable, reservedSuffix -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetClassName(String tableName) Convert the given tableName to a simple class namegetDefaultAlias(EntityType entityType) Get the default alias for the given EntityTypegetDefaultVariableName(EntityType entityType) Get the default variable name for the given EntityTypegetForeignKeysVariable(EntityType entityType) Get the field name for the foreign keys class instancegetPrimaryKeysVariable(EntityType entityType) Get the field name for the primary keys class instancegetPropertyName(String columnName, EntityType entityType) Convert the given column name to a property namegetPropertyNameForForeignKey(String fkName, EntityType entityType) Convert the given foreign key name to a foreign key property namegetPropertyNameForInverseForeignKey(String fkName, EntityType entityType) Convert the given foreign key name to a foreign key property namegetPropertyNameForPrimaryKey(String pkName, EntityType entityType) Convert the given primary key name to a primary key property nameprotected StringtoCamelCase(String str) Methods inherited from class com.querydsl.sql.codegen.AbstractNamingStrategy
appendSchema, escape, getClassName, getForeignKeysClassName, getPackage, getPrimaryKeysClassName, normalizeColumnName, normalizeJavaName, normalizeSchemaName, normalizeSQLName, normalizeTableName, setForeignKeysClassName, setForeignKeysVariable, setPrimaryKeysClassName, setPrimaryKeysVariable, setReservedSuffix, shouldGenerateClass, shouldGenerateForeignKey
-
Constructor Details
-
DefaultNamingStrategy
public DefaultNamingStrategy()
-
-
Method Details
-
getClassName
Description copied from interface:NamingStrategyConvert the given tableName to a simple class name- Returns:
-
getDefaultAlias
Description copied from interface:NamingStrategyGet the default alias for the given EntityType- Returns:
-
getDefaultVariableName
Description copied from interface:NamingStrategyGet the default variable name for the given EntityType- Returns:
-
getForeignKeysVariable
Description copied from interface:NamingStrategyGet the field name for the foreign keys class instance- Specified by:
getForeignKeysVariablein interfaceNamingStrategy- Overrides:
getForeignKeysVariablein classAbstractNamingStrategy- Returns:
-
getPrimaryKeysVariable
Description copied from interface:NamingStrategyGet the field name for the primary keys class instance- Specified by:
getPrimaryKeysVariablein interfaceNamingStrategy- Overrides:
getPrimaryKeysVariablein classAbstractNamingStrategy- Returns:
-
getPropertyName
Description copied from interface:NamingStrategyConvert the given column name to a property name- Returns:
-
getPropertyNameForForeignKey
Description copied from interface:NamingStrategyConvert the given foreign key name to a foreign key property name- Returns:
-
getPropertyNameForInverseForeignKey
Description copied from interface:NamingStrategyConvert the given foreign key name to a foreign key property name- Returns:
-
getPropertyNameForPrimaryKey
Description copied from interface:NamingStrategyConvert the given primary key name to a primary key property name- Returns:
-
toCamelCase
-