Package acdp.tools
Interface Refactor.Names
- Enclosing class:
Refactor
public static interface Refactor.Names
Declares methods for fluently creating a list where each element is equal
to a column name and, provided that the column references a table, the
name of the referenced table.
Instances of this interface, which are returned by the Refactor.names()
method, are used in the Refactor.addTable(java.nio.file.Path, java.lang.String, acdp.design.CustomTable, acdp.tools.Refactor.Names)
method.
The methods declared in this interface must be invoked in the same order
in which the columns appear in the table definition of
the newly added table.
- Author:
- Beat Hörmann
-
Method Summary
Modifier and TypeMethodDescriptionAdds to the list of column and table names the specified column name.Adds to the list of column and table names the specified column name and the specified name of the table that is referenced by this column.
-
Method Details
-
add
Adds to the list of column and table names the specified column name.Invoke this method if this column does not reference a table.
- Parameters:
columnName
- The name of this column, not allowed to benull
and not allowed to be an empty string.- Returns:
- This instance.
- Throws:
IllegalArgumentException
- IfcolumnName
isnull
or an empty string or if this method was invoked before with the same column name.
-
add
Adds to the list of column and table names the specified column name and the specified name of the table that is referenced by this column.Invoke this method if this column references the specified table.
- Parameters:
columnName
- The name of this column, not allowed to benull
and not allowed to be an empty string.tableName
- The name of the referenced table, not allowed to benull
and not allowed to be an empty string. The table must exist in the database.- Returns:
- This instance.
- Throws:
IllegalArgumentException
- IfcolumnName
ortableName
isnull
or an empty string or if this method was invoked before with the same column name.
-