- java.lang.Object
-
- org.jooq.XMLFormat
-
public final class XMLFormat extends Object
An XML formatting type, which can be used to configure XML imports / exports.- Author:
- Lukas Eder
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
XMLFormat.RecordFormat
The format of individual XML records.
-
Field Summary
Fields Modifier and Type Field Description static XMLFormat
DEFAULT_FOR_RECORDS
static XMLFormat
DEFAULT_FOR_RESULTS
-
Constructor Summary
Constructors Constructor Description XMLFormat()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
format()
The formatting flag.XMLFormat
format(boolean newFormat)
The new value for the formatting flag, defaulting tofalse
.boolean
header()
The header.XMLFormat
header(boolean newHeader)
The new header value, defaulting totrue
.int
indent()
The indentation.XMLFormat
indent(int newIndent)
The new indentation value, defaulting to2
.String
indentString(int level)
Convenience method to get an indentation string at a given level.String
newline()
The formatting flag.XMLFormat
newline(String newNewline)
The new newline character, defaulting to\n
.XMLFormat.RecordFormat
recordFormat()
The record format to be applied, defaulting toXMLFormat.RecordFormat.VALUE_ELEMENTS_WITH_FIELD_ATTRIBUTE
.XMLFormat
recordFormat(XMLFormat.RecordFormat newRecordFormat)
The record format to be applied, defaulting toXMLFormat.RecordFormat.VALUE_ELEMENTS_WITH_FIELD_ATTRIBUTE
.boolean
xmlns()
The xmlns flag.XMLFormat
xmlns(boolean newXmlns)
The new value for the xmlns flag, defaulting totrue
.
-
-
-
Method Detail
-
xmlns
public XMLFormat xmlns(boolean newXmlns)
The new value for the xmlns flag, defaulting totrue
.
-
xmlns
public boolean xmlns()
The xmlns flag.
-
format
public XMLFormat format(boolean newFormat)
The new value for the formatting flag, defaulting tofalse
.
-
format
public boolean format()
The formatting flag.
-
newline
public String newline()
The formatting flag.
-
indent
public XMLFormat indent(int newIndent)
The new indentation value, defaulting to2
.
-
indent
public int indent()
The indentation.
-
indentString
public String indentString(int level)
Convenience method to get an indentation string at a given level.
-
header
public XMLFormat header(boolean newHeader)
The new header value, defaulting totrue
.This flag governs whether the
/result/fields element should be generated on export.
This flag is ignored on
Formattable.formatXML(XMLFormat)
and similar methods.
-
header
public boolean header()
The header.
-
recordFormat
public XMLFormat recordFormat(XMLFormat.RecordFormat newRecordFormat)
The record format to be applied, defaulting toXMLFormat.RecordFormat.VALUE_ELEMENTS_WITH_FIELD_ATTRIBUTE
.
-
recordFormat
public XMLFormat.RecordFormat recordFormat()
The record format to be applied, defaulting toXMLFormat.RecordFormat.VALUE_ELEMENTS_WITH_FIELD_ATTRIBUTE
.
-
-