Interface DbNamingStrategy


public interface DbNamingStrategy
Interface to define the naming strategy to map EntityBeans to a database.
Since:
1.0.0
See Also:
  • Method Details

    • getColumnName

      default String getColumnName(io.github.mmm.property.ReadableProperty<?> property)
      Parameters:
      property - the ReadableProperty to derive the column name from.
      Returns:
      the column name for the given property.
    • getColumnName

      default String getColumnName(String rawColumnName)
      Parameters:
      rawColumnName - the raw column name to map. May be the property name or remapped and decomposed from it.
      Returns:
      the final column name.
    • getTableName

      default String getTableName(EntityBean bean)
      Parameters:
      bean - the EntityBean to map to a database table.
      Returns:
      the physical table name.
    • getTableName

      default String getTableName(AbstractEntityClause<?,?,?> entityClause)
      Parameters:
      entityClause - the AbstractEntityClause.
      Returns:
      the physical table name.
    • getTableName

      default String getTableName(String rawTableName)
      Parameters:
      rawTableName - the raw table name to map. May be the stable entity name.
      Returns:
      the database table name.
    • of

      static DbNamingStrategy of()
      Returns:
      the default DbNamingStrategy.
    • of

      static DbNamingStrategy of(io.github.mmm.base.text.CaseSyntax caseSyntax)
      Parameters:
      caseSyntax - the CaseSyntax to use.
      Returns:
      the DbNamingStrategy converting to the given CaseSyntax.
    • ofRdbms

      static DbNamingStrategy ofRdbms()
      Returns:
      the DbNamingStrategy for legacy RDBMS.