ADBC
Arrow 資料庫連線能力
載入中...
搜尋中...
找不到相符項目
目錄工具

類別

struct  adbc::driver::GetObjectsHelper
 實作 GetObjects 的輔助工具。 更多...
 
struct  adbc::driver::GetObjectsHelper::Table
 
struct  adbc::driver::GetObjectsHelper::ColumnXdbc
 
struct  adbc::driver::GetObjectsHelper::Column
 
struct  adbc::driver::GetObjectsHelper::ConstraintUsage
 
struct  adbc::driver::GetObjectsHelper::Constraint
 
struct  adbc::driver::InfoValue
 要從 AdbcConnectionGetInfo() 傳回的陣列中單一項目的表示法。 更多...
 

列舉

enum class  adbc::driver::GetObjectsDepth { kCatalogs , kSchemas , kTables , kColumns }
 GetObjects 層級。 更多...
 

函式

Status adbc::driver::MakeGetObjectsSchema (ArrowSchema *schema)
 AdbcConnectionGetObjects() 建立 ArrowSchema。
 
Status adbc::driver::GetObjectsHelper::Close ()
 
virtual Status adbc::driver::GetObjectsHelper::Load (GetObjectsDepth depth, std::optional< std::string_view > catalog_filter, std::optional< std::string_view > schema_filter, std::optional< std::string_view > table_filter, std::optional< std::string_view > column_filter, const std::vector< std::string_view > &table_types)
 擷取所有需要的中繼資料。驅動程式可以延遲載入,但這讓它有機會預先載入資料。
 
virtual Status adbc::driver::GetObjectsHelper::LoadCatalogs (std::optional< std::string_view > catalog_filter)
 
virtual Result< std::optional< std::string_view > > adbc::driver::GetObjectsHelper::NextCatalog ()
 
virtual Status adbc::driver::GetObjectsHelper::LoadSchemas (std::string_view catalog, std::optional< std::string_view > schema_filter)
 
virtual Result< std::optional< std::string_view > > adbc::driver::GetObjectsHelper::NextSchema ()
 
virtual Status adbc::driver::GetObjectsHelper::LoadTables (std::string_view catalog, std::string_view schema, std::optional< std::string_view > table_filter, const std::vector< std::string_view > &table_types)
 
virtual Result< std::optional< Table > > adbc::driver::GetObjectsHelper::NextTable ()
 
virtual Status adbc::driver::GetObjectsHelper::LoadColumns (std::string_view catalog, std::string_view schema, std::string_view table, std::optional< std::string_view > column_filter)
 
virtual Result< std::optional< Column > > adbc::driver::GetObjectsHelper::NextColumn ()
 
virtual Result< std::optional< Constraint > > adbc::driver::GetObjectsHelper::NextConstraint ()
 
Status adbc::driver::BuildGetObjects (GetObjectsHelper *helper, GetObjectsDepth depth, std::optional< std::string_view > catalog_filter, std::optional< std::string_view > schema_filter, std::optional< std::string_view > table_filter, std::optional< std::string_view > column_filter, const std::vector< std::string_view > &table_types, ArrowArrayStream *out)
 實作 GetObjects 的輔助工具。 out/helper 的生命週期由呼叫者管理。
 
void adbc::driver::MakeEmptyStream (ArrowSchema *schema, ArrowArrayStream *out)
 從給定的 ArrowSchema 建立具有零批次的 ArrowArrayStream。
 
void adbc::driver::MakeArrayStream (ArrowSchema *schema, ArrowArray *array, ArrowArrayStream *out)
 從給定的 ArrowSchema 和 ArrowArray 建立 ArrowArrayStream。
 
Status adbc::driver::MakeTableTypesStream (const std::vector< std::string > &table_types, ArrowArrayStream *out)
 建立表格類型向量的 ArrowArrayStream 表示法。
 
Status adbc::driver::MakeGetInfoStream (const std::vector< InfoValue > &infos, ArrowArrayStream *out)
 建立要從 AdbcConnectionGetInfo() 傳回的 ArrowArrayStream。
 

變數

std::string_view adbc::driver::GetObjectsHelper::Table::name
 
std::string_view adbc::driver::GetObjectsHelper::Table::type
 
std::optional< int16_t > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_data_type
 
std::optional< std::string_view > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_type_name
 
std::optional< int32_t > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_column_size
 
std::optional< int16_t > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_decimal_digits
 
std::optional< int16_t > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_num_prec_radix
 
std::optional< int16_t > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_nullable
 
std::optional< std::string_view > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_column_def
 
std::optional< int16_t > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_sql_data_type
 
std::optional< int16_t > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_datetime_sub
 
std::optional< int32_t > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_char_octet_length
 
std::optional< std::string_view > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_is_nullable
 
std::optional< std::string_view > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_scope_catalog
 
std::optional< std::string_view > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_scope_schema
 
std::optional< std::string_view > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_scope_table
 
std::optional< bool > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_is_autoincrement
 
std::optional< bool > adbc::driver::GetObjectsHelper::ColumnXdbc::xdbc_is_generatedcolumn
 
std::string_view adbc::driver::GetObjectsHelper::Column::column_name
 
int32_t adbc::driver::GetObjectsHelper::Column::ordinal_position
 
std::optional< std::string_view > adbc::driver::GetObjectsHelper::Column::remarks
 
std::optional< ColumnXdbcadbc::driver::GetObjectsHelper::Column::xdbc
 
std::optional< std::string_view > adbc::driver::GetObjectsHelper::ConstraintUsage::catalog
 
std::optional< std::string_view > adbc::driver::GetObjectsHelper::ConstraintUsage::schema
 
std::string_view adbc::driver::GetObjectsHelper::ConstraintUsage::table
 
std::string_view adbc::driver::GetObjectsHelper::ConstraintUsage::column
 
std::optional< std::string_view > adbc::driver::GetObjectsHelper::Constraint::name
 
std::string_view adbc::driver::GetObjectsHelper::Constraint::type
 
std::vector< std::string_view > adbc::driver::GetObjectsHelper::Constraint::column_names
 
std::optional< std::vector< ConstraintUsage > > adbc::driver::GetObjectsHelper::Constraint::usage
 

詳細說明

用於實作目錄/中繼資料相關功能的工具。


類別文件

◆ adbc::driver::GetObjectsHelper

struct adbc::driver::GetObjectsHelper

實作 GetObjects 的輔助工具。

驅動程式可以在驅動程式特定的類別中實作 GetObjectsHelper 的方法,以取得 AdbcConnectionGetObjects() 的相容實作。

公開成員函式

Status Close ()
 
virtual Status Load (GetObjectsDepth depth, std::optional< std::string_view > catalog_filter, std::optional< std::string_view > schema_filter, std::optional< std::string_view > table_filter, std::optional< std::string_view > column_filter, const std::vector< std::string_view > &table_types)
 擷取所有需要的中繼資料。驅動程式可以延遲載入,但這讓它有機會預先載入資料。
 
virtual Status LoadCatalogs (std::optional< std::string_view > catalog_filter)
 
virtual Result< std::optional< std::string_view > > NextCatalog ()
 
virtual Status LoadSchemas (std::string_view catalog, std::optional< std::string_view > schema_filter)
 
virtual Result< std::optional< std::string_view > > NextSchema ()
 
virtual Status LoadTables (std::string_view catalog, std::string_view schema, std::optional< std::string_view > table_filter, const std::vector< std::string_view > &table_types)
 
virtual Result< std::optional< Table > > NextTable ()
 
virtual Status LoadColumns (std::string_view catalog, std::string_view schema, std::string_view table, std::optional< std::string_view > column_filter)
 
virtual Result< std::optional< Column > > NextColumn ()
 
virtual Result< std::optional< Constraint > > NextConstraint ()
 

◆ adbc::driver::GetObjectsHelper::Table

struct adbc::driver::GetObjectsHelper::Table

公開屬性

std::string_view name
 
std::string_view type
 

◆ adbc::driver::GetObjectsHelper::ColumnXdbc

struct adbc::driver::GetObjectsHelper::ColumnXdbc

公開屬性

std::optional< int16_t > xdbc_data_type
 
std::optional< std::string_view > xdbc_type_name
 
std::optional< int32_t > xdbc_column_size
 
std::optional< int16_t > xdbc_decimal_digits
 
std::optional< int16_t > xdbc_num_prec_radix
 
std::optional< int16_t > xdbc_nullable
 
std::optional< std::string_view > xdbc_column_def
 
std::optional< int16_t > xdbc_sql_data_type
 
std::optional< int16_t > xdbc_datetime_sub
 
std::optional< int32_t > xdbc_char_octet_length
 
std::optional< std::string_view > xdbc_is_nullable
 
std::optional< std::string_view > xdbc_scope_catalog
 
std::optional< std::string_view > xdbc_scope_schema
 
std::optional< std::string_view > xdbc_scope_table
 
std::optional< bool > xdbc_is_autoincrement
 
std::optional< bool > xdbc_is_generatedcolumn
 

◆ adbc::driver::GetObjectsHelper::Column

struct adbc::driver::GetObjectsHelper::Column

公開屬性

std::string_view column_name
 
int32_t ordinal_position
 
std::optional< std::string_view > remarks
 
std::optional< ColumnXdbcxdbc
 

◆ adbc::driver::GetObjectsHelper::ConstraintUsage

struct adbc::driver::GetObjectsHelper::ConstraintUsage

公開屬性

std::optional< std::string_view > catalog
 
std::optional< std::string_view > schema
 
std::string_view table
 
std::string_view column
 

◆ adbc::driver::GetObjectsHelper::Constraint

struct adbc::driver::GetObjectsHelper::Constraint

公開屬性

std::optional< std::string_view > name
 
std::string_view type
 
std::vector< std::string_view > column_names
 
std::optional< std::vector< ConstraintUsage > > usage
 

◆ adbc::driver::InfoValue

struct adbc::driver::InfoValue

要從 AdbcConnectionGetInfo() 傳回的陣列中單一項目的表示法。

公開成員函式

 InfoValue (uint32_t code, std::variant< std::string, int64_t > value)
 
 InfoValue (uint32_t code, const char *value)
 

公開屬性

uint32_t code
 
std::variant< std::string, int64_t > value
 

列舉類型文件

◆ GetObjectsDepth

enum class adbc::driver::GetObjectsDepth
strong

GetObjects 層級。

函式文件

◆ BuildGetObjects()

Status adbc::driver::BuildGetObjects ( GetObjectsHelper * helper,
GetObjectsDepth depth,
std::optional< std::string_view > catalog_filter,
std::optional< std::string_view > schema_filter,
std::optional< std::string_view > table_filter,
std::optional< std::string_view > column_filter,
const std::vector< std::string_view > & table_types,
ArrowArrayStream * out )

實作 GetObjects 的輔助工具。 out/helper 的生命週期由呼叫者管理。

◆ Load()

virtual Status adbc::driver::GetObjectsHelper::Load ( GetObjectsDepth depth,
std::optional< std::string_view > catalog_filter,
std::optional< std::string_view > schema_filter,
std::optional< std::string_view > table_filter,
std::optional< std::string_view > column_filter,
const std::vector< std::string_view > & table_types )
inlinevirtual

擷取所有需要的中繼資料。驅動程式可以延遲載入,但這讓它有機會預先載入資料。

◆ MakeArrayStream()

void adbc::driver::MakeArrayStream ( ArrowSchema * schema,
ArrowArray * array,
ArrowArrayStream * out )

從給定的 ArrowSchema 和 ArrowArray 建立 ArrowArrayStream。

如果陣列長度為零,則產生的 ArrowArrayStream 將包含零批次;如果陣列長度不為零,則包含正好一批次。此函式取得 schema 和 array 的擁有權;呼叫者負責釋放 out。

◆ MakeEmptyStream()

void adbc::driver::MakeEmptyStream ( ArrowSchema * schema,
ArrowArrayStream * out )

從給定的 ArrowSchema 建立具有零批次的 ArrowArrayStream。

此函式取得 schema 的擁有權;呼叫者負責釋放 out。

◆ MakeGetInfoStream()

Status adbc::driver::MakeGetInfoStream ( const std::vector< InfoValue > & infos,
ArrowArrayStream * out )

建立要從 AdbcConnectionGetInfo() 傳回的 ArrowArrayStream。

呼叫者負責在成功時釋放 out。

◆ MakeGetObjectsSchema()

Status adbc::driver::MakeGetObjectsSchema ( ArrowSchema * schema)

AdbcConnectionGetObjects() 建立 ArrowSchema。

◆ MakeTableTypesStream()

Status adbc::driver::MakeTableTypesStream ( const std::vector< std::string > & table_types,
ArrowArrayStream * out )

建立表格類型向量的 ArrowArrayStream 表示法。

建立表格類型陣列的 ArrowArrayStream 表示法,可用於實作 AdbcConnectionGetTableTypes()。呼叫者負責在成功時釋放 out。