Examples of addColumn()


Examples of javax.swing.table.DefaultTableColumnModel.addColumn()

    server_info_param_column.setModelIndex(1);
    server_info_param_column.setHeaderValue(" ");
    server_info_param_column.setCellRenderer(new ServerInfoParamCellRenderer());
   
    TableColumnModel column_model = new DefaultTableColumnModel();
    column_model.addColumn(server_info_label_column);
    column_model.addColumn(server_info_param_column);
   
    this.setModel(new ServerInfoTableModel());
    this.setColumnModel(column_model);
  }
View Full Code Here

Examples of javax.swing.table.DefaultTableModel.addColumn()

   * @return A <code>TableModel</code>.
   */
  public static TableModel createData()
  {
    final DefaultTableModel data = new DefaultTableModel();
    data.addColumn("Data");
    data.addColumn("A");
    data.addColumn("B");
    data.addColumn("C");
    data.addRow(new Object[]{"data.firstElement", new Double(43.0), new Double(127.5), new Double(10001.999)});
    data.addRow(new Object[]{"data.secondElement", new Double(57.0), new Double(108.5), new Double(-10001.999)});
View Full Code Here

Examples of javax.swing.table.TableColumnModel.addColumn()

    server_info_param_column.setModelIndex(1);
    server_info_param_column.setHeaderValue(" ");
    server_info_param_column.setCellRenderer(new ServerInfoParamCellRenderer());
   
    TableColumnModel column_model = new DefaultTableColumnModel();
    column_model.addColumn(server_info_label_column);
    column_model.addColumn(server_info_param_column);
   
    this.setModel(new ServerInfoTableModel());
    this.setColumnModel(column_model);
  }
View Full Code Here

Examples of liquibase.change.core.AddColumnChange.addColumn()

    public void generateStatements_multipleColumns() {
        AddColumnChange change = new AddColumnChange();
        AddColumnConfig column1 = new AddColumnConfig();
        column1.setName("column1");
        column1.setType("INT");
        change.addColumn(column1);
        AddColumnConfig column2 = new AddColumnConfig();
        column2.setName("column2");
        column2.setType("INT");
        change.addColumn(column2);
View Full Code Here

Examples of liquibase.change.core.CreateIndexChange.addColumn()

        createTableChange.addColumn(new ColumnConfig().setName("other_column").setType("int"));

        CreateIndexChange createIndexChange = new CreateIndexChange();
        createIndexChange.setIndexName(change.getIndexName());
        createIndexChange.setTableName(usedTableName);
        createIndexChange.addColumn((AddColumnConfig) new AddColumnConfig().setName("name"));

        return new Change[] {createTableChange, createIndexChange };

    }
View Full Code Here

Examples of liquibase.change.core.CreateTableChange.addColumn()

    @Test
    public void serialize__change() {
        ChangeSet changeSet = new ChangeSet("test1", "nvoxland", false, true, "/test/me.txt", null, null, null);
        CreateTableChange change = new CreateTableChange();
        change.setTableName("testTable");
        change.addColumn(new ColumnConfig().setName("id").setType("int"));
        change.addColumn(new ColumnConfig().setName("name").setType("varchar(255)"));
        changeSet.addChange(change);

        String out = new YamlChangeLogSerializer().serialize(changeSet, false);
View Full Code Here

Examples of liquibase.change.core.DropColumnChange.addColumn()

    @Test
    public void generateStatements_multipleColumns() {
        DropColumnChange change = new DropColumnChange();
        ColumnConfig column1 = new ColumnConfig();
        column1.setName("column1");
        change.addColumn(column1);
        ColumnConfig column2 = new ColumnConfig();
        column2.setName("column2");
        change.addColumn(column2);

        SqlStatement[] statements = change.generateStatements(new MockDatabase());
View Full Code Here

Examples of liquibase.change.core.InsertDataChange.addColumn()

        InsertDataChange insertDataChange1 = new InsertDataChange();
        insertDataChange1.setCatalogName(change.getCatalogName());
        insertDataChange1.setSchemaName(change.getSchemaName());
        insertDataChange1.setTableName(change.getTableName());
        insertDataChange1.addColumn(new ColumnConfig().setName("id").setType("int").setValueNumeric(1));
        insertDataChange1.addColumn(new ColumnConfig().setName("name").setType("varchar(255)").setValue("Row A"));

        InsertDataChange insertDataChange2 = new InsertDataChange();
        insertDataChange2.setCatalogName(change.getCatalogName());
        insertDataChange2.setSchemaName(change.getSchemaName());
View Full Code Here

Examples of liquibase.change.core.LoadDataChange.addColumn()

                LoadDataColumnConfig columnConfig = new LoadDataColumnConfig();
                columnConfig.setHeader(colName);
                columnConfig.setName(colName);
                columnConfig.setType(dataTypes[i]);

                change.addColumn(columnConfig);
            }

            return new Change[]{
                    change
            };
View Full Code Here

Examples of liquibase.statement.core.CreateTableStatement.addColumn()

            if (constraints != null && constraints.isPrimaryKey() != null && constraints.isPrimaryKey()) {

                statement.addPrimaryKeyColumn(column.getName(), columnType, defaultValue, constraints.getPrimaryKeyName(), constraints.getPrimaryKeyTablespace());

            } else {
                statement.addColumn(column.getName(),
                        columnType,
                        defaultValue,
                        column.getRemarks());
            }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.