Top Description Inners Fields Constructors Methods
org.hibernate.engine.jdbc.internal

public final Enum FormatStyle

extends Enum<FormatStyle>
Class Inheritance

Represents the the understood types or styles of formatting.
Author
Steve Ebersole

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class

Field Summary

Modifier and TypeField and Description
public static final FormatStyle
BASIC

Formatting for SELECT, INSERT, UPDATE and DELETE statements

public static final FormatStyle
DDL

Formatting for DDL (CREATE, ALTER, DROP, etc) statements

private final Formatter
public static final FormatStyle
HIGHLIGHT

Syntax highlighting via ANSI escape codes

private final String
public static final FormatStyle
NONE

No formatting

Constructor Summary

AccessConstructor and Description
private
FormatStyle(String name, Formatter formatter)

Method Summary

Modifier and TypeMethod and Description
public Formatter
public String
public static FormatStyle
public static FormatStyle[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

BASICback to summary
public static final FormatStyle BASIC

Formatting for SELECT, INSERT, UPDATE and DELETE statements

DDLback to summary
public static final FormatStyle DDL

Formatting for DDL (CREATE, ALTER, DROP, etc) statements

formatterback to summary
private final Formatter formatter
HIGHLIGHTback to summary
public static final FormatStyle HIGHLIGHT

Syntax highlighting via ANSI escape codes

nameback to summary
private final String name

Hides java.lang.Enum.name.

NONEback to summary
public static final FormatStyle NONE

No formatting

Constructor Detail

FormatStyleback to summary
private FormatStyle(String name, Formatter formatter)

Method Detail

getFormatterback to summary
public Formatter getFormatter()
getNameback to summary
public String getName()
valueOfback to summary
public static FormatStyle valueOf(String name)
valuesback to summary
public static FormatStyle[] values()
org.hibernate.engine.jdbc.internal back to summary

private Class FormatStyle.NoFormatImpl

extends Object
implements Formatter
Class Inheritance
All Implemented Interfaces
org.hibernate.engine.jdbc.internal.Formatter

Field Summary

Modifier and TypeField and Description
public static final FormatStyle.NoFormatImpl
INSTANCE

Singleton access

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public String
format(String
The original SQL string
source
)

Implements org.hibernate.engine.jdbc.internal.Formatter.format.

Format the source SQL string.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

INSTANCEback to summary
public static final FormatStyle.NoFormatImpl INSTANCE

Singleton access

Constructor Detail

NoFormatImplback to summary
private NoFormatImpl()

Method Detail

formatback to summary
public String format(String source)

Implements org.hibernate.engine.jdbc.internal.Formatter.format.

Doc from org.hibernate.engine.jdbc.internal.Formatter.format.

Format the source SQL string.

Parameters
source:String

The original SQL string

Returns:String

The formatted version