Top Inners Fields Constructors Methods
org.jooq.impl

pack-priv final Class LoaderImpl<R extends org.jooq.Record>

extends Object
implements LoaderOptionsStep<R extends Record>, LoaderRowsStep<R extends Record>, LoaderXMLStep<R extends Record>, LoaderCSVStep<R extends Record>, LoaderCSVOptionsStep<R extends Record>, LoaderJSONStep<R extends Record>, LoaderJSONOptionsStep<R extends Record>, Loader<R extends Record>
Class Inheritance
All Implemented Interfaces
org.jooq.Loader, org.jooq.LoaderJSONOptionsStep, org.jooq.LoaderListenerStep, org.jooq.LoaderLoadStep, org.jooq.LoaderJSONStep, org.jooq.LoaderCSVOptionsStep, org.jooq.LoaderCSVStep, org.jooq.LoaderXMLStep, org.jooq.LoaderRowsStep, org.jooq.LoaderOptionsStep, org.jooq.LoaderSourceStep
Static Imports
java.lang.Boolean.FALSE, org.jooq.SQLDialect.MARIADB, .SQLDialect.MYSQL, org.jooq.impl.Tools.EMPTY_FIELD, .Tools.combine, org.jooq.tools.jdbc.JDBCUtils.safeClose

Authors
Lukas Eder, Johannes Bühler

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class
LoaderImpl.CachedPS

Deprecated as a consequence of DefaultPreparedStatement being deprecated.
private static class
private class

Field Summary

Modifier and TypeField and Description
private Iterator<? extends Object[]>
private int
private static final int
private static final int
private static final int
private int
private int
private static final int
private static final int
private static final int
private int
private int
private static final int
private static final int
private static final int
private int
private final Configuration
private int
private static final int
private static final int
private static final int
private static final int
private final List<LoaderError>
private int
private LoaderFieldMapper
private Field<?>[]
fields

Deprecated as a consequence of Field being deprecated.
private boolean
private int
private int
private Source
private static final JooqLogger
private static final Set<SQLDialect>
private String
private static final int
private static final int
private static final int
private static final int
private static final int
private int
private int
private LoaderRowListener
private LoaderRowListener
private BitSet
private int
private char
private final LoaderContext
private char
private Field<?>[]
source

Deprecated as a consequence of Field being deprecated.
private int
private final Table<R>
private int
private int

Constructor Summary

AccessConstructor and Description
pack-priv
LoaderImpl(Configuration configuration, Table<R> table)

Method Summary

Modifier and TypeMethod and Description
private final <T> void
addValue0(InsertQuery<R> insert, Field<T> field, Object row)

Deprecated as a consequence of InsertQuery and Field being deprecated.
Type-safety...
private final <T> void
addValueForUpdate0(InsertQuery<R> insert, Field<T> field, Object row)

Deprecated as a consequence of InsertQuery and Field being deprecated.
Type-safety...
public final LoaderImpl<R>
batchAfter(int
The number of records that are batched together.
number
)

Implements org.jooq.LoaderOptionsStep.batchAfter.

Batch a given number of bulk statements together.
public final LoaderImpl<R>
batchAll()

Implements org.jooq.LoaderOptionsStep.batchAll.

Batch all bulk statements in one JDBC batch statement.
public final LoaderImpl<R>
batchNone()

Implements org.jooq.LoaderOptionsStep.batchNone.

Do not batch bulk statements together.
public final LoaderImpl<R>
bulkAfter(int
The number of records that are put together in one bulk statement.
number
)

Implements org.jooq.LoaderOptionsStep.bulkAfter.

Bulk-insert a given number of statements in a single multi-row bulk statement.
public final LoaderImpl<R>
bulkAll()

Implements org.jooq.LoaderOptionsStep.bulkAll.

Bulk-insert all rows in a single multi-row bulk statement.
public final LoaderImpl<R>
bulkNone()

Implements org.jooq.LoaderOptionsStep.bulkNone.

Do not bulk-insert rows in multi-row bulk statements.
private final void
private final void
public final LoaderImpl<R>
commitAfter(int
The number of records that are committed together.
number
)

Implements org.jooq.LoaderOptionsStep.commitAfter.

Commit after a certain number of batches.
public final LoaderImpl<R>
commitAll()

Implements org.jooq.LoaderOptionsStep.commitAll.

Commit only after inserting all batches.
public final LoaderImpl<R>
commitEach()

Implements org.jooq.LoaderOptionsStep.commitEach.

Commit each batch.
public final LoaderImpl<R>
commitNone()

Implements org.jooq.LoaderOptionsStep.commitNone.

Leave committing / rollbacking up to client code.
public final List<LoaderError>
errors()

Implements org.jooq.Loader.errors.

A list of errors that might have happened during the load.
public final LoaderImpl<R>
execute()

Implements org.jooq.LoaderLoadStep.execute.

Execute the load.
private final void
public final int
executed()

Implements org.jooq.Loader.executed.

The number of executed statements, bulk statements, or batch statements.
private final void
private final void
private final void
executeSQL(final Iterator<? extends Object[]> iterator)

private final void
executeSQL(Iterator<? extends Object[]> iterator, DSLContext ctx)

public final LoaderImpl<R>
fields(Field<?>... f)

Implements org.jooq.LoaderRowsStep.fields, org.jooq.LoaderCSVStep.fields, org.jooq.LoaderJSONStep.fields.

Deprecated as a consequence of Field being deprecated.
Specify the the fields to be loaded into the table in the correct order.
public final LoaderImpl<R>
fields(Collection<? extends Field<?>> f)

Implements org.jooq.LoaderRowsStep.fields, org.jooq.LoaderCSVStep.fields, org.jooq.LoaderJSONStep.fields.

Specify the the fields to be loaded into the table in the correct order.
public final LoaderImpl<R>
fields(LoaderFieldMapper mapper)

Implements org.jooq.LoaderRowsStep.fields, org.jooq.LoaderCSVStep.fields, org.jooq.LoaderJSONStep.fields.

Specify a function to apply on each input field to receive the target table's field.
private final void
fields0(Object[] row)

public LoaderImpl<R>
fieldsCorresponding()

Implements org.jooq.LoaderRowsStep.fieldsCorresponding, org.jooq.LoaderCSVStep.fieldsCorresponding, org.jooq.LoaderJSONStep.fieldsCorresponding.

Indicate that all input fields which have a corresponding field in the target table (with the same name) should be loaded.
public LoaderImpl<R>
fieldsFromSource()

Implements org.jooq.LoaderRowsStep.fieldsFromSource, org.jooq.LoaderCSVStep.fieldsFromSource, org.jooq.LoaderJSONStep.fieldsFromSource.

Deprecated
Indicate that all input fields which have a corresponding field in the target table (with the same name) should be loaded.
public final int
ignored()

Implements org.jooq.Loader.ignored.

The number of ignored rows.
public final LoaderImpl<R>
ignoreRows(int
The number of rows to ignore.
number
)

Implements org.jooq.LoaderCSVOptionsStep.ignoreRows, org.jooq.LoaderJSONOptionsStep.ignoreRows.

Specify that a certain number of rows should be ignored from the CSV file.
public final LoaderRowsStep<R>
loadArrays(Object[]... a)

Implements org.jooq.LoaderSourceStep.loadArrays.

Load in-memory data.
public final LoaderRowsStep<R>
loadArrays(Iterable<? extends Object[]> a)

Implements org.jooq.LoaderSourceStep.loadArrays.

Load in-memory data.
public final LoaderRowsStep<R>
loadArrays(Iterator<? extends Object[]> a)

Implements org.jooq.LoaderSourceStep.loadArrays.

Load in-memory data.
public final LoaderRowsStep<R>
loadArrays(Stream<? extends Object[]> a)

Implements org.jooq.LoaderSourceStep.loadArrays.

Load in-memory data.
public final LoaderImpl<R>
loadCSV(File file)

Implements org.jooq.LoaderSourceStep.loadCSV.

Load CSV data.
public final LoaderImpl<R>
loadCSV(File file, String charsetName)

Implements org.jooq.LoaderSourceStep.loadCSV.

Load CSV data.
public final LoaderImpl<R>
loadCSV(File file, Charset cs)

Implements org.jooq.LoaderSourceStep.loadCSV.

Load CSV data.
public final LoaderImpl<R>
loadCSV(File file, CharsetDecoder dec)

Implements org.jooq.LoaderSourceStep.loadCSV.

Load CSV data.
public final LoaderImpl<R>
loadCSV(String csv)

Implements org.jooq.LoaderSourceStep.loadCSV.

Load CSV data.
public final LoaderImpl<R>
loadCSV(InputStream stream)

Implements org.jooq.LoaderSourceStep.loadCSV.

Load CSV data.
public final LoaderImpl<R>
loadCSV(InputStream stream, String charsetName)

Implements org.jooq.LoaderSourceStep.loadCSV.

Load CSV data.
public final LoaderImpl<R>
loadCSV(InputStream stream, Charset cs)

Implements org.jooq.LoaderSourceStep.loadCSV.

Load CSV data.
public final LoaderImpl<R>
public final LoaderImpl<R>
loadCSV(Reader reader)

Implements org.jooq.LoaderSourceStep.loadCSV.

Load CSV data.
public final LoaderImpl<R>
loadCSV(Source s)

Implements org.jooq.LoaderSourceStep.loadCSV.

Load CSV data.
public final LoaderImpl<R>
loadJSON(File file)

Implements org.jooq.LoaderSourceStep.loadJSON.

Load JSON data.
public final LoaderImpl<R>
loadJSON(File file, String charsetName)

Implements org.jooq.LoaderSourceStep.loadJSON.

Load JSON data.
public final LoaderImpl<R>
loadJSON(File file, Charset cs)

Implements org.jooq.LoaderSourceStep.loadJSON.

Load JSON data.
public final LoaderImpl<R>
loadJSON(File file, CharsetDecoder dec)

Implements org.jooq.LoaderSourceStep.loadJSON.

Load JSON data.
public final LoaderImpl<R>
loadJSON(String json)

Implements org.jooq.LoaderSourceStep.loadJSON.

Load JSON data.
public final LoaderImpl<R>
loadJSON(InputStream stream)

Implements org.jooq.LoaderSourceStep.loadJSON.

Load JSON data.
public final LoaderImpl<R>
loadJSON(InputStream stream, String charsetName)

Implements org.jooq.LoaderSourceStep.loadJSON.

Load JSON data.
public final LoaderImpl<R>
loadJSON(InputStream stream, Charset cs)

Implements org.jooq.LoaderSourceStep.loadJSON.

Load JSON data.
public final LoaderImpl<R>
public final LoaderImpl<R>
loadJSON(Reader reader)

Implements org.jooq.LoaderSourceStep.loadJSON.

Load JSON data.
public final LoaderImpl<R>
loadJSON(Source s)

Implements org.jooq.LoaderSourceStep.loadJSON.

Load JSON data.
public final LoaderRowsStep<R>
loadRecords(Record... records)

Implements org.jooq.LoaderSourceStep.loadRecords.

Load in-memory data.
public final LoaderRowsStep<R>
loadRecords(Iterable<? extends Record> records)

Implements org.jooq.LoaderSourceStep.loadRecords.

Load in-memory data.
public final LoaderRowsStep<R>
loadRecords(Iterator<? extends Record> records)

Implements org.jooq.LoaderSourceStep.loadRecords.

Load in-memory data.
public final LoaderRowsStep<R>
loadRecords(Stream<? extends Record> records)

Implements org.jooq.LoaderSourceStep.loadRecords.

Load in-memory data.
public final LoaderImpl<R>
loadXML(File file)

Implements org.jooq.LoaderSourceStep.loadXML.

Load XML data.
public final LoaderImpl<R>
loadXML(File file, String charsetName)

Implements org.jooq.LoaderSourceStep.loadXML.

Load XML data.
public final LoaderImpl<R>
loadXML(File file, Charset cs)

Implements org.jooq.LoaderSourceStep.loadXML.

Load XML data.
public final LoaderImpl<R>
loadXML(File file, CharsetDecoder dec)

Implements org.jooq.LoaderSourceStep.loadXML.

Load XML data.
public final LoaderImpl<R>
loadXML(String xml)

Implements org.jooq.LoaderSourceStep.loadXML.

Load XML data.
public final LoaderImpl<R>
loadXML(InputStream stream)

Implements org.jooq.LoaderSourceStep.loadXML.

Load XML data.
public final LoaderImpl<R>
loadXML(InputStream stream, String charsetName)

Implements org.jooq.LoaderSourceStep.loadXML.

Load XML data.
public final LoaderImpl<R>
loadXML(InputStream stream, Charset cs)

Implements org.jooq.LoaderSourceStep.loadXML.

Load XML data.
public final LoaderImpl<R>
public final LoaderImpl<R>
loadXML(Reader reader)

Implements org.jooq.LoaderSourceStep.loadXML.

Load XML data.
public final LoaderImpl<R>
public final LoaderImpl<R>
loadXML(Source s)

Implements org.jooq.LoaderSourceStep.loadXML.

Load XML data.
public final LoaderImpl<R>
nullString(String n)

Implements org.jooq.LoaderCSVOptionsStep.nullString.

Specify the input string representation of NULL.
public final LoaderImpl<R>
onDuplicateKeyError()

Implements org.jooq.LoaderOptionsStep.onDuplicateKeyError.

Instruct the Loader to cause an error in loading if there are any duplicate records.
public final LoaderImpl<R>
onDuplicateKeyIgnore()

Implements org.jooq.LoaderOptionsStep.onDuplicateKeyIgnore.

Instruct the Loader to skip duplicate records if any of the unique keys' values are already in the database.
public final LoaderImpl<R>
onDuplicateKeyUpdate()

Implements org.jooq.LoaderOptionsStep.onDuplicateKeyUpdate.

Instruct the Loader to update duplicate records if any of the unique keys' values are already in the database.
public final LoaderImpl<R>
onErrorAbort()

Implements org.jooq.LoaderOptionsStep.onErrorAbort.

Instruct the Loader to abort loading after the first error that might occur when inserting a record.
public final LoaderImpl<R>
onErrorIgnore()

Implements org.jooq.LoaderOptionsStep.onErrorIgnore.

Instruct the Loader to ignore any errors that might occur when inserting a record.
public final LoaderImpl<R>
onRow(LoaderRowListener l)

Implements org.jooq.LoaderListenerStep.onRow.

Specify a listener that is invoked whenever a row has been processed.
public final LoaderImpl<R>
onRowEnd(LoaderRowListener l)

Implements org.jooq.LoaderListenerStep.onRowEnd.

Specify a listener that is invoked after a row has been processed.
public final LoaderImpl<R>
onRowStart(LoaderRowListener l)

Implements org.jooq.LoaderListenerStep.onRowStart.

Specify a listener that is invoked before a row is processed.
public final int
processed()

Implements org.jooq.Loader.processed.

The number of processed rows.
public final LoaderImpl<R>
quote(char q)

Implements org.jooq.LoaderCSVOptionsStep.quote.

Specify the quote character.
public final LoaderContext
result()

Implements org.jooq.Loader.result.

The results that are also returned from Loader.
private final void
public final LoaderImpl<R>
separator(char s)

Implements org.jooq.LoaderCSVOptionsStep.separator.

Specify the separator character.
public final int
stored()

Implements org.jooq.Loader.stored.

The number of inserted or updated rows.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait