Hyper API for C++ 0.0.18825
Hyper client library for C++ applications
Loading...
Searching...
No Matches
hyperapi::Row Class Referencefinal

A Row inside a chunk. More...

#include <Result.hpp>

Public Member Functions

template<typename ReturnType = Value>
ReturnType get (hyper_field_index_t columnIndex) const
 Returns the value of field at position columnIndex.
 
const ResultSchemagetSchema () const noexcept
 Returns the schema of the row.
 

Detailed Description

A Row inside a chunk.

The row is only valid for as long as the chunk lives.

Examples
read_and_print_data_from_existing_hyper_file.cpp, and update_data_in_existing_hyper_file.cpp.

Definition at line 209 of file Result.hpp.

Member Function Documentation

◆ get()

template<typename ReturnType = Value>
ReturnType hyperapi::Row::get ( hyper_field_index_t  columnIndex) const

Returns the value of field at position columnIndex.

Example: int a = row.get(); Example: auto a = row.get<int>();

Parameters
columnIndexThe index of the field inside the row (starting at 0).
Returns
The value of type Value. The returned value implicitly casts to all types.
See also
hyperapi::Value::get()
Precondition
The requested type is compatible to the column type.

◆ getSchema()

const ResultSchema & hyperapi::Row::getSchema ( ) const
noexcept

Returns the schema of the row.

Returns
The result schema.
Precondition
isOpen()

The documentation for this class was generated from the following file: