◆ GetChildTypes()
140607 {
140608 D_ASSERT(type.id() == LogicalTypeId::STRUCT || type.id() == LogicalTypeId::UNION ||
140609 type.id() == LogicalTypeId::VARIANT);
140610
140611 auto info = type.AuxInfo();
140612 D_ASSERT(info);
140613 return info->Cast<StructTypeInfo>().child_types;
140614}
◆ GetChildType()
140616 {
140617 auto &child_types = StructType::GetChildTypes(type);
140618 D_ASSERT(index < child_types.size());
140619 return child_types[
index].second;
140620}
◆ GetChildName()
| const string & duckdb::StructType::GetChildName |
( |
const LogicalType & | type, |
|
|
idx_t | index ) |
|
static |
140622 {
140623 auto &child_types = StructType::GetChildTypes(type);
140624 D_ASSERT(index < child_types.size());
140625 return child_types[
index].first;
140626}
◆ GetChildIndexUnsafe()
| idx_t duckdb::StructType::GetChildIndexUnsafe |
( |
const LogicalType & | type, |
|
|
const string & | name ) |
|
static |
140628 {
140629 auto &child_types = StructType::GetChildTypes(type);
140630 for (
idx_t i = 0; i < child_types.size(); i++) {
140632 return i;
140633 }
140634 }
140635 throw InternalException("Could not find child with name \"%s\" in struct type \"%s\"", name, type.ToString());
140636}
static DUCKDB_API bool CIEquals(const string &l1, const string &l2)
Case insensitive equals.
Definition duckdb.cpp:109696
uint64_t idx_t
a saner size_t for loop indices etc
Definition duckdb.hpp:237
◆ GetChildCount()
140638 {
140639 return StructType::GetChildTypes(type).size();
140640}
◆ IsUnnamed()
| bool duckdb::StructType::IsUnnamed |
( |
const LogicalType & | type | ) |
|
|
static |
140641 {
140642 auto &child_types = StructType::GetChildTypes(type);
140643 if (child_types.empty()) {
140644 return false;
140645 }
140646 return child_types[0].first.empty();
140647}
The documentation for this struct was generated from the following files: