コード例 #1
0
  /** Return a platform independant definition of the LPROJECT database table. */
  public static TableDefinition tableDefinition() {
    TableDefinition definition = new TableDefinition();

    definition.setName("BUDGET");
    definition.addIdentityField("ID", BigInteger.class, 15);
    definition.addField("CUR", String.class, 3);
    definition.addField("AMNT", Double.class, 15, 2);

    return definition;
  }
コード例 #2
0
  /** Return a platform independant definition of the database table. */
  public static TableDefinition tableDefinition() {
    TableDefinition definition = new TableDefinition();

    definition.setName("OWNER_A");

    definition.addIdentityField("ID", java.math.BigDecimal.class, 15);
    definition.addField("NAME", String.class, 10);
    definition.addField("ONE_TO_ONE_", java.math.BigDecimal.class, 15);
    definition.addForeignKeyConstraint("OWNER_A_ONE_TO_ONE", "ONE_TO_ONE_", "ID", "OWNER_B");

    return definition;
  }