Package net.sf.minuteProject.configuration.bean.model.data

Examples of net.sf.minuteProject.configuration.bean.model.data.Column


    // is it a view ?
    Table table= TableUtils.getTable(database, tableName);
    if (table==null)
      table = TableUtils.getView(database, tableName);
     
    Column column = ColumnUtils.getColumn(table, columnName);
   
    // is it a view
    Table foreignTable= TableUtils.getTable(database, foreignTableName);
    if (foreignTable==null)
      foreignTable = TableUtils.getView(database, foreignTableName);
     
    String foreignColumnName = field.getLinkToTargetField();
    if (foreignColumnName==null)
      foreignColumnName = TableUtils.getPrimaryKey(foreignTable);
    Column foreignColumn = ColumnUtils.getColumn(foreignTable, foreignColumnName);
   
    if (table!=null && column != null && foreignTable!=null && foreignColumn!=null) {
      reference.setLocalTable(table);
      reference.setLocalColumn(column);
      reference.getLocalColumn().setAlias(reference.getLocalColumn().getAlias());
View Full Code Here


      columns = new ArrayList<Column>();
      if (table!=null) {
        for (Iterator iter = getFields().iterator(); iter.hasNext();) {
          Field field = (Field)iter.next();
          for (int i = 0; i <table.getColumns().length; i++) {
            Column column = table.getColumn(i);
            if (field.getName().equals(column.getName()))
              columns.add(column);
          }
        }
      }
    }
View Full Code Here

TOP

Related Classes of net.sf.minuteProject.configuration.bean.model.data.Column

Copyright © 2018 www.massapicom. 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.