Class SQLAlterStatement
java.lang.Object
com.github.tadukoo.database.mysql.syntax.statement.SQLAlterStatement
SQL Alter Statement represents a MySQL Alter statement
- Version:
- Alpha v.0.3
- Author:
- Logan Ferree (Tadukoo)
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
The building part of building aSQLAlterStatement
static interface
Thecolumn definition
part of building aSQLAlterStatement
static interface
static interface
The Column Name part of building aSQLAlterStatement
static interface
Theoperation
part of building aSQLAlterStatement
static class
A builder to use to build aSQLAlterStatement
.static interface
The Table name part of building aSQLAlterStatement
static interface
The Type part of building aSQLAlterStatement
-
Field Summary
Modifier and TypeFieldDescriptionprivate final ColumnDefinition
Thecolumn definition
to be usedprivate final String
The name of the column to alterprivate final ForeignKeyConstraint
Theforeign key
to be added to the tableprivate final SQLColumnOperation
Theoperation
to performprivate final String
The name of the table to alterprivate final SQLType
Thetype
to be altered -
Constructor Summary
ModifierConstructorDescriptionprivate
SQLAlterStatement
(SQLType type, String tableName, SQLColumnOperation operation, String columnName, ColumnDefinition columnDef, ForeignKeyConstraint foreignKey) Constructs aSQLAlterStatement
using the given parameters -
Method Summary
-
Field Details
-
type
Thetype
to be altered -
tableName
The name of the table to alter -
operation
Theoperation
to perform -
columnName
The name of the column to alter -
columnDef
Thecolumn definition
to be used -
foreignKey
Theforeign key
to be added to the table
-
-
Constructor Details
-
SQLAlterStatement
private SQLAlterStatement(SQLType type, String tableName, SQLColumnOperation operation, String columnName, ColumnDefinition columnDef, ForeignKeyConstraint foreignKey) Constructs aSQLAlterStatement
using the given parameters- Parameters:
type
- Thetype
to be alteredtableName
- The name of the table to alteroperation
- Theoperation
to performcolumnName
- The name of the column to altercolumnDef
- Thecolumn definition
to be usedforeignKey
- Theforeign key
to be added to the table
-
-
Method Details
-
builder
- Returns:
- A new
SQLAlterStatement.SQLAlterStatementBuilder
to build a newSQLAlterStatement
-
getType
- Returns:
- The
type
to be altered
-
getTableName
- Returns:
- The name of the table to alter
-
getOperation
- Returns:
- The
operation
to perform
-
getColumnName
- Returns:
- The name of the column to alter
-
getColumnDef
- Returns:
- The
column definition
to be used
-
getForeignKey
- Returns:
- The
foreign key
to be added to the table
-
toString
-