SpiderDB 数据库结构扒取工具

程序名称:SpiderDB

授权协议: Apache

操作系统: 跨平台

开发语言: Java

SpiderDB 介绍

SpiderDB 是一个轻量级的数据库结构扒取工具,使用 Java 开发。它是一个简单的类库可根据数据库的表结构来生成 POJO
对象,使用简单,支持各种不同的数据库系统。

示例代码

DBCrawler dbCrawler = new DBCrawler(connection, ConfigEnum.MAXIMUM);
DataBase dataBase = dbCrawler.getDatabase();
System.out.println(“productName :” + dataBase.getProductName() + ” version:” +
dataBase.getProductVersion());

//Return Schemas
SchemaSet schemaSet = dataBase.getSchemaSet();
Set schemas = schemaSet.getSchemas();
//Iterate to Fetch the schema @R_623_4045@ion and Tables
for(Schema schema : schemas)
{
System.out.println(“SchemaName :” + schema.getSchamaName());
TableSet tableSet = schema.getTableSet();
Set

tables = tableSet.getTables();
//Iterate to fetch the tables
for(Table table : tables)
{
System.out.println(“tableName :” + table.getTableName());
PrimaryKey primaryKey = table.getPrimaryKey();
System.out.println(“pk_Name:”+primaryKey.getPkName() + ” PrimaryKey Columns:”
+ primaryKey.getColumns());

ColumnSet columnSet = table.getColumnSet();
System.out.println(“Table Columns:”+ columnSet.getColumns());

Set foreignKeys = table.getForeignKeys();
System.out.println(“foreignKeys:”+foreignKeys);
}
}

SpiderDB 官网

http://code.google.com/p/spiderdb/

相关编程语言

BlazeDS 是一个基于服务器的Java 远程控制(remoting...
OVal 是一个可扩展的Java对象数据验证框架,验证的规...
Volta 是一套开发工具,专为开发分布式、实时系统应...
OpenDDS 是一个开源的 C++ 实现的 对象管理组织 OMG...
JADE (Java Agent DEvelopment Framework) 是一个完...
FastMM ,在D2006和2007中已代替了原来的内存管理器。