myTinySQL v0.2.0-2-g5000098
A tiny SQL interpreter over fixed-width text files
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
tinysql::Column Struct Reference

One column of a table: the characters it occupies in every fixed-width row. More...

#include <Catalog.hpp>

Public Member Functions

std::size_t width () const
 Number of characters the column occupies.
 

Public Attributes

std::string name
 Column name, e.g. NOME.
 
std::string type
 N1 or S1: recorded in SYSTEM_TABLE, not enforced.
 
std::size_t from = 0
 First character of the column in a row, counted from 0.
 
std::size_t to = 0
 Last character of the column, inclusive.
 

Detailed Description

One column of a table: the characters it occupies in every fixed-width row.

Definition at line 19 of file Catalog.hpp.

Member Function Documentation

◆ width()

std::size_t tinysql::Column::width ( ) const
inline

Number of characters the column occupies.

Returns
to - from + 1.

Definition at line 27 of file Catalog.hpp.

Member Data Documentation

◆ from

std::size_t tinysql::Column::from = 0

First character of the column in a row, counted from 0.

Definition at line 22 of file Catalog.hpp.

◆ name

std::string tinysql::Column::name

Column name, e.g. NOME.

Definition at line 20 of file Catalog.hpp.

◆ to

std::size_t tinysql::Column::to = 0

Last character of the column, inclusive.

Definition at line 23 of file Catalog.hpp.

◆ type

std::string tinysql::Column::type

N1 or S1: recorded in SYSTEM_TABLE, not enforced.

Definition at line 21 of file Catalog.hpp.


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