Signet Forge 0.1.0
C++20 Parquet library with AI-native extensions
DEMO
Loading...
Searching...
No Matches
signet::forge::Column< T > Struct Template Reference

Typed column descriptor for the Schema::build() variadic API. More...

#include <schema.hpp>

Public Member Functions

 Column (std::string n)
 Construct a column with a name only (logical type auto-deduced for strings).
 
 Column (std::string n, LogicalType lt)
 Construct a column with an explicit logical type.
 
ColumnDescriptor to_descriptor () const
 Convert to a ColumnDescriptor for Schema construction.
 

Public Attributes

std::string name
 Column name.
 
LogicalType logical_type = LogicalType::NONE
 Optional logical annotation.
 

Detailed Description

template<typename T>
struct signet::forge::Column< T >

Typed column descriptor for the Schema::build() variadic API.

Deduces the Parquet PhysicalType from the C++ template parameter T. For std::string, the LogicalType defaults to STRING unless overridden.

auto schema = Schema::build("trades",
Column<double>{"price"},
Column<std::string>{"symbol"});
static Schema build(std::string name, Cols &&... cols)
Build a Schema from typed Column<T> descriptors (variadic factory).
Definition schema.hpp:217
@ TIMESTAMP_NS
Timestamp — INT64, nanoseconds since Unix epoch.
Typed column descriptor for the Schema::build() variadic API.
Definition schema.hpp:39
Template Parameters
TC++ type mapped to a Parquet PhysicalType via parquet_type_of.
See also
Schema::build(), SchemaBuilder, ColumnDescriptor

Definition at line 39 of file schema.hpp.

Constructor & Destructor Documentation

◆ Column() [1/2]

template<typename T >
signet::forge::Column< T >::Column ( std::string  n)
inline

Construct a column with a name only (logical type auto-deduced for strings).

Parameters
nColumn name.

Definition at line 45 of file schema.hpp.

◆ Column() [2/2]

template<typename T >
signet::forge::Column< T >::Column ( std::string  n,
LogicalType  lt 
)
inline

Construct a column with an explicit logical type.

Parameters
nColumn name.
ltLogical type annotation (NONE falls through to auto-deduction).

Definition at line 52 of file schema.hpp.

Member Function Documentation

◆ to_descriptor()

template<typename T >
ColumnDescriptor signet::forge::Column< T >::to_descriptor ( ) const
inline

Convert to a ColumnDescriptor for Schema construction.

Returns
A ColumnDescriptor with physical type deduced from T.

Definition at line 60 of file schema.hpp.

Member Data Documentation

◆ logical_type

template<typename T >
LogicalType signet::forge::Column< T >::logical_type = LogicalType::NONE

Optional logical annotation.

Definition at line 41 of file schema.hpp.

◆ name

template<typename T >
std::string signet::forge::Column< T >::name

Column name.

Definition at line 40 of file schema.hpp.


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