get

inline fun <T> get(index: Int): T

Returns the attribute at index, cast to T.

Return

The attribute value.

Parameters

index

Zero-based index in declaration order.

Type Parameters

T

The expected attribute type. Declare it nullable to accept a SQL NULL.

Throws

COLUMN_NOT_FOUND if index is outside this composite's attributes, CONVERSION_ERROR if the value is null under a non-nullable T, or is not a T.


inline fun <T> get(name: String): T

Returns the attribute named name, cast to T.

Return

The attribute value.

Parameters

name

The attribute name, as declared in the database.

Type Parameters

T

The expected attribute type. Declare it nullable to accept a SQL NULL.

Throws

COLUMN_NOT_FOUND if there is no such attribute, CONVERSION_ERROR if the value is null under a non-nullable T, or is not a T.