import_filter

Defined in header: <orcus/interface.hpp>

class import_filter

Base interface for import filters.

Subclassed by orcus::orcus_csv, orcus::orcus_gnumeric, orcus::orcus_ods, orcus::orcus_parquet, orcus::orcus_xls_xml, orcus::orcus_xlsx

Public Functions

import_filter(format_t input)
virtual ~import_filter()
virtual void read_file(const std::filesystem::path &filepath) = 0

Read the content of a file.

Parameters:

filepath – Path to a local file to read the content from.

virtual void read_stream(std::string_view stream) = 0

Read the content of an in-memory stream.

Parameters:

stream – in-memory stream to read from.

virtual std::string_view get_name() const = 0

Get the name of a filter.

Returns:

name of a filter.

void set_config(const orcus::config &v)

Update filter configuration.

Parameters:

v – New configuration to set.

const orcus::config &get_config() const

Get current filter configuration.

Returns:

Reference to currently stored filter configuration.