|
Extension SDK | |||||||||
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |
See:
Description
Interface Summary | |
Database | Database - The interface between the JDeveloper code and a data source. |
Class Summary | |
BinaryResource | Object representation of a binary resource retrieved from a connection. |
CheckConstraint | |
Column | Model of a database column. |
Constraint | |
DatabaseFactory | DatabaseFactory |
DatabaseObjectType | Constants for the Database Object Types, as well as a few static utility methods. |
DataType | DataType - Represents an database data type. |
DBNull | NULL database value |
DBObject | Base class for tables, nodes, constraints, etc. |
DBWorkArea | Database WorkArea - basically a todo list when this is committed. |
FKConstraint | |
Index | Model of a database index. |
JavaNodeInfo | |
JdbcDatabase | Implementation of the Database interface for use with JDBC Connections,
currently this implementation handles all three types of database types
(DATABASE_TYPE_GENERIC , DATABASE_TYPE_ORACLE ,
and DATABASE_TYPE_ORACLE_LITE ). |
PKConstraint | |
SchemaObject | |
Sequence | Model of a database sequence. |
Synonym | Model of a database synonym. |
Table | Model of a database table. |
Trigger | |
UniqueConstraint | |
Util | Utility class used by the SQL builders and database classes. |
Provides object oriented method of creating SQL code to generate database objects. The current implementation only supports tables thus far.
Package Specification.
The Object2SQL classes consist of two parts.
The general usage pattern is:
Related Documentation
Example Usage:
For overviews, tutorials, examples, guides, and tool documentation, please see: package oracle.jdeveloper.cm.ds.db; import java.sql.*; import oracle.jdeveloper.cm.rt.*; /** * TestCase #1 for oracle.jdeveloper.cm.ds.db * * @author Robert Clevenger */ public class TestCase1 extends Object { /** * Constructor */ public TestCase1() { } public static void main(String[] args) { DBWorkArea dbWa = new DBWorkArea(); Table tblDept = new Table("DEPT"); tblDept.addColumn(new Column("DEPTNO", DataType.ORA_NUMBER)); tblDept.addColumn(new Column("DNAME", DataType.ORA_VARCHAR2)); Table tblEmp = new Table("EMP"); Column colEmpNo = new Column("EMPNO", DataType.ORA_NUMBER); colEmpNo.setPrimaryKey(true); tblEmp.addColumn(colEmpNo); Column colEname = new Column("ENAME", DataType.ORA_VARCHAR2); colEname.setPrecision(new Integer(200)); tblEmp.addColumn(colEname); tblEmp.addColumn(new Column("DEPTNO", DataType.ORA_NUMBER)); Column colDeptNo = tblEmp.getColumn("DEPTNO"); colDeptNo.setForeignKey(tblDept.getColumn("DEPTNO")); dbWa.addObject(tblEmp); dbWa.addObject(tblDept); DBWorkAreaBuilder builder = DBWorkAreaBuilderFactory.getBuilder( DBWorkAreaBuilderFactory.ORACLE_BUILDER); String sql = builder.buildSqlFromObject(dbWa); System.out.println(sql); } }
|
Extension SDK | |||||||||
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |
Copyright ©1997, 2003, Oracle. All rights reserved.