站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > Hibernate 3.2.4 正式版 API 英文文档

DDLFormatter (Hibernate API Documentation) - Hibernate 3.2.4 正式版 API 英文文档


org.hibernate.pretty
Class DDLFormatter

java.lang.Object
  extended byorg.hibernate.pretty.DDLFormatter

public class DDLFormatter
extends Object


Constructor Summary
DDLFormatter(String sql)
           
 
Method Summary
 String format()
          Format an SQL statement using simple rules: a) Insert newline after each comma; b) Indent three spaces after each inserted newline; If the statement contains single/double quotes return unchanged, it is too complex and could be broken by simple formatting.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DDLFormatter

public DDLFormatter(String sql)
Method Detail

format

public String format()
Format an SQL statement using simple rules: a) Insert newline after each comma; b) Indent three spaces after each inserted newline; If the statement contains single/double quotes return unchanged, it is too complex and could be broken by simple formatting.