Orcus
Public Member Functions | List of all members
orcus::spreadsheet::import_factory Class Reference
Inheritance diagram for orcus::spreadsheet::import_factory:
orcus::spreadsheet::iface::import_factory

Public Member Functions

 import_factory (document &doc, row_t row_size=1048576, col_t col_size=16384)
 
 import_factory (document &doc, view &view, row_t row_size=1048576, col_t col_size=16384)
 
virtual iface::import_global_settingsget_global_settings () override
 
virtual iface::import_shared_stringsget_shared_strings () override
 
virtual iface::import_stylesget_styles () override
 
virtual iface::import_named_expressionget_named_expression () override
 
virtual iface::import_reference_resolverget_reference_resolver () override
 
virtual iface::import_pivot_cache_definitioncreate_pivot_cache_definition (orcus::spreadsheet::pivot_cache_id_t cache_id) override
 
virtual iface::import_pivot_cache_recordscreate_pivot_cache_records (orcus::spreadsheet::pivot_cache_id_t cache_id) override
 
virtual iface::import_sheetappend_sheet (sheet_t sheet_index, const char *sheet_name, size_t sheet_name_length) override
 
virtual iface::import_sheetget_sheet (const char *sheet_name, size_t sheet_name_length) override
 
virtual iface::import_sheetget_sheet (sheet_t sheet_index) override
 
virtual void finalize () override
 
void set_default_row_size (row_t row_size)
 
void set_default_column_size (col_t col_size)
 
void set_character_set (character_set_t charset)
 
character_set_t get_character_set () const
 

Constructor & Destructor Documentation

◆ ~import_factory()

virtual orcus::spreadsheet::import_factory::~import_factory ( )
virtual

Member Function Documentation

◆ append_sheet()

virtual iface::import_sheet * orcus::spreadsheet::import_factory::append_sheet ( sheet_t  sheet_index,
const char *  sheet_name,
size_t  sheet_name_length 
)
overridevirtual

Append a sheet with specified sheet position index and name.

Parameters
sheet_indexposition index of the sheet to be appended. It is 0-based i.e. the first sheet to be appended will have an index value of 0.
sheet_namepointer to the first character in the buffer where the sheet name is stored.
sheet_name_lengthlength of the sheet name.
Returns
pointer to the sheet instance. It may return nullptr if the client app fails to append a new sheet.

Implements orcus::spreadsheet::iface::import_factory.

◆ create_pivot_cache_definition()

virtual iface::import_pivot_cache_definition * orcus::spreadsheet::import_factory::create_pivot_cache_definition ( orcus::spreadsheet::pivot_cache_id_t  cache_id)
overridevirtual

Create an interface for pivot cache definition import for a specified cache ID. In case a pivot cache alrady exists for the passed ID, the client app should overwrite the existing cache with a brand-new cache instance.

Parameters
cache_idnumeric ID associated with the pivot cache.
Returns
pointer to the pivot cache interface instance. If may return NULL if the client app doesn't support pivot tables.

Reimplemented from orcus::spreadsheet::iface::import_factory.

◆ create_pivot_cache_records()

virtual iface::import_pivot_cache_records * orcus::spreadsheet::import_factory::create_pivot_cache_records ( orcus::spreadsheet::pivot_cache_id_t  cache_id)
overridevirtual

Create an interface for pivot cache records import for a specified cache ID.

Parameters
cache_idnumeric ID associated with the pivot cache.
Returns
pointer to the pivot cache records interface instance. If may return nullptr if the client app doesn't support pivot tables.

Reimplemented from orcus::spreadsheet::iface::import_factory.

◆ finalize()

virtual void orcus::spreadsheet::import_factory::finalize ( )
overridevirtual

This method is called at the end of import, to give the implementor a chance to perform post-processing if necessary.

Implements orcus::spreadsheet::iface::import_factory.

◆ get_global_settings()

virtual iface::import_global_settings * orcus::spreadsheet::import_factory::get_global_settings ( )
overridevirtual

◆ get_named_expression()

virtual iface::import_named_expression * orcus::spreadsheet::import_factory::get_named_expression ( )
overridevirtual

◆ get_reference_resolver()

virtual iface::import_reference_resolver * orcus::spreadsheet::import_factory::get_reference_resolver ( )
overridevirtual

◆ get_shared_strings()

virtual iface::import_shared_strings * orcus::spreadsheet::import_factory::get_shared_strings ( )
overridevirtual
Returns
pointer to the shared strings instance. It may return NULL if the client app doesn't support shared strings.

Reimplemented from orcus::spreadsheet::iface::import_factory.

◆ get_sheet() [1/2]

virtual iface::import_sheet * orcus::spreadsheet::import_factory::get_sheet ( const char *  sheet_name,
size_t  sheet_name_length 
)
overridevirtual
Returns
pointer to the sheet instance whose name matches the name passed to this method. It returns nullptr if no sheet instance exists by the specified name.

Implements orcus::spreadsheet::iface::import_factory.

◆ get_sheet() [2/2]

virtual iface::import_sheet * orcus::spreadsheet::import_factory::get_sheet ( sheet_t  sheet_index)
overridevirtual

Retrieve sheet instance by specified numerical sheet index.

Parameters
sheet_indexsheet index
Returns
pointer to the sheet instance, or nullptr if no sheet instance exists at specified sheet index position.

Implements orcus::spreadsheet::iface::import_factory.

◆ get_styles()

virtual iface::import_styles * orcus::spreadsheet::import_factory::get_styles ( )
overridevirtual
Returns
pointer to the styles instance. It may return NULL if the client app doesn't support styles.

Reimplemented from orcus::spreadsheet::iface::import_factory.