|
iceberg-cpp
|
A data type that has child fields. More...
#include <type.h>
Public Types | |
| using | SchemaFieldConstRef = std::reference_wrapper< const SchemaField > |
Public Member Functions | |
| bool | is_primitive () const override |
| Is this a primitive type (may not have child fields)? | |
| bool | is_nested () const override |
| Is this a nested type (may have child fields)? | |
| virtual std::span< const SchemaField > | fields () const =0 |
| Get a view of the child fields. | |
| virtual Result< std::optional< SchemaFieldConstRef > > | GetFieldById (int32_t field_id) const =0 |
| Get a field by field ID. | |
| virtual Result< std::optional< SchemaFieldConstRef > > | GetFieldByIndex (int32_t index) const =0 |
| Get a field by index. | |
| virtual Result< std::optional< SchemaFieldConstRef > > | GetFieldByName (std::string_view name, bool case_sensitive) const =0 |
| Get a field by name. Return an error Status if the field name is not unique; prefer GetFieldById or GetFieldByIndex when possible. | |
| Result< std::optional< SchemaFieldConstRef > > | GetFieldByName (std::string_view name) const |
| Get a field by name (case-sensitive). | |
Public Member Functions inherited from iceberg::Type | |
| virtual TypeId | type_id () const =0 |
| Get the type ID. | |
Public Member Functions inherited from iceberg::util::Formattable | |
| virtual std::string | ToString () const =0 |
| Get a user-readable string representation. | |
Additional Inherited Members | |
Protected Member Functions inherited from iceberg::Type | |
| virtual bool | Equals (const Type &other) const =0 |
| Compare two types for equality. | |
A data type that has child fields.
|
pure virtual |
Get a view of the child fields.
Implemented in iceberg::StructType, iceberg::ListType, and iceberg::MapType.
|
pure virtual |
Get a field by field ID.
Implemented in iceberg::StructType, iceberg::ListType, and iceberg::MapType.
|
pure virtual |
Get a field by index.
Implemented in iceberg::StructType, iceberg::ListType, and iceberg::MapType.
|
pure virtual |
Get a field by name. Return an error Status if the field name is not unique; prefer GetFieldById or GetFieldByIndex when possible.
Implemented in iceberg::StructType, iceberg::ListType, iceberg::MapType, iceberg::StructType, iceberg::ListType, and iceberg::MapType.
|
inlineoverridevirtual |
Is this a nested type (may have child fields)?
Implements iceberg::Type.
|
inlineoverridevirtual |
Is this a primitive type (may not have child fields)?
Implements iceberg::Type.