- java.lang.Object
-
- org.jooq.impl.UDTRecordImpl<R>
-
- All Implemented Interfaces:
Serializable
,Comparable<Record>
,SQLData
,Attachable
,Formattable
,Record
,UDTRecord<R>
@Internal public class UDTRecordImpl<R extends UDTRecord<R>> extends Object implements UDTRecord<R>
A record implementation for a record originating from a single UDTThis type is for JOOQ INTERNAL USE only. Do not reference directly
- Author:
- Lukas Eder
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description UDTRecordImpl(UDT<R> udt)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
attach(Configuration c)
Attach this object to a newConfiguration
.boolean
changed()
Check if this record has been changed from its original as fetched from the database.void
changed(boolean c)
Set all of this record's internal changed flags to the supplied value.boolean
changed(int fieldIndex)
Check if a field's value has been changed from its original as fetched from the database.void
changed(int fieldIndex, boolean c)
Set this record's internal changed flag to the supplied value for a given field.boolean
changed(String fieldName)
Check if a field's value has been changed from its original as fetched from the database.void
changed(String fieldName, boolean c)
Set this record's internal changed flag to the supplied value for a given field.boolean
changed(Field<?> field)
Check if a field's value has been changed from its original as fetched from the database.void
changed(Field<?> field, boolean c)
Set this record's internal changed flag to the supplied value for a given field.boolean
changed(Name fieldName)
Check if a field's value has been changed from its original as fetched from the database.void
changed(Name fieldName, boolean c)
Set this record's internal changed flag to the supplied value for a given field.int
compareTo(Record that)
Compares thisRecord
with anotherRecord
according to their natural ordering.Configuration
configuration()
protected DSLContext
create()
Deprecated.- 3.11.0 - [#6720] [#6721] - UseAttachable.configuration()
andConfiguration.dsl()
instead.void
detach()
Detach this object from its currentConfiguration
.boolean
equals(Object obj)
Field<?>
field(int index)
Get a specific field from this Record.Field<?>
field(String name)
Get a specific field from this Record.<T> Field<T>
field(Field<T> field)
Get a specific field from this Record.Field<?>
field(Name name)
Get a specific qualified field from this Record.Field<?>[]
fields()
Get all fields from this Record.Field<?>[]
fields(int... fieldIndexes)
Get all fields from this Record, providing some field indexes.Field<?>[]
fields(String... fieldNames)
Get all fields from this Record, providing some field names.Field<?>[]
fields(Field<?>... f)
Get all fields from this Record, providing some fields.Field<?>[]
fields(Name... fieldNames)
Get all fields from this Record, providing some field names.Row
fieldsRow()
Get this record's fields as aRow
.String
format()
Get a simple formatted representation of this result.String
format(int maxRecords)
Get a simple formatted representation of this result.void
format(OutputStream stream)
LikeFormattable.format()
, but the data is output onto anOutputStream
.void
format(OutputStream stream, int maxRecords)
LikeFormattable.format(int)
, but the data is output onto anOutputStream
.void
format(OutputStream stream, TXTFormat format)
LikeFormattable.format(TXTFormat)
, but the data is output onto anOutputStream
.void
format(Writer writer)
LikeFormattable.format()
, but the data is output onto aWriter
.void
format(Writer writer, int maxRecords)
LikeFormattable.format(int)
, but the data is output onto aWriter
.void
format(Writer writer, TXTFormat format)
LikeFormattable.format(TXTFormat)
, but the data is output onto aWriter
.String
format(TXTFormat format)
Get a simple formatted representation of this result.String
formatChart()
void
formatChart(OutputStream stream)
LikeFormattable.formatChart()
, but the data is output onto anOutputStream
.void
formatChart(OutputStream stream, ChartFormat format)
LikeFormattable.formatChart(ChartFormat)
, but the data is output onto anOutputStream
.void
formatChart(Writer writer)
LikeFormattable.formatChart()
, but the data is output onto aWriter
.void
formatChart(Writer writer, ChartFormat format)
LikeFormattable.formatChart(ChartFormat)
, but the data is output onto aWriter
.String
formatChart(ChartFormat format)
String
formatCSV()
Get a simple formatted representation of this result as CSV.String
formatCSV(boolean header)
Get a simple formatted representation of this result as CSV.String
formatCSV(boolean header, char delimiter)
Get a simple formatted representation of this result as CSV.String
formatCSV(boolean header, char delimiter, String nullString)
Get a simple formatted representation of this result as CSV.String
formatCSV(char delimiter)
Get a simple formatted representation of this result as CSV.String
formatCSV(char delimiter, String nullString)
Get a simple formatted representation of this result as CSV.void
formatCSV(OutputStream stream)
LikeFormattable.formatCSV()
, but the data is output onto anOutputStream
.void
formatCSV(OutputStream stream, boolean header)
LikeFormattable.formatCSV(boolean)
, but the data is output onto anOutputStream
.void
formatCSV(OutputStream stream, boolean header, char delimiter)
LikeFormattable.formatCSV(boolean, char)
, but the data is output onto anOutputStream
.void
formatCSV(OutputStream stream, boolean header, char delimiter, String nullString)
LikeFormattable.formatCSV(boolean, char, String)
, but the data is output onto anOutputStream
.void
formatCSV(OutputStream stream, char delimiter)
LikeFormattable.formatCSV(char)
, but the data is output onto anOutputStream
.void
formatCSV(OutputStream stream, char delimiter, String nullString)
LikeFormattable.formatCSV(char, String)
, but the data is output onto anOutputStream
.void
formatCSV(OutputStream stream, CSVFormat format)
LikeFormattable.formatCSV(CSVFormat)
, but the data is output onto anOutputStream
.void
formatCSV(Writer writer)
LikeFormattable.formatCSV()
, but the data is output onto aWriter
.void
formatCSV(Writer writer, boolean header)
LikeFormattable.formatCSV(boolean)
, but the data is output onto aWriter
.void
formatCSV(Writer writer, boolean header, char delimiter)
LikeFormattable.formatCSV(boolean, char)
, but the data is output onto aWriter
.void
formatCSV(Writer writer, boolean header, char delimiter, String nullString)
LikeFormattable.formatCSV(boolean, char, String)
, but the data is output onto aWriter
.void
formatCSV(Writer writer, char delimiter)
LikeFormattable.formatCSV(char)
, but the data is output onto aWriter
.void
formatCSV(Writer writer, char delimiter, String nullString)
LikeFormattable.formatCSV(char, String)
, but the data is output onto aWriter
.void
formatCSV(Writer writer, CSVFormat format)
LikeFormattable.formatCSV(CSVFormat)
, but the data is output onto aWriter
.String
formatCSV(CSVFormat format)
Get a simple formatted representation of this result as CSV.String
formatHTML()
Get a simple formatted representation of this result as HTML.void
formatHTML(OutputStream stream)
LikeFormattable.formatHTML()
, but the data is output onto anOutputStream
.void
formatHTML(Writer writer)
LikeFormattable.formatHTML()
, but the data is output onto aWriter
.String
formatInsert()
Get this result as a set ofINSERT
statements.void
formatInsert(OutputStream stream)
LikeFormattable.formatInsert()
, but the data is output onto anOutputStream
.void
formatInsert(OutputStream stream, Table<?> table, Field<?>... f)
LikeFormattable.formatInsert(Table, Field...)
, but the data is output onto anOutputStream
.void
formatInsert(Writer writer)
LikeFormattable.formatInsert()
, but the data is output onto aWriter
.void
formatInsert(Writer writer, Table<?> table, Field<?>... f)
LikeFormattable.formatInsert(Table, Field...)
, but the data is output onto anWriter
.String
formatInsert(Table<?> table, Field<?>... f)
Get this result as a set ofINSERT
statements.String
formatJSON()
Get a simple formatted representation of this result as a JSON array of array.void
formatJSON(OutputStream stream)
LikeFormattable.formatJSON()
, but the data is output onto anOutputStream
.void
formatJSON(OutputStream stream, JSONFormat format)
LikeFormattable.formatJSON(JSONFormat)
, but the data is output onto anOutputStream
.void
formatJSON(Writer writer)
LikeFormattable.formatJSON()
, but the data is output onto aWriter
.void
formatJSON(Writer writer, JSONFormat format)
LikeFormattable.formatJSON(JSONFormat)
, but the data is output onto aWriter
.String
formatJSON(JSONFormat format)
Get a simple formatted representation of this result as a JSON data structure, according to the format.String
formatXML()
Get this result formatted as XML.void
formatXML(OutputStream stream)
LikeFormattable.formatXML()
, but the data is output onto anOutputStream
.void
formatXML(OutputStream stream, XMLFormat format)
LikeFormattable.formatXML(XMLFormat)
, but the data is output onto anOutputStream
.void
formatXML(Writer writer)
LikeFormattable.formatXML()
, but the data is output onto aWriter
.void
formatXML(Writer writer, XMLFormat format)
LikeFormattable.formatXML(XMLFormat)
, but the data is output onto aWriter
.String
formatXML(XMLFormat format)
Get this result formatted as XML.void
from(Object source)
Load data into this record from a source.void
from(Object source, int... fieldIndexes)
Load data into this record from a source, providing some field indexes.void
from(Object source, String... fieldNames)
Load data into this record from a source, providing some field names.void
from(Object source, Field<?>... f)
Load data into this record from a source, providing some fields.void
from(Object source, Name... fieldNames)
Load data into this record from a source, providing some field names.protected void
from(Record source)
This method was implemented with [#799].void
fromArray(Object... array)
Load data from an array into this record.void
fromArray(Object[] array, int... fieldIndexes)
Load data from an array into this record, providing some fields indexes.void
fromArray(Object[] array, String... fieldNames)
Load data from an array into this record, providing some fields names.void
fromArray(Object[] array, Field<?>... f)
Load data from an array into this record, providing some fields.void
fromArray(Object[] array, Name... fieldNames)
Load data from an array into this record, providing some fields names.void
fromMap(Map<String,?> map)
Load data from a map into this record.void
fromMap(Map<String,?> map, int... fieldIndexes)
Load data from a map into this record, providing some field indexes.void
fromMap(Map<String,?> map, String... fieldNames)
Load data from a map into this record, providing some field names.void
fromMap(Map<String,?> map, Field<?>... f)
Load data from a map into this record, providing some fields.void
fromMap(Map<String,?> map, Name... fieldNames)
Load data from a map into this record, providing some field names.Object
get(int index)
Get a value from this record, providing a field index.<T> T
get(int index, Class<? extends T> type)
Get a converted value from this record, providing a field index.<U> U
get(int index, Converter<?,? extends U> converter)
Get a converted value from this record, providing a field index.Object
get(String fieldName)
Get a value from this Record, providing a field name.<T> T
get(String fieldName, Class<? extends T> type)
Get a converted value from this Record, providing a field name.<U> U
get(String fieldName, Converter<?,? extends U> converter)
Get a converted value from this Record, providing a field name.<T> T
get(Field<?> field, Class<? extends T> type)
Get a converted value from this Record, providing a field.<T> T
get(Field<T> field)
Get a value from this Record, providing a field.<T,U>
Uget(Field<T> field, Converter<? super T,? extends U> converter)
Get a converted value from this Record, providing a field.Object
get(Name fieldName)
Get a value from this Record, providing a field name.<T> T
get(Name fieldName, Class<? extends T> type)
Get a converted value from this Record, providing a field name.<U> U
get(Name fieldName, Converter<?,? extends U> converter)
Get a converted value from this Record, providing a field name.String
getSQLTypeName()
UDT<R>
getUDT()
The UDT from which this record was readObject
getValue(int index)
Get a value from this record, providing a field index.<T> T
getValue(int index, Class<? extends T> type)
Get a converted value from this record, providing a field index.<T> T
getValue(int index, Class<? extends T> type, T defaultValue)
Deprecated.Object
getValue(int index, Object defaultValue)
Deprecated.<U> U
getValue(int index, Converter<?,? extends U> converter)
Get a converted value from this record, providing a field index.<U> U
getValue(int index, Converter<?,? extends U> converter, U defaultValue)
Deprecated.Object
getValue(String fieldName)
Get a value from this Record, providing a field name.<T> T
getValue(String fieldName, Class<? extends T> type)
Get a converted value from this Record, providing a field name.<T> T
getValue(String fieldName, Class<? extends T> type, T defaultValue)
Deprecated.Object
getValue(String fieldName, Object defaultValue)
Deprecated.<U> U
getValue(String fieldName, Converter<?,? extends U> converter)
Get a converted value from this Record, providing a field name.<U> U
getValue(String fieldName, Converter<?,? extends U> converter, U defaultValue)
Deprecated.<T> T
getValue(Field<?> field, Class<? extends T> type)
Get a converted value from this Record, providing a field.<T> T
getValue(Field<?> field, Class<? extends T> type, T defaultValue)
Deprecated.<T> T
getValue(Field<T> field)
Get a value from this Record, providing a field.<T,U>
UgetValue(Field<T> field, Converter<? super T,? extends U> converter)
Get a converted value from this Record, providing a field.<T,U>
UgetValue(Field<T> field, Converter<? super T,? extends U> converter, U defaultValue)
Deprecated.<T> T
getValue(Field<T> field, T defaultValue)
Deprecated.Object
getValue(Name fieldName)
Get a value from this Record, providing a field name.<T> T
getValue(Name fieldName, Class<? extends T> type)
Get a converted value from this Record, providing a field name.<U> U
getValue(Name fieldName, Converter<?,? extends U> converter)
Get a converted value from this Record, providing a field name.int
hashCode()
int
indexOf(String fieldName)
Get a field's index from this record.int
indexOf(Field<?> field)
Get a field's index from this record.int
indexOf(Name fieldName)
Get a field's index from this record.<E> E
into(E object)
Map resulting records onto a custom type.<E> E
into(Class<? extends E> type)
Map resulting records onto a custom type.Record
into(Field<?>... f)
Copy this record into a new record holding only a subset of the previous fields.<T1> Record1<T1>
into(Field<T1> field1)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2>
Record2<T1,T2>into(Field<T1> field1, Field<T2> field2)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3>
Record3<T1,T2,T3>into(Field<T1> field1, Field<T2> field2, Field<T3> field3)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4>
Record4<T1,T2,T3,T4>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5>
Record5<T1,T2,T3,T4,T5>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6>
Record6<T1,T2,T3,T4,T5,T6>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7>
Record7<T1,T2,T3,T4,T5,T6,T7>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8>
Record8<T1,T2,T3,T4,T5,T6,T7,T8>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9>
Record9<T1,T2,T3,T4,T5,T6,T7,T8,T9>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10>
Record10<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11>
Record11<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12>
Record12<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13>
Record13<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14>
Record14<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15>
Record15<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16>
Record16<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17>
Record17<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18>
Record18<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17, Field<T18> field18)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19>
Record19<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17, Field<T18> field18, Field<T19> field19)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20>
Record20<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17, Field<T18> field18, Field<T19> field19, Field<T20> field20)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21>
Record21<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17, Field<T18> field18, Field<T19> field19, Field<T20> field20, Field<T21> field21)
Copy this record into a new record holding only a subset of the previous fields.<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21,T22>
Record22<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21,T22>into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17, Field<T18> field18, Field<T19> field19, Field<T20> field20, Field<T21> field21, Field<T22> field22)
Copy this record into a new record holding only a subset of the previous fields.<R extends Record>
Rinto(Table<R> table)
Map resulting records onto a custom record type.Object[]
intoArray()
Convert this record into an array.List<Object>
intoList()
Convert this record into a list.Map<String,Object>
intoMap()
Return this record as a name/value map.ResultSet
intoResultSet()
Generate an in-memory JDBCResultSet
containing the data of thisRecord
.Stream<Object>
intoStream()
Convert this record into a stream.Document
intoXML()
Get this result as XML.<H extends ContentHandler>
HintoXML(H handler)
Get this result as XML using a SAXContentHandler
.<H extends ContentHandler>
HintoXML(H handler, XMLFormat format)
Get this result as XML using a SAXContentHandler
.Document
intoXML(XMLFormat format)
Get this result as XML.<E> E
map(RecordMapper<Record,E> mapper)
Map this record into a custom mapper callback.Record
original()
Get this record containing the original values as fetched from the database.Object
original(int fieldIndex)
Get an original value from this record as fetched from the database.Object
original(String fieldName)
Get an original value from this record as fetched from the database.<T> T
original(Field<T> field)
Get an original value from this record as fetched from the database.Object
original(Name fieldName)
Get an original value from this record as fetched from the database.void
readSQL(SQLInput stream, String typeName)
void
reset()
void
reset(int fieldIndex)
void
reset(String fieldName)
Reset a given value to itsRecord.original(String)
value and itsRecord.changed(String)
flag tofalse
.void
reset(Field<?> field)
Reset a given value to itsRecord.original(Field)
value and itsRecord.changed(Field)
flag tofalse
.void
reset(Name fieldName)
protected void
set(int index, Object value)
<T> void
set(Field<T> field, T value)
Set a value into this record.<T,U>
voidset(Field<T> field, U value, Converter<? extends T,? super U> converter)
Set a value into this record.protected void
setValue(int index, Object value)
Deprecated.- UseAbstractRecord.set(int, Object)
instead<T> void
setValue(Field<T> field, T value)
Set a value into this record.<T,U>
voidsetValue(Field<T> field, U value, Converter<? extends T,? super U> converter)
Set a value into this record.int
size()
Get the number of fields of this record.String
toString()
Row
valuesRow()
Get this record's values as aRow
.<T> R
with(Field<T> field, T value)
Set a value into this record.<T,U>
Rwith(Field<T> field, U value, Converter<? extends T,? super U> converter)
Set a value into this record.void
writeSQL(SQLOutput stream)
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.jooq.Attachable
attach, configuration, detach
-
Methods inherited from interface org.jooq.Formattable
format, format, format, format, format, format, format, format, format, formatChart, formatChart, formatChart, formatChart, formatChart, formatChart, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatCSV, formatHTML, formatHTML, formatHTML, formatInsert, formatInsert, formatInsert, formatInsert, formatInsert, formatInsert, formatJSON, formatJSON, formatJSON, formatJSON, formatJSON, formatJSON, formatXML, formatXML, formatXML, formatXML, formatXML, formatXML, intoXML, intoXML, intoXML, intoXML
-
Methods inherited from interface org.jooq.Record
changed, changed, changed, changed, changed, changed, changed, changed, changed, changed, compareTo, equals, field, field, field, field, fields, fields, fields, fields, fields, from, from, from, from, from, fromArray, fromArray, fromArray, fromArray, fromArray, fromMap, fromMap, fromMap, fromMap, fromMap, get, get, get, get, get, get, get, get, get, get, get, get, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, hashCode, indexOf, indexOf, indexOf, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, into, intoArray, intoList, intoMap, intoResultSet, intoStream, map, original, original, original, original, original, reset, reset, reset, reset, reset, set, set, setValue, setValue, size
-
-
-
-
Method Detail
-
getUDT
public final UDT<R> getUDT()
Description copied from interface:UDTRecord
The UDT from which this record was read
-
fieldsRow
public Row fieldsRow()
Description copied from interface:Record
Get this record's fields as aRow
.
-
valuesRow
public Row valuesRow()
Description copied from interface:Record
Get this record's values as aRow
.
-
getSQLTypeName
public final String getSQLTypeName() throws SQLException
- Specified by:
getSQLTypeName
in interfaceSQLData
- Throws:
SQLException
-
readSQL
public final void readSQL(SQLInput stream, String typeName) throws SQLException
- Specified by:
readSQL
in interfaceSQLData
- Throws:
SQLException
-
writeSQL
public final void writeSQL(SQLOutput stream) throws SQLException
- Specified by:
writeSQL
in interfaceSQLData
- Throws:
SQLException
-
with
public final <T> R with(Field<T> field, T value)
Description copied from interface:Record
Set a value into this record.Like
Record.set(Field, Object)
but returningthis
for fluent setting of multiple values.
-
with
public final <T,U> R with(Field<T> field, U value, Converter<? extends T,? super U> converter)
Description copied from interface:Record
Set a value into this record.Like
Record.set(Field, Object, Converter)
but returningthis
for fluent setting of multiple values.
-
toString
public String toString()
-
field
public final <T> Field<T> field(Field<T> field)
Description copied from interface:Record
Get a specific field from this Record.This will return:
- A field that is the same as the argument field (by identity comparison).
- A field that is equal to the argument field (exact matching fully qualified name).
- A field that is equal to the argument field (partially matching qualified name).
- A field whose name is equal to the name of the argument field.
null
otherwise.
- Specified by:
field
in interfaceRecord
- See Also:
Row.field(Field)
-
field
public final Field<?> field(String name)
Description copied from interface:Record
Get a specific field from this Record.- Specified by:
field
in interfaceRecord
- See Also:
Row.field(String)
-
field
public final Field<?> field(Name name)
Description copied from interface:Record
Get a specific qualified field from this Record.- Specified by:
field
in interfaceRecord
- See Also:
Row.field(Name)
-
field
public final Field<?> field(int index)
Description copied from interface:Record
Get a specific field from this Record.- Specified by:
field
in interfaceRecord
- See Also:
Row.field(int)
-
fields
public final Field<?>[] fields()
Description copied from interface:Record
Get all fields from this Record.- Specified by:
fields
in interfaceRecord
- See Also:
Row.fields()
-
fields
public final Field<?>[] fields(Field<?>... f)
Description copied from interface:Record
Get all fields from this Record, providing some fields.- Specified by:
fields
in interfaceRecord
- Returns:
- All available fields
- See Also:
Row.fields(Field...)
-
fields
public final Field<?>[] fields(String... fieldNames)
Description copied from interface:Record
Get all fields from this Record, providing some field names.- Specified by:
fields
in interfaceRecord
- Returns:
- All available fields
- See Also:
Row.fields(String...)
-
fields
public final Field<?>[] fields(Name... fieldNames)
Description copied from interface:Record
Get all fields from this Record, providing some field names.- Specified by:
fields
in interfaceRecord
- Returns:
- All available fields
- See Also:
Row.fields(Name...)
-
fields
public final Field<?>[] fields(int... fieldIndexes)
Description copied from interface:Record
Get all fields from this Record, providing some field indexes.- Specified by:
fields
in interfaceRecord
- Returns:
- All available fields
- See Also:
Row.fields(int...)
-
indexOf
public final int indexOf(Field<?> field)
Description copied from interface:Record
Get a field's index from this record.
-
indexOf
public final int indexOf(String fieldName)
Description copied from interface:Record
Get a field's index from this record.
-
indexOf
public final int indexOf(Name fieldName)
Description copied from interface:Record
Get a field's index from this record.
-
size
public final int size()
Description copied from interface:Record
Get the number of fields of this record.
-
get
public final <T> T get(Field<T> field)
Description copied from interface:Record
Get a value from this Record, providing a field.If this record contains a field with the same
Field.getName()
as the argument field, that value is retrieved.
-
get
public final <T> T get(Field<?> field, Class<? extends T> type)
Description copied from interface:Record
Get a converted value from this Record, providing a field.If this record contains a field with the same
Field.getName()
as the argument field, that value is retrieved.- Specified by:
get
in interfaceRecord
- Type Parameters:
T
- The conversion type parameter- Parameters:
field
- The fieldtype
- The conversion type- Returns:
- The value of a field contained in this record
- See Also:
Convert.convert(Object, Class)
-
get
public final <T,U> U get(Field<T> field, Converter<? super T,? extends U> converter)
Description copied from interface:Record
Get a converted value from this Record, providing a field.If this record contains a field with the same
Field.getName()
as the argument field, that value is retrieved.- Specified by:
get
in interfaceRecord
- Type Parameters:
T
- The database type parameterU
- The conversion type parameter- Parameters:
field
- The fieldconverter
- The data type converter- Returns:
- The value of a field contained in this record
- See Also:
Convert.convert(Object, Converter)
-
get
public final Object get(int index)
Description copied from interface:Record
Get a value from this record, providing a field index.
-
get
public final <T> T get(int index, Class<? extends T> type)
Description copied from interface:Record
Get a converted value from this record, providing a field index.- Specified by:
get
in interfaceRecord
- Type Parameters:
T
- The conversion type parameter- Parameters:
index
- The field's indextype
- The conversion type- Returns:
- The value of a field's index contained in this record
- See Also:
Convert.convert(Object, Class)
-
get
public final <U> U get(int index, Converter<?,? extends U> converter)
Description copied from interface:Record
Get a converted value from this record, providing a field index.- Specified by:
get
in interfaceRecord
- Type Parameters:
U
- The conversion type parameter- Parameters:
index
- The field's indexconverter
- The data type converter- Returns:
- The value of a field's index contained in this record
- See Also:
Convert.convert(Object, Converter)
-
get
public final Object get(String fieldName)
Description copied from interface:Record
Get a value from this Record, providing a field name.
-
get
public final <T> T get(String fieldName, Class<? extends T> type)
Description copied from interface:Record
Get a converted value from this Record, providing a field name.- Specified by:
get
in interfaceRecord
- Type Parameters:
T
- The conversion type parameter- Parameters:
fieldName
- The field's nametype
- The conversion type- Returns:
- The value of a field's name contained in this record
- See Also:
Convert.convert(Object, Class)
-
get
public final <U> U get(String fieldName, Converter<?,? extends U> converter)
Description copied from interface:Record
Get a converted value from this Record, providing a field name.- Specified by:
get
in interfaceRecord
- Type Parameters:
U
- The conversion type parameter- Parameters:
fieldName
- The field's nameconverter
- The data type converter- Returns:
- The value of a field's name contained in this record
- See Also:
Convert.convert(Object, Converter)
-
get
public final Object get(Name fieldName)
Description copied from interface:Record
Get a value from this Record, providing a field name.
-
get
public final <T> T get(Name fieldName, Class<? extends T> type)
Description copied from interface:Record
Get a converted value from this Record, providing a field name.- Specified by:
get
in interfaceRecord
- Type Parameters:
T
- The conversion type parameter- Parameters:
fieldName
- The field's nametype
- The conversion type- Returns:
- The value of a field's name contained in this record
- See Also:
Convert.convert(Object, Class)
-
get
public final <U> U get(Name fieldName, Converter<?,? extends U> converter)
Description copied from interface:Record
Get a converted value from this Record, providing a field name.- Specified by:
get
in interfaceRecord
- Type Parameters:
U
- The conversion type parameter- Parameters:
fieldName
- The field's nameconverter
- The data type converter- Returns:
- The value of a field's name contained in this record
- See Also:
Convert.convert(Object, Converter)
-
setValue
@Deprecated protected final void setValue(int index, Object value)
Deprecated.- UseAbstractRecord.set(int, Object)
insteadSubclasses may type-unsafely set a value to a record index. This method takes care of converting the value to the appropriate type.
-
set
protected final void set(int index, Object value)
-
set
public final <T> void set(Field<T> field, T value)
Description copied from interface:Record
Set a value into this record.This will always set the
Record.changed(Field)
flag for the givenfield
, no matter if setting the value actually changes the value.Changing
Table.getPrimaryKey()
values will set allRecord.changed()
flags to true, in order to produce completeINSERT
statements on subsequentUpdatableRecord.store()
operations.
-
set
public final <T,U> void set(Field<T> field, U value, Converter<? extends T,? super U> converter)
Description copied from interface:Record
Set a value into this record.This will always set the
Record.changed(Field)
flag for the givenfield
, no matter if setting the value actually changes the value.Changing
Table.getPrimaryKey()
values will set allRecord.changed()
flags to true, in order to produce completeINSERT
statements on subsequentUpdatableRecord.store()
operations.
-
original
public Record original()
Description copied from interface:Record
Get this record containing the original values as fetched from the database.Record values can be freely modified after having fetched a record from the database. Every record also references the originally fetched values. This method returns a new record containing those original values.
- Specified by:
original
in interfaceRecord
- See Also:
Record.original(Field)
,Record.original(int)
,Record.original(String)
-
original
public final <T> T original(Field<T> field)
Description copied from interface:Record
Get an original value from this record as fetched from the database.Record values can be freely modified after having fetched a record from the database. Every record also references the originally fetched values. This method returns such an original value for a field.
- Specified by:
original
in interfaceRecord
- See Also:
Record.original()
-
original
public final Object original(int fieldIndex)
Description copied from interface:Record
Get an original value from this record as fetched from the database.Record values can be freely modified after having fetched a record from the database. Every record also references the originally fetched values. This method returns such an original value for a field.
- Specified by:
original
in interfaceRecord
- See Also:
Record.original()
-
original
public final Object original(String fieldName)
Description copied from interface:Record
Get an original value from this record as fetched from the database.Record values can be freely modified after having fetched a record from the database. Every record also references the originally fetched values. This method returns such an original value for a field.
- Specified by:
original
in interfaceRecord
- See Also:
Record.original()
-
original
public final Object original(Name fieldName)
Description copied from interface:Record
Get an original value from this record as fetched from the database.Record values can be freely modified after having fetched a record from the database. Every record also references the originally fetched values. This method returns such an original value for a field.
- Specified by:
original
in interfaceRecord
- See Also:
Record.original()
-
changed
public final boolean changed()
Description copied from interface:Record
Check if this record has been changed from its original as fetched from the database.If this returns
false
, then it can be said thatrecord.equals(record.original())
is true.- Specified by:
changed
in interfaceRecord
- See Also:
Record.original()
,Record.changed(Field)
,Record.changed(int)
,Record.changed(String)
-
changed
public final boolean changed(Field<?> field)
Description copied from interface:Record
Check if a field's value has been changed from its original as fetched from the database.- Specified by:
changed
in interfaceRecord
- See Also:
Record.changed()
,Record.original(Field)
-
changed
public final boolean changed(int fieldIndex)
Description copied from interface:Record
Check if a field's value has been changed from its original as fetched from the database.- Specified by:
changed
in interfaceRecord
- See Also:
Record.changed()
,Record.original(int)
-
changed
public final boolean changed(String fieldName)
Description copied from interface:Record
Check if a field's value has been changed from its original as fetched from the database.- Specified by:
changed
in interfaceRecord
- See Also:
Record.changed()
,Record.original(String)
-
changed
public final boolean changed(Name fieldName)
Description copied from interface:Record
Check if a field's value has been changed from its original as fetched from the database.- Specified by:
changed
in interfaceRecord
- See Also:
Record.changed()
,Record.original(Name)
-
changed
public final void changed(boolean c)
Description copied from interface:Record
Set all of this record's internal changed flags to the supplied value.If the
changed
argument isfalse
, theRecord.original()
values will be reset to the corresponding "current" values as well- Specified by:
changed
in interfaceRecord
- See Also:
Record.changed()
,Record.changed(Field, boolean)
,Record.changed(int, boolean)
,Record.changed(String, boolean)
-
changed
public final void changed(Field<?> field, boolean c)
Description copied from interface:Record
Set this record's internal changed flag to the supplied value for a given field.If the
changed
argument isfalse
, theRecord.original(Field)
value will be reset to the corresponding "current" value as well- Specified by:
changed
in interfaceRecord
- See Also:
Record.changed()
,Record.changed(Field)
-
changed
public final void changed(int fieldIndex, boolean c)
Description copied from interface:Record
Set this record's internal changed flag to the supplied value for a given field.If the
changed
argument isfalse
, theRecord.original(int)
value will be reset to the corresponding "current" value as well- Specified by:
changed
in interfaceRecord
- See Also:
Record.changed()
,Record.changed(int)
-
changed
public final void changed(String fieldName, boolean c)
Description copied from interface:Record
Set this record's internal changed flag to the supplied value for a given field.If the
changed
argument isfalse
, theRecord.original(String)
value will be reset to the corresponding "current" value as well- Specified by:
changed
in interfaceRecord
- See Also:
Record.changed()
,Record.changed(String)
-
changed
public final void changed(Name fieldName, boolean c)
Description copied from interface:Record
Set this record's internal changed flag to the supplied value for a given field.If the
changed
argument isfalse
, theRecord.original(Name)
value will be reset to the corresponding "current" value as well- Specified by:
changed
in interfaceRecord
- See Also:
Record.changed()
,Record.changed(Name)
-
reset
public final void reset()
Description copied from interface:Record
-
reset
public final void reset(Field<?> field)
Description copied from interface:Record
Reset a given value to itsRecord.original(Field)
value and itsRecord.changed(Field)
flag tofalse
.
-
reset
public final void reset(int fieldIndex)
Description copied from interface:Record
-
reset
public final void reset(String fieldName)
Description copied from interface:Record
Reset a given value to itsRecord.original(String)
value and itsRecord.changed(String)
flag tofalse
.
-
intoArray
public final Object[] intoArray()
Description copied from interface:Record
Convert this record into an array.The resulting array has the same number of elements as this record has fields. The resulting array contains data as such:
// For arbitrary values of i record.getValue(i) == record.intoArray()[i]
This is the same as calling
into(Object[].class)
- Specified by:
intoArray
in interfaceRecord
- Returns:
- This record as an array
- See Also:
Record.fromArray(Object...)
-
intoList
public final List<Object> intoList()
Description copied from interface:Record
Convert this record into a list.The resulting list has the same number of elements as this record has fields. The resulting array contains data as such:
// For arbitrary values of i record.getValue(i) == record.intoList().get(i)
This is the same as calling
Arrays.asList(intoArray())
-
intoStream
public final Stream<Object> intoStream()
Description copied from interface:Record
Convert this record into a stream.The resulting stream has the same number of elements as this record has fields. The resulting stream contains data as such:
This is the same as calling
into(Stream.class)
- Specified by:
intoStream
in interfaceRecord
- Returns:
- This record as a stream
-
intoMap
public final Map<String,Object> intoMap()
Description copied from interface:Record
Return this record as a name/value map.This is the inverse operation to
Record.fromMap(Map)
- Specified by:
intoMap
in interfaceRecord
- Returns:
- This record as a map
- See Also:
Record.fromMap(Map)
-
into
public final Record into(Field<?>... f)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.
-
into
public final <T1> Record1<T1> into(Field<T1> field1)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2> Record2<T1,T2> into(Field<T1> field1, Field<T2> field2)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3> Record3<T1,T2,T3> into(Field<T1> field1, Field<T2> field2, Field<T3> field3)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4> Record4<T1,T2,T3,T4> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5> Record5<T1,T2,T3,T4,T5> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6> Record6<T1,T2,T3,T4,T5,T6> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7> Record7<T1,T2,T3,T4,T5,T6,T7> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8> Record8<T1,T2,T3,T4,T5,T6,T7,T8> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9> Record9<T1,T2,T3,T4,T5,T6,T7,T8,T9> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10> Record10<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11> Record11<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12> Record12<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13> Record13<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14> Record14<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15> Record15<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16> Record16<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17> Record17<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18> Record18<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17, Field<T18> field18)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19> Record19<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17, Field<T18> field18, Field<T19> field19)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20> Record20<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17, Field<T18> field18, Field<T19> field19, Field<T20> field20)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21> Record21<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17, Field<T18> field18, Field<T19> field19, Field<T20> field20, Field<T21> field21)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21,T22> Record22<T1,T2,T3,T4,T5,T6,T7,T8,T9,T10,T11,T12,T13,T14,T15,T16,T17,T18,T19,T20,T21,T22> into(Field<T1> field1, Field<T2> field2, Field<T3> field3, Field<T4> field4, Field<T5> field5, Field<T6> field6, Field<T7> field7, Field<T8> field8, Field<T9> field9, Field<T10> field10, Field<T11> field11, Field<T12> field12, Field<T13> field13, Field<T14> field14, Field<T15> field15, Field<T16> field16, Field<T17> field17, Field<T18> field18, Field<T19> field19, Field<T20> field20, Field<T21> field21, Field<T22> field22)
Description copied from interface:Record
Copy this record into a new record holding only a subset of the previous fields.- Specified by:
into
in interfaceRecord
- Returns:
- The new record
- See Also:
Record.into(Table)
-
into
public final <E> E into(Class<? extends E> type)
Description copied from interface:Record
Map resulting records onto a custom type.This will map this record onto your custom type using a
RecordMapper
as provided byConfiguration.recordMapperProvider()
. If no custom provider is specified, theDefaultRecordMapperProvider
is used.- Specified by:
into
in interfaceRecord
- Type Parameters:
E
- The generic entity type.- Parameters:
type
- The entity type.- See Also:
Record.from(Object)
,DefaultRecordMapper
-
into
public final <E> E into(E object)
Description copied from interface:Record
Map resulting records onto a custom type.This is the same as
Record.into(Class)
, except that no new object is instantiated as a result. Instead, you can provide your own custom POJO instance.- Specified by:
into
in interfaceRecord
- Type Parameters:
E
- The generic entity type.- Parameters:
object
- The receiving bean.- See Also:
Record.from(Object)
-
into
public final <R extends Record> R into(Table<R> table)
Description copied from interface:Record
Map resulting records onto a custom record type.The mapping algorithm is this:
jOOQ will map
Record
values by equal field names:- For every field in the
table
argument withField.getName()
"MY_field"
(case-sensitive!), a corresponding field with the same name in this record will be searched. - If several fields in this record share the same
Field.getName()
, then the first one returning true onField.equals(Object)
will be returned. (e.g. qualified field names match)
Other restrictions
Table.getRecordType()
must return a class of typeTableRecord
, which must provide a default constructor. Non-public default constructors are made accessible usingConstructor.setAccessible(boolean)
- For every field in the
-
intoResultSet
public final ResultSet intoResultSet()
Description copied from interface:Record
Generate an in-memory JDBCResultSet
containing the data of thisRecord
.Use this as an adapter for JDBC-compliant code that expects a
ResultSet
to operate on, rather than a jOOQResult
. The returnedResultSet
allows for the following behaviour according to the JDBC specification:-
ResultSet.CLOSE_CURSORS_AT_COMMIT
: The cursors (i.e.Statement
object) are no longer available -
ResultSet.CONCUR_READ_ONLY
: You cannot update the database through thisResultSet
, as the underlyingResult
object does not hold any open database refences anymore -
ResultSet.FETCH_FORWARD
: The fetch direction is forward only, and cannot be changed -
ResultSet.TYPE_SCROLL_INSENSITIVE
: You can use any of theResultSet
's scrolling methods, e.g.ResultSet.next()
orResultSet.previous()
, etc.
You may use
DSLContext.fetch(ResultSet)
to unwind this wrapper again.This is the same as creating a new
Result
with thisRecord
only, and then callingResult.intoResultSet()
on thatResult
- Specified by:
intoResultSet
in interfaceRecord
- Returns:
- A wrapper JDBC
ResultSet
-
-
map
public final <E> E map(RecordMapper<Record,E> mapper)
Description copied from interface:Record
Map this record into a custom mapper callback.
-
from
public final void from(Object source)
Description copied from interface:Record
Load data into this record from a source.The mapping algorithm is this:
If
source
is anarray
Loading of data is delegated to
Record.fromArray(Object...)
If
source
is aMap
Loading of data is delegated to
Record.fromMap(Map)
If
source
is anIterable
Loading of data is equivalent to loading
Record.fromArray(Object...)
, transforming theIterable
to an array, first.If any JPA
Column
annotations are found on theClass
of the providedsource
, only those are used. Matching candidates are:- Public no-argument instance methods annotated with
Column
- Public no-argument instance methods starting with
getXXX
orisXXX
, if there exists a matching public single-argumentsetXXX()
instance method that is annotated withColumn
- Public instance member fields annotated with
Column
Column.name()
must matchField.getName()
. All other annotation attributes are ignored- Only the first match per field is used
- Matching methods have a higher priority than matching member fields
- Explicitly matching methods have a higher priority than implicitly matching methods (implicitly matching getter = setter is annotated)
- Static methods / member fields are ignored
If there are no JPA
Column
annotations, or jOOQ can't find thejavax.persistence
API on the classpath, jOOQ will map members by naming convention:If
Field.getName()
isMY_field
(case-sensitive!), then this field's value will be fetched from the first of these:- Public no-argument instance method
MY_field()
- Public no-argument instance method
myField()
- Public no-argument instance method
getMY_field()
- Public no-argument instance method
getMyField()
- Public instance member field
MY_field
- Public instance member field
myField
Other restrictions
- primitive types are supported.
General notes
The resulting record will have its internal "changed" flags set to true for all values. This means that
UpdatableRecord.store()
will perform anINSERT
statement. If you wish to store the record using anUPDATE
statement, useDSLContext.executeUpdate(UpdatableRecord)
instead.This is the same as calling
record.from(source, record.fields())
- Specified by:
from
in interfaceRecord
- Parameters:
source
- The source object to copy data from- See Also:
Record.into(Class)
,Record.from(Object, Field...)
- Public no-argument instance methods annotated with
-
from
public final void from(Object source, Field<?>... f)
Description copied from interface:Record
Load data into this record from a source, providing some fields.This is the same as
Record.from(Object)
, except that only fields contained in thefields
argument will be mapped.- Specified by:
from
in interfaceRecord
- Parameters:
source
- The source object to copy data fromf
- The record's fields to use for mapping- See Also:
Record.into(Class)
,Record.from(Object)
-
from
public final void from(Object source, String... fieldNames)
Description copied from interface:Record
Load data into this record from a source, providing some field names.This is the same as
Record.from(Object)
, except that only fields contained in thefieldNames
argument will be mapped.- Specified by:
from
in interfaceRecord
- Parameters:
source
- The source object to copy data fromfieldNames
- The record's fields names to use for mapping- See Also:
Record.into(Class)
,Record.from(Object)
-
from
public final void from(Object source, Name... fieldNames)
Description copied from interface:Record
Load data into this record from a source, providing some field names.This is the same as
Record.from(Object)
, except that only fields contained in thefieldNames
argument will be mapped.- Specified by:
from
in interfaceRecord
- Parameters:
source
- The source object to copy data fromfieldNames
- The record's fields names to use for mapping- See Also:
Record.into(Class)
,Record.from(Object)
-
from
public final void from(Object source, int... fieldIndexes)
Description copied from interface:Record
Load data into this record from a source, providing some field indexes.This is the same as
Record.from(Object)
, except that only fields contained in thefieldIndexes
argument will be mapped.- Specified by:
from
in interfaceRecord
- Parameters:
source
- The source object to copy data fromfieldIndexes
- The record's fields indexes to use for mapping- See Also:
Record.into(Class)
,Record.from(Object)
-
fromMap
public final void fromMap(Map<String,?> map)
Description copied from interface:Record
Load data from a map into this record.The argument map is expected to hold field-name / value pairs where field-names correspond to actual field names as provided by
Record.field(String)
. Missing fields will be left untouched. Excess fields will be ignored.This is the inverse operation to
Record.intoMap()
. This is the same as callingrecord.fromMap(map, record.fields())
- Specified by:
fromMap
in interfaceRecord
- See Also:
Record.intoMap()
,Record.fromMap(Map, Field...)
-
fromMap
public final void fromMap(Map<String,?> map, Field<?>... f)
Description copied from interface:Record
Load data from a map into this record, providing some fields.The argument map is expected to hold field-name / value pairs where field-names correspond to actual field names as provided by
Record.field(String)
. Missing fields will be left untouched. Excess fields will be ignored.This is the same as
Record.fromMap(Map)
, except that only fields contained in thefields
argument will be mapped.- Specified by:
fromMap
in interfaceRecord
- See Also:
Record.intoMap()
,Record.fromMap(Map)
-
fromMap
public final void fromMap(Map<String,?> map, String... fieldNames)
Description copied from interface:Record
Load data from a map into this record, providing some field names.The argument map is expected to hold field-name / value pairs where field-names correspond to actual field names as provided by
Record.field(String)
. Missing fields will be left untouched. Excess fields will be ignored.This is the same as
Record.fromMap(Map)
, except that only fields contained in thefieldNames
argument will be mapped.- Specified by:
fromMap
in interfaceRecord
- See Also:
Record.intoMap()
,Record.fromMap(Map)
-
fromMap
public final void fromMap(Map<String,?> map, Name... fieldNames)
Description copied from interface:Record
Load data from a map into this record, providing some field names.The argument map is expected to hold field-name / value pairs where field-names correspond to actual field names as provided by
Record.field(Name)
. Missing fields will be left untouched. Excess fields will be ignored.This is the same as
Record.fromMap(Map)
, except that only fields contained in thefieldNames
argument will be mapped.- Specified by:
fromMap
in interfaceRecord
- See Also:
Record.intoMap()
,Record.fromMap(Map)
-
fromMap
public final void fromMap(Map<String,?> map, int... fieldIndexes)
Description copied from interface:Record
Load data from a map into this record, providing some field indexes.The argument map is expected to hold field-name / value pairs where field-names correspond to actual field names as provided by
Record.field(String)
. Missing fields will be left untouched. Excess fields will be ignored.This is the same as
Record.fromMap(Map)
, except that only fields contained in thefieldIndexes
argument will be mapped.- Specified by:
fromMap
in interfaceRecord
- See Also:
Record.intoMap()
,Record.fromMap(Map)
-
fromArray
public final void fromArray(Object... array)
Description copied from interface:Record
Load data from an array into this record.The argument array is expected to hold values for this record's field indexes. Missing values will be left untouched. Excess values will be ignored.
This is the inverse operation to
Record.intoArray()
- Specified by:
fromArray
in interfaceRecord
- See Also:
Record.intoArray()
,Record.fromArray(Object[], Field...)
-
fromArray
public final void fromArray(Object[] array, Field<?>... f)
Description copied from interface:Record
Load data from an array into this record, providing some fields.The argument array is expected to hold values for this record's field indexes. Missing values will be left untouched. Excess values will be ignored.
This is the same as
Record.fromArray(Object...)
, except that only fields contained in thefields
argument will be mapped.- Specified by:
fromArray
in interfaceRecord
- See Also:
Record.intoArray()
,Record.fromArray(Object...)
-
fromArray
public final void fromArray(Object[] array, String... fieldNames)
Description copied from interface:Record
Load data from an array into this record, providing some fields names.The argument array is expected to hold values for this record's field indexes. Missing values will be left untouched. Excess values will be ignored.
This is the same as
Record.fromArray(Object...)
, except that only fields contained in thefieldNames
argument will be mapped.- Specified by:
fromArray
in interfaceRecord
- See Also:
Record.intoArray()
,Record.fromArray(Object...)
-
fromArray
public final void fromArray(Object[] array, Name... fieldNames)
Description copied from interface:Record
Load data from an array into this record, providing some fields names.The argument array is expected to hold values for this record's field indexes. Missing values will be left untouched. Excess values will be ignored.
This is the same as
Record.fromArray(Object...)
, except that only fields contained in thefieldNames
argument will be mapped.- Specified by:
fromArray
in interfaceRecord
- See Also:
Record.intoArray()
,Record.fromArray(Object...)
-
fromArray
public final void fromArray(Object[] array, int... fieldIndexes)
Description copied from interface:Record
Load data from an array into this record, providing some fields indexes.The argument array is expected to hold values for this record's field indexes. Missing values will be left untouched. Excess values will be ignored.
This is the same as
Record.fromArray(Object...)
, except that only fields contained in thefieldIndexes
argument will be mapped.- Specified by:
fromArray
in interfaceRecord
- See Also:
Record.intoArray()
,Record.fromArray(Object...)
-
from
protected final void from(Record source)
This method was implemented with [#799]. It may be useful to make it public for broader use...?
-
format
public final void format(Writer writer, TXTFormat format)
Description copied from interface:Formattable
LikeFormattable.format(TXTFormat)
, but the data is output onto aWriter
.- Specified by:
format
in interfaceFormattable
-
formatCSV
public final void formatCSV(Writer writer, CSVFormat format)
Description copied from interface:Formattable
LikeFormattable.formatCSV(CSVFormat)
, but the data is output onto aWriter
.- Specified by:
formatCSV
in interfaceFormattable
-
formatJSON
public final void formatJSON(Writer writer, JSONFormat format)
Description copied from interface:Formattable
LikeFormattable.formatJSON(JSONFormat)
, but the data is output onto aWriter
.- Specified by:
formatJSON
in interfaceFormattable
-
formatXML
public final void formatXML(Writer writer, XMLFormat format)
Description copied from interface:Formattable
LikeFormattable.formatXML(XMLFormat)
, but the data is output onto aWriter
.- Specified by:
formatXML
in interfaceFormattable
-
formatHTML
public final void formatHTML(Writer writer)
Description copied from interface:Formattable
LikeFormattable.formatHTML()
, but the data is output onto aWriter
.- Specified by:
formatHTML
in interfaceFormattable
-
formatChart
public final void formatChart(Writer writer, ChartFormat format)
Description copied from interface:Formattable
LikeFormattable.formatChart(ChartFormat)
, but the data is output onto aWriter
.- Specified by:
formatChart
in interfaceFormattable
-
formatInsert
public final void formatInsert(Writer writer)
Description copied from interface:Formattable
LikeFormattable.formatInsert()
, but the data is output onto aWriter
.- Specified by:
formatInsert
in interfaceFormattable
-
formatInsert
public final void formatInsert(Writer writer, Table<?> table, Field<?>... f)
Description copied from interface:Formattable
LikeFormattable.formatInsert(Table, Field...)
, but the data is output onto anWriter
.- Specified by:
formatInsert
in interfaceFormattable
-
intoXML
public final Document intoXML(XMLFormat format)
Description copied from interface:Formattable
Get this result as XML.- Specified by:
intoXML
in interfaceFormattable
- See Also:
Formattable.formatXML()
, http://www.jooq.org/xsd/jooq-export-3.10.0.xsd
-
intoXML
public final <H extends ContentHandler> H intoXML(H handler, XMLFormat format) throws SAXException
Description copied from interface:Formattable
Get this result as XML using a SAXContentHandler
.- Specified by:
intoXML
in interfaceFormattable
- Parameters:
handler
- The custom content handler.- Returns:
- The argument content handler is returned for convenience.
- Throws:
SAXException
- See Also:
Formattable.formatXML()
, http://www.jooq.org/xsd/jooq-export-3.10.0.xsd
-
compareTo
public int compareTo(Record that)
Description copied from interface:Record
Compares thisRecord
with anotherRecord
according to their natural ordering.jOOQ Records implement
Comparable
to allow for naturally ordering Records in a "SQL way", i.e. according to the following rules:Records being compared must have the same ROW type
Two Records are comparable if and only if they have the same
ROW
type, i.e. if theirfieldsRow()
methods return fields of the same type and degree.Comparison rules
Assume the following notations:
X[i]
meansX.getValue(i)
X = Y
meansX.compareTo(Y) == 0
X < Y
meansX.compareTo(Y) < 0
X[i] = Y[i]
means(X[i] == null && Y[i] == null) || X[i].compareTo(Y[i]) == 0
X[i] < Y[i]
meansY[i] == null || X[i].compareTo(Y[i]) < 0
. This corresponds to the SQLNULLS LAST
clause.
r1
andr2
,x = r1.compareTo(r2)
yields:x = -1
: if(r1[0] < r2[0]) OR (r1[0] = r2[0] AND r1[1] < r2[1]) OR ... OR (r1[0] = r2[0] AND ... AND r1[N-1] = r2[N-1] AND r1[N] < r2[N])
x = 0
: ifOR (r1[0] = r2[0] AND ... AND r1[N-1] = r2[N-1] AND r1[N] = r2[N])
x = 1
: if(r1[0] > r2[0]) OR (r1[0] = r2[0] AND r1[1] > r2[1]) OR ... OR (r1[0] = r2[0] AND ... AND r1[N-1] = r2[N-1] AND r1[N] > r2[N])
Note, that the above rules correspond to the SQL ordering behaviour as illustrated in the following examples:
-- A SQL ORDER BY clause, ordering all records by columns in their order SELECT a, b, c FROM my_table ORDER BY 1, 2, 3 -- A row value expression comparison predicate SELECT * FROM my_table WHERE (a, b, c) < (1, 2, 3)
See
Row1.lessThan(Row1)
,Row2.lessThan(Row2)
, ...,Row22.lessThan(Row22)
for more details about row value expression comparison predicatesAlternative sorting behaviour can be achieved through
Result.sortAsc(java.util.Comparator)
and similar methods.- Specified by:
compareTo
in interfaceComparable<Record>
- Specified by:
compareTo
in interfaceRecord
-
getValue
public final <T> T getValue(Field<T> field)
Description copied from interface:Record
Get a value from this Record, providing a field.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(Field)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(Field)
-
getValue
@Deprecated public final <T> T getValue(Field<T> field, T defaultValue)
Deprecated.Description copied from interface:Record
Get a value from this record, providing a field.
-
getValue
public final <T> T getValue(Field<?> field, Class<? extends T> type)
Description copied from interface:Record
Get a converted value from this Record, providing a field.[#2211] Future versions of jOOQ might remove tthis method. It is recommended to use
Record.get(Field, Class)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(Field, Class)
-
getValue
@Deprecated public final <T> T getValue(Field<?> field, Class<? extends T> type, T defaultValue)
Deprecated.Description copied from interface:Record
Get a converted value from this record, providing a field.- Specified by:
getValue
in interfaceRecord
- Type Parameters:
T
- The conversion type parameter- Parameters:
field
- The fieldtype
- The conversion typedefaultValue
- The default value instead ofnull
- Returns:
- The value of a field contained in this record, or defaultValue,
if
null
- See Also:
Convert.convert(Object, Class)
-
getValue
public final <T,U> U getValue(Field<T> field, Converter<? super T,? extends U> converter)
Description copied from interface:Record
Get a converted value from this Record, providing a field.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(Field, Converter)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(Field, Converter)
-
getValue
@Deprecated public final <T,U> U getValue(Field<T> field, Converter<? super T,? extends U> converter, U defaultValue)
Deprecated.Description copied from interface:Record
Get a converted value from this record, providing a field.- Specified by:
getValue
in interfaceRecord
- Type Parameters:
T
- The database type parameterU
- The conversion type parameter- Parameters:
field
- The fieldconverter
- The data type converterdefaultValue
- The default value instead ofnull
- Returns:
- The value of a field contained in this record, or defaultValue,
if
null
- See Also:
Convert.convert(Object, Converter)
-
getValue
public final Object getValue(int index)
Description copied from interface:Record
Get a value from this record, providing a field index.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(int)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(int)
-
getValue
@Deprecated public final Object getValue(int index, Object defaultValue)
Deprecated.Description copied from interface:Record
Get a value from this record, providing a field index.
-
getValue
public final <T> T getValue(int index, Class<? extends T> type)
Description copied from interface:Record
Get a converted value from this record, providing a field index.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(int, Class)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(int, Class)
-
getValue
@Deprecated public final <T> T getValue(int index, Class<? extends T> type, T defaultValue)
Deprecated.Description copied from interface:Record
Get a converted value from this record, providing a field index.- Specified by:
getValue
in interfaceRecord
- Type Parameters:
T
- The conversion type parameter- Parameters:
index
- The field's indextype
- The conversion typedefaultValue
- The default value instead ofnull
- Returns:
- The value of a field's index contained in this record, or
defaultValue, if
null
- See Also:
Convert.convert(Object, Class)
-
getValue
public final <U> U getValue(int index, Converter<?,? extends U> converter)
Description copied from interface:Record
Get a converted value from this record, providing a field index.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(int, Converter)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(int, Converter)
-
getValue
@Deprecated public final <U> U getValue(int index, Converter<?,? extends U> converter, U defaultValue)
Deprecated.Description copied from interface:Record
Get a converted value from this record, providing a field index.- Specified by:
getValue
in interfaceRecord
- Type Parameters:
U
- The conversion type parameter- Parameters:
index
- The field's indexconverter
- The data type converterdefaultValue
- The default value instead ofnull
- Returns:
- The value of a field's index contained in this record, or
defaultValue, if
null
- See Also:
Convert.convert(Object, Converter)
-
getValue
public final Object getValue(String fieldName)
Description copied from interface:Record
Get a value from this Record, providing a field name.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(String)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(String)
-
getValue
@Deprecated public final Object getValue(String fieldName, Object defaultValue)
Deprecated.Description copied from interface:Record
Get a value from this record, providing a field name.
-
getValue
public final <T> T getValue(String fieldName, Class<? extends T> type)
Description copied from interface:Record
Get a converted value from this Record, providing a field name.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(String, Class)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(String, Class)
-
getValue
@Deprecated public final <T> T getValue(String fieldName, Class<? extends T> type, T defaultValue)
Deprecated.Description copied from interface:Record
Get a converted value from this record, providing a field name.- Specified by:
getValue
in interfaceRecord
- Type Parameters:
T
- The conversion type parameter- Parameters:
fieldName
- The field's nametype
- The conversion typedefaultValue
- The default value instead ofnull
- Returns:
- The value of a field's name contained in this record, or
defaultValue, if
null
- See Also:
Convert.convert(Object, Class)
-
getValue
public final <U> U getValue(String fieldName, Converter<?,? extends U> converter)
Description copied from interface:Record
Get a converted value from this Record, providing a field name.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(String, Converter)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(String, Converter)
-
getValue
@Deprecated public final <U> U getValue(String fieldName, Converter<?,? extends U> converter, U defaultValue)
Deprecated.Description copied from interface:Record
Get a converted value from this record, providing a field name.- Specified by:
getValue
in interfaceRecord
- Type Parameters:
U
- The conversion type parameter- Parameters:
fieldName
- The field's nameconverter
- The data type converterdefaultValue
- The default value instead ofnull
- Returns:
- The value of a field's name contained in this record, or
defaultValue, if
null
- See Also:
Convert.convert(Object, Converter)
-
getValue
public final Object getValue(Name fieldName)
Description copied from interface:Record
Get a value from this Record, providing a field name.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(Name)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(Name)
-
getValue
public final <T> T getValue(Name fieldName, Class<? extends T> type)
Description copied from interface:Record
Get a converted value from this Record, providing a field name.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(Name, Class)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(Name, Class)
-
getValue
public final <U> U getValue(Name fieldName, Converter<?,? extends U> converter)
Description copied from interface:Record
Get a converted value from this Record, providing a field name.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.get(Name, Converter)
instead.- Specified by:
getValue
in interfaceRecord
- See Also:
Record.get(Name, Converter)
-
setValue
public final <T> void setValue(Field<T> field, T value)
Description copied from interface:Record
Set a value into this record.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.set(Field, Object)
instead.- Specified by:
setValue
in interfaceRecord
- See Also:
Record.set(Field, Object)
-
setValue
public final <T,U> void setValue(Field<T> field, U value, Converter<? extends T,? super U> converter)
Description copied from interface:Record
Set a value into this record.[#2211] Future versions of jOOQ might remove this method. It is recommended to use
Record.set(Field, Object, Converter)
instead.- Specified by:
setValue
in interfaceRecord
- See Also:
Record.set(Field, Object, Converter)
-
attach
public final void attach(Configuration c)
Description copied from interface:Attachable
Attach this object to a newConfiguration
.- Specified by:
attach
in interfaceAttachable
- Parameters:
c
- A configuration ornull
, if you wish to detach thisAttachable
from its previous configuration.
-
detach
public final void detach()
Description copied from interface:Attachable
Detach this object from its currentConfiguration
.This is the same as calling
attach(null)
.- Specified by:
detach
in interfaceAttachable
-
configuration
public final Configuration configuration()
Description copied from interface:Attachable
- Specified by:
configuration
in interfaceAttachable
-
create
@Deprecated protected final DSLContext create()
Deprecated.- 3.11.0 - [#6720] [#6721] - UseAttachable.configuration()
andConfiguration.dsl()
instead.This method is used in generated code!
-
format
public final String format()
Description copied from interface:Formattable
Get a simple formatted representation of this result.This is the same as calling
Formattable.format(int)
withmaxRows = Integer.MAX_VALUE
- Specified by:
format
in interfaceFormattable
- Returns:
- The formatted result
-
format
public final String format(int maxRecords)
Description copied from interface:Formattable
Get a simple formatted representation of this result.- Specified by:
format
in interfaceFormattable
- Parameters:
maxRecords
- The maximum number of records to include in the formatted result- Returns:
- The formatted result
-
format
public final String format(TXTFormat format)
Description copied from interface:Formattable
Get a simple formatted representation of this result.- Specified by:
format
in interfaceFormattable
- Parameters:
format
- The formatting information- Returns:
- The formatted result
-
format
public final void format(OutputStream stream)
Description copied from interface:Formattable
LikeFormattable.format()
, but the data is output onto anOutputStream
.- Specified by:
format
in interfaceFormattable
-
format
public final void format(OutputStream stream, int maxRecords)
Description copied from interface:Formattable
LikeFormattable.format(int)
, but the data is output onto anOutputStream
.- Specified by:
format
in interfaceFormattable
-
format
public final void format(OutputStream stream, TXTFormat format)
Description copied from interface:Formattable
LikeFormattable.format(TXTFormat)
, but the data is output onto anOutputStream
.- Specified by:
format
in interfaceFormattable
-
format
public final void format(Writer writer)
Description copied from interface:Formattable
LikeFormattable.format()
, but the data is output onto aWriter
.- Specified by:
format
in interfaceFormattable
-
format
public final void format(Writer writer, int maxRecords)
Description copied from interface:Formattable
LikeFormattable.format(int)
, but the data is output onto aWriter
.- Specified by:
format
in interfaceFormattable
-
formatCSV
public final String formatCSV()
Description copied from interface:Formattable
Get a simple formatted representation of this result as CSV.This is the same as calling
formatCSV(true, ',', "")
- Specified by:
formatCSV
in interfaceFormattable
- Returns:
- The formatted result
-
formatCSV
public final String formatCSV(boolean header)
Description copied from interface:Formattable
Get a simple formatted representation of this result as CSV.This is the same as calling
formatCSV(',', "")
- Specified by:
formatCSV
in interfaceFormattable
- Parameters:
header
- Whether to emit a CSV header line- Returns:
- The formatted result
-
formatCSV
public final void formatCSV(OutputStream stream)
Description copied from interface:Formattable
LikeFormattable.formatCSV()
, but the data is output onto anOutputStream
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final void formatCSV(OutputStream stream, boolean header)
Description copied from interface:Formattable
LikeFormattable.formatCSV(boolean)
, but the data is output onto anOutputStream
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final void formatCSV(Writer writer)
Description copied from interface:Formattable
LikeFormattable.formatCSV()
, but the data is output onto aWriter
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final void formatCSV(Writer writer, boolean header)
Description copied from interface:Formattable
LikeFormattable.formatCSV(boolean)
, but the data is output onto aWriter
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final String formatCSV(char delimiter)
Description copied from interface:Formattable
Get a simple formatted representation of this result as CSV.This is the same as calling
formatCSV(true, delimiter, "")
- Specified by:
formatCSV
in interfaceFormattable
- Parameters:
delimiter
- The delimiter to use between records- Returns:
- The formatted result
-
formatCSV
public final String formatCSV(boolean header, char delimiter)
Description copied from interface:Formattable
Get a simple formatted representation of this result as CSV.This is the same as calling
formatCSV(delimiter, "")
- Specified by:
formatCSV
in interfaceFormattable
- Parameters:
header
- Whether to emit a CSV header linedelimiter
- The delimiter to use between records- Returns:
- The formatted result
-
formatCSV
public final void formatCSV(OutputStream stream, char delimiter)
Description copied from interface:Formattable
LikeFormattable.formatCSV(char)
, but the data is output onto anOutputStream
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final void formatCSV(OutputStream stream, boolean header, char delimiter)
Description copied from interface:Formattable
LikeFormattable.formatCSV(boolean, char)
, but the data is output onto anOutputStream
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final void formatCSV(Writer writer, char delimiter)
Description copied from interface:Formattable
LikeFormattable.formatCSV(char)
, but the data is output onto aWriter
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final void formatCSV(Writer writer, boolean header, char delimiter)
Description copied from interface:Formattable
LikeFormattable.formatCSV(boolean, char)
, but the data is output onto aWriter
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final String formatCSV(char delimiter, String nullString)
Description copied from interface:Formattable
Get a simple formatted representation of this result as CSV.This is the same as calling
formatCSV(true, delimiter, nullString)
- Specified by:
formatCSV
in interfaceFormattable
- Parameters:
delimiter
- The delimiter to use between recordsnullString
- A special string for encodingNULL
values.- Returns:
- The formatted result
-
formatCSV
public final String formatCSV(boolean header, char delimiter, String nullString)
Description copied from interface:Formattable
Get a simple formatted representation of this result as CSV.- Specified by:
formatCSV
in interfaceFormattable
- Parameters:
header
- Whether to emit a CSV header linedelimiter
- The delimiter to use between recordsnullString
- A special string for encodingNULL
values.- Returns:
- The formatted result
-
formatCSV
public final String formatCSV(CSVFormat format)
Description copied from interface:Formattable
Get a simple formatted representation of this result as CSV.- Specified by:
formatCSV
in interfaceFormattable
- Returns:
- The formatted result
-
formatCSV
public final void formatCSV(OutputStream stream, char delimiter, String nullString)
Description copied from interface:Formattable
LikeFormattable.formatCSV(char, String)
, but the data is output onto anOutputStream
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final void formatCSV(OutputStream stream, boolean header, char delimiter, String nullString)
Description copied from interface:Formattable
LikeFormattable.formatCSV(boolean, char, String)
, but the data is output onto anOutputStream
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final void formatCSV(OutputStream stream, CSVFormat format)
Description copied from interface:Formattable
LikeFormattable.formatCSV(CSVFormat)
, but the data is output onto anOutputStream
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final void formatCSV(Writer writer, char delimiter, String nullString)
Description copied from interface:Formattable
LikeFormattable.formatCSV(char, String)
, but the data is output onto aWriter
.- Specified by:
formatCSV
in interfaceFormattable
-
formatCSV
public final void formatCSV(Writer writer, boolean header, char delimiter, String nullString)
Description copied from interface:Formattable
LikeFormattable.formatCSV(boolean, char, String)
, but the data is output onto aWriter
.- Specified by:
formatCSV
in interfaceFormattable
-
formatJSON
public final String formatJSON()
Description copied from interface:Formattable
Get a simple formatted representation of this result as a JSON array of array.The format is the following:
{"fields":[{"name":"field-1","type":"type-1"}, {"name":"field-2","type":"type-2"}, ..., {"name":"field-n","type":"type-n"}], "records":[[value-1-1,value-1-2,...,value-1-n], [value-2-1,value-2-2,...,value-2-n]]}
- Specified by:
formatJSON
in interfaceFormattable
- Returns:
- The formatted result
-
formatJSON
public final String formatJSON(JSONFormat format)
Description copied from interface:Formattable
Get a simple formatted representation of this result as a JSON data structure, according to the format.- Specified by:
formatJSON
in interfaceFormattable
- Returns:
- The formatted result
- See Also:
JSONFormat
-
formatJSON
public final void formatJSON(OutputStream stream)
Description copied from interface:Formattable
LikeFormattable.formatJSON()
, but the data is output onto anOutputStream
.- Specified by:
formatJSON
in interfaceFormattable
-
formatJSON
public final void formatJSON(OutputStream stream, JSONFormat format)
Description copied from interface:Formattable
LikeFormattable.formatJSON(JSONFormat)
, but the data is output onto anOutputStream
.- Specified by:
formatJSON
in interfaceFormattable
-
formatJSON
public final void formatJSON(Writer writer)
Description copied from interface:Formattable
LikeFormattable.formatJSON()
, but the data is output onto aWriter
.- Specified by:
formatJSON
in interfaceFormattable
-
formatXML
public final String formatXML()
Description copied from interface:Formattable
Get this result formatted as XML.- Specified by:
formatXML
in interfaceFormattable
- See Also:
- http://www.jooq.org/xsd/jooq-export-3.10.0.xsd
-
formatXML
public final String formatXML(XMLFormat format)
Description copied from interface:Formattable
Get this result formatted as XML.- Specified by:
formatXML
in interfaceFormattable
- See Also:
- http://www.jooq.org/xsd/jooq-export-3.10.0.xsd
-
formatXML
public final void formatXML(OutputStream stream)
Description copied from interface:Formattable
LikeFormattable.formatXML()
, but the data is output onto anOutputStream
.- Specified by:
formatXML
in interfaceFormattable
-
formatXML
public final void formatXML(OutputStream stream, XMLFormat format)
Description copied from interface:Formattable
LikeFormattable.formatXML(XMLFormat)
, but the data is output onto anOutputStream
.- Specified by:
formatXML
in interfaceFormattable
-
formatXML
public final void formatXML(Writer writer)
Description copied from interface:Formattable
LikeFormattable.formatXML()
, but the data is output onto aWriter
.- Specified by:
formatXML
in interfaceFormattable
-
formatChart
public final String formatChart()
- Specified by:
formatChart
in interfaceFormattable
-
formatChart
public final String formatChart(ChartFormat format)
- Specified by:
formatChart
in interfaceFormattable
-
formatChart
public final void formatChart(OutputStream stream)
Description copied from interface:Formattable
LikeFormattable.formatChart()
, but the data is output onto anOutputStream
.- Specified by:
formatChart
in interfaceFormattable
-
formatChart
public final void formatChart(OutputStream stream, ChartFormat format)
Description copied from interface:Formattable
LikeFormattable.formatChart(ChartFormat)
, but the data is output onto anOutputStream
.- Specified by:
formatChart
in interfaceFormattable
-
formatChart
public final void formatChart(Writer writer)
Description copied from interface:Formattable
LikeFormattable.formatChart()
, but the data is output onto aWriter
.- Specified by:
formatChart
in interfaceFormattable
-
formatInsert
public final String formatInsert()
Description copied from interface:Formattable
Get this result as a set ofINSERT
statements.This uses the the first record's
TableRecord.getTable()
, if the first record is aTableRecord
. Otherwise, this generatesINSERT
statements into an"UNKNOWN_TABLE"
. In both cases, theResult.fields()
are used for column names.- Specified by:
formatInsert
in interfaceFormattable
-
formatInsert
public final void formatInsert(OutputStream stream)
Description copied from interface:Formattable
LikeFormattable.formatInsert()
, but the data is output onto anOutputStream
.- Specified by:
formatInsert
in interfaceFormattable
-
formatInsert
public final String formatInsert(Table<?> table, Field<?>... f)
Description copied from interface:Formattable
Get this result as a set ofINSERT
statements.This explicitly specifies the table (and optionally the fields) to insert into. If the
fields
argument is left empty, theResult.fields()
are used, instead.- Specified by:
formatInsert
in interfaceFormattable
-
formatInsert
public final void formatInsert(OutputStream stream, Table<?> table, Field<?>... f)
Description copied from interface:Formattable
LikeFormattable.formatInsert(Table, Field...)
, but the data is output onto anOutputStream
.- Specified by:
formatInsert
in interfaceFormattable
-
formatHTML
public final String formatHTML()
Description copied from interface:Formattable
Get a simple formatted representation of this result as HTML.The HTML code is formatted as follows:
<table> <thead> <tr> <th>field-1</th> <th>field-2</th> ... <th>field-n</th> </tr> </thead> <tbody> <tr> <th>value-1-1</th> <th>value-1-2</th> ... <th>value-1-n</th> </tr> <tr> <th>value-2-1</th> <th>value-2-2</th> ... <th>value-2-n</th> </tr> ... </tbody> </table>
- Specified by:
formatHTML
in interfaceFormattable
- Returns:
- The formatted result
-
formatHTML
public final void formatHTML(OutputStream stream)
Description copied from interface:Formattable
LikeFormattable.formatHTML()
, but the data is output onto anOutputStream
.- Specified by:
formatHTML
in interfaceFormattable
-
intoXML
public final Document intoXML()
Description copied from interface:Formattable
Get this result as XML.- Specified by:
intoXML
in interfaceFormattable
- See Also:
Formattable.formatXML()
, http://www.jooq.org/xsd/jooq-export-3.10.0.xsd
-
intoXML
public final <H extends ContentHandler> H intoXML(H handler) throws SAXException
Description copied from interface:Formattable
Get this result as XML using a SAXContentHandler
.- Specified by:
intoXML
in interfaceFormattable
- Parameters:
handler
- The custom content handler.- Returns:
- The argument content handler is returned for convenience.
- Throws:
SAXException
- See Also:
Formattable.formatXML()
, http://www.jooq.org/xsd/jooq-export-3.10.0.xsd
-
-