Package io.vertx.sqlclient
Interface Row
-
- All Superinterfaces:
Tuple
public interface Row extends Tuple
A single row of theexecution result rowset.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default <T> Tget(Class<T> type, String column)LikeTuple.get(Class, int)but specifying thecolumninstead of the position.default BigDecimal[]getArrayOfBigDecimals(String column)Get an array ofBigDecimalvalue for the givencolumn.default Boolean[]getArrayOfBooleans(String column)Get an array ofBooleanvalue for the givencolumn.default Buffer[]getArrayOfBuffers(String column)Get an array ofBuffervalue for the givencolumn.default Double[]getArrayOfDoubles(String column)Get an array ofDoublevalue for the givencolumn.default Float[]getArrayOfFloats(String column)Get an array ofFloatvalue for the givencolumn.default Integer[]getArrayOfIntegers(String column)Get an array ofIntegervalue for the givencolumn.default JsonArray[]getArrayOfJsonArrays(String column)Get an array ofJsonArrayvalue for the givencolumn.default JsonObject[]getArrayOfJsonObjects(String column)Get an array ofJsonObjectvalue for the givencolumn.default Object[]getArrayOfJsons(String column)Get an array of JSON elements for the givencolumn, the element might benullor one of the following types: String Number JsonObject JsonArray Booleandefault LocalDate[]getArrayOfLocalDates(String column)Get an array ofLocalDatevalue for the givencolumn.default LocalDateTime[]getArrayOfLocalDateTimes(String column)Get an array ofLocalDateTimevalue for the givencolumn.default LocalTime[]getArrayOfLocalTimes(String column)Get an array ofLocalTimevalue for the givencolumn.default Long[]getArrayOfLongs(String column)Get an array ofLongvalue for the givencolumn.default Numeric[]getArrayOfNumerics(String column)Get an array ofNumericvalue for the givencolumn.default OffsetDateTime[]getArrayOfOffsetDateTimes(String column)Get an array ofOffsetDateTimevalue for the givencolumn.default OffsetTime[]getArrayOfOffsetTimes(String column)Get an array ofOffsetTimevalue for the givencolumn.default Short[]getArrayOfShorts(String column)Get an array ofShortvalue for the givencolumn.default String[]getArrayOfStrings(String column)Get an array ofStringvalue for the givencolumn.default Temporal[]getArrayOfTemporals(String column)Get an array ofTemporalvalue for the givencolumn.default UUID[]getArrayOfUUIDs(String column)Get an array ofUUIDvalue for the givencolumn.default BigDecimalgetBigDecimal(String column)GetBigDecimalvalue for the givencolumn.default BooleangetBoolean(String column)Get a boolean value for the givencolumn.default BuffergetBuffer(String column)Get a buffer value for the givencolumn.intgetColumnIndex(String column)Get a column position for the given @code column}.StringgetColumnName(int pos)Get a column name atpos.default DoublegetDouble(String column)Get a double value for the givencolumn.default FloatgetFloat(String column)Get a float value for the givencolumn.default IntegergetInteger(String column)Get an integer value for the givencolumn.default ObjectgetJson(String column)Get a JSON element for the givencolumn, the element might benullor one of the following types: String Number JsonObject JsonArray Booleandefault JsonArraygetJsonArray(String column)Get aJsonArrayvalue for the givencolumn.default JsonObjectgetJsonObject(String column)Get aJsonObjectvalue for the givencolumn.default LocalDategetLocalDate(String column)GetLocalDatevalue for the givencolumn.default LocalDateTimegetLocalDateTime(String column)GetLocalDateTimevalue for the givencolumn.default LocalTimegetLocalTime(String column)GetLocalTimevalue for the givencolumn.default LonggetLong(String column)Get a long value for the givencolumn.default NumericgetNumeric(String column)GetNumericvalue for the givencolumn.default OffsetDateTimegetOffsetDateTime(String column)GetOffsetDateTimevalue for the givencolumn.default OffsetTimegetOffsetTime(String column)GetOffsetTimevalue for the givencolumn.default ShortgetShort(String column)Get a short value for the givencolumn.default StringgetString(String column)Get a string value for the givencolumn.default TemporalgetTemporal(String column)Get a temporal value for the givencolumn.default UUIDgetUUID(String column)GetUUIDvalue for the givencolumn.default ObjectgetValue(String column)Get a value for the givencolumn.default voidrelease()Signal the row can be recycled, this is only effective when dealing with a row in a collector query and the row has already been processed and transformed.default JsonObjecttoJson()Return a JSON object representation of the row.-
Methods inherited from interface io.vertx.sqlclient.Tuple
addArrayOfBigDecimal, addArrayOfBoolean, addArrayOfBuffer, addArrayOfDouble, addArrayOfFloat, addArrayOfInteger, addArrayOfJsonArray, addArrayOfJsonObject, addArrayOfLocalDate, addArrayOfLocalDateTime, addArrayOfLocalTime, addArrayOfLong, addArrayOfOffsetDateTime, addArrayOfOffsetTime, addArrayOfShort, addArrayOfString, addArrayOfTemporal, addArrayOfUUID, addBigDecimal, addBoolean, addBuffer, addDouble, addFloat, addInteger, addJsonArray, addJsonObject, addLocalDate, addLocalDateTime, addLocalTime, addLong, addOffsetDateTime, addOffsetTime, addShort, addString, addTemporal, addUUID, addValue, clear, deepToString, get, getArrayOfBigDecimals, getArrayOfBooleans, getArrayOfBuffers, getArrayOfDoubles, getArrayOfFloats, getArrayOfIntegers, getArrayOfJsonArrays, getArrayOfJsonObjects, getArrayOfJsons, getArrayOfLocalDates, getArrayOfLocalDateTimes, getArrayOfLocalTimes, getArrayOfLongs, getArrayOfNumerics, getArrayOfOffsetDateTimes, getArrayOfOffsetTimes, getArrayOfShorts, getArrayOfStrings, getArrayOfTemporals, getArrayOfUUIDs, getBigDecimal, getBoolean, getBuffer, getDouble, getFloat, getInteger, getJson, getJsonArray, getJsonObject, getLocalDate, getLocalDateTime, getLocalTime, getLong, getNumeric, getOffsetDateTime, getOffsetTime, getShort, getString, getTemporal, getUUID, getValue, size, types
-
-
-
-
Method Detail
-
getColumnName
String getColumnName(int pos)
Get a column name atpos.- Parameters:
pos- the column position- Returns:
- the column name or
null
-
getColumnIndex
int getColumnIndex(String column)
Get a column position for the given @code column}.- Parameters:
column- the column name- Returns:
- the column name or
-1if not found
-
getValue
default Object getValue(String column)
Get a value for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getBoolean
default Boolean getBoolean(String column)
Get a boolean value for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getShort
default Short getShort(String column)
Get a short value for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getInteger
default Integer getInteger(String column)
Get an integer value for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getLong
default Long getLong(String column)
Get a long value for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getFloat
default Float getFloat(String column)
Get a float value for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getDouble
default Double getDouble(String column)
Get a double value for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getNumeric
default Numeric getNumeric(String column)
GetNumericvalue for the givencolumn.- Parameters:
column- the column- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getString
default String getString(String column)
Get a string value for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getJson
default Object getJson(String column)
Get a JSON element for the givencolumn, the element might benullor one of the following types:- String
- Number
- JsonObject
- JsonArray
- Boolean
- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getJsonObject
default JsonObject getJsonObject(String column)
Get aJsonObjectvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getJsonArray
default JsonArray getJsonArray(String column)
Get aJsonArrayvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getTemporal
default Temporal getTemporal(String column)
Get a temporal value for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getLocalDate
default LocalDate getLocalDate(String column)
GetLocalDatevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getLocalTime
default LocalTime getLocalTime(String column)
GetLocalTimevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getLocalDateTime
default LocalDateTime getLocalDateTime(String column)
GetLocalDateTimevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getOffsetTime
default OffsetTime getOffsetTime(String column)
GetOffsetTimevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getOffsetDateTime
default OffsetDateTime getOffsetDateTime(String column)
GetOffsetDateTimevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getBuffer
default Buffer getBuffer(String column)
Get a buffer value for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getUUID
default UUID getUUID(String column)
GetUUIDvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getBigDecimal
default BigDecimal getBigDecimal(String column)
GetBigDecimalvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfBooleans
default Boolean[] getArrayOfBooleans(String column)
Get an array ofBooleanvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfShorts
default Short[] getArrayOfShorts(String column)
Get an array ofShortvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfIntegers
default Integer[] getArrayOfIntegers(String column)
Get an array ofIntegervalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfLongs
default Long[] getArrayOfLongs(String column)
Get an array ofLongvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfFloats
default Float[] getArrayOfFloats(String column)
Get an array ofFloatvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfDoubles
default Double[] getArrayOfDoubles(String column)
Get an array ofDoublevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfNumerics
default Numeric[] getArrayOfNumerics(String column)
Get an array ofNumericvalue for the givencolumn.- Parameters:
column- the column- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfStrings
default String[] getArrayOfStrings(String column)
Get an array ofStringvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfJsonObjects
default JsonObject[] getArrayOfJsonObjects(String column)
Get an array ofJsonObjectvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfJsonArrays
default JsonArray[] getArrayOfJsonArrays(String column)
Get an array ofJsonArrayvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfTemporals
default Temporal[] getArrayOfTemporals(String column)
Get an array ofTemporalvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfLocalDates
default LocalDate[] getArrayOfLocalDates(String column)
Get an array ofLocalDatevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfLocalTimes
default LocalTime[] getArrayOfLocalTimes(String column)
Get an array ofLocalTimevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfLocalDateTimes
default LocalDateTime[] getArrayOfLocalDateTimes(String column)
Get an array ofLocalDateTimevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfOffsetTimes
default OffsetTime[] getArrayOfOffsetTimes(String column)
Get an array ofOffsetTimevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfOffsetDateTimes
default OffsetDateTime[] getArrayOfOffsetDateTimes(String column)
Get an array ofOffsetDateTimevalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfBuffers
default Buffer[] getArrayOfBuffers(String column)
Get an array ofBuffervalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfUUIDs
default UUID[] getArrayOfUUIDs(String column)
Get an array ofUUIDvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfBigDecimals
default BigDecimal[] getArrayOfBigDecimals(String column)
Get an array ofBigDecimalvalue for the givencolumn.- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
getArrayOfJsons
default Object[] getArrayOfJsons(String column)
Get an array of JSON elements for the givencolumn, the element might benullor one of the following types:- String
- Number
- JsonObject
- JsonArray
- Boolean
- Parameters:
column- the column name- Returns:
- the
columnvalue - Throws:
NoSuchElementException- when thecolumndoes not exist
-
get
default <T> T get(Class<T> type, String column)
LikeTuple.get(Class, int)but specifying thecolumninstead of the position.
-
toJson
default JsonObject toJson()
Return a JSON object representation of the row.Column names are mapped to JSON keys.
The following rules are applied for the column values:
- number, boolean and string are preserved
- the
nullvalue is preserved - JSON elements are preserved
Bufferare converted to base64 encoded strings- array is mapped
JsonArray - otherwise the type converted to a string
- Returns:
- the json representation
-
release
default void release()
Signal the row can be recycled, this is only effective when dealing with a row in a collector query and the row has already been processed and transformed.
-
-