com.github.drinkjava2.jdialects
Class DDLCreateUtils

java.lang.Object
  extended by com.github.drinkjava2.jdialects.DDLCreateUtils

public class DDLCreateUtils
extends Object

To transfer platform-independent model to create DDL String array

Since:
1.0.2
Author:
Yong Zhu

Constructor Summary
DDLCreateUtils()
           
 
Method Summary
protected static void checkAndInsertToNotRepeatSeq(Set<SequenceIdGenerator> notRepeatedSeq, SequenceIdGenerator seq)
          if name not found, add
If name same, but other fields different, throw exception
If name same, and other field same, ignore
protected static void checkAndInsertToNotRepeatTable(Set<TableIdGenerator> notRepeatedSeq, TableIdGenerator tab)
          if name not found, add
If name same, but other fields different, throw exception
If name same, and other field same, ignore
static String[] toCreateDDL(Dialect dialect, TableModel... tables)
          Transfer tables to DDL by given dialect and without format it, if want get a formatted DDL, use DDLFormatter.format(DDLs) method to format it
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DDLCreateUtils

public DDLCreateUtils()
Method Detail

toCreateDDL

public static String[] toCreateDDL(Dialect dialect,
                                   TableModel... tables)
Transfer tables to DDL by given dialect and without format it, if want get a formatted DDL, use DDLFormatter.format(DDLs) method to format it


checkAndInsertToNotRepeatSeq

protected static void checkAndInsertToNotRepeatSeq(Set<SequenceIdGenerator> notRepeatedSeq,
                                                   SequenceIdGenerator seq)
if name not found, add
If name same, but other fields different, throw exception
If name same, and other field same, ignore


checkAndInsertToNotRepeatTable

protected static void checkAndInsertToNotRepeatTable(Set<TableIdGenerator> notRepeatedSeq,
                                                     TableIdGenerator tab)
if name not found, add
If name same, but other fields different, throw exception
If name same, and other field same, ignore



Copyright © 2018. All rights reserved.