Orcus
Loading...
Searching...
No Matches
orcus::spreadsheet::pivot_collection Class Reference

Public Member Functions

 pivot_collection (document &doc)
 
 pivot_collection (const pivot_collection &)=delete
 
void insert_worksheet_cache (std::string_view sheet_name, const ixion::abs_range_t &range, std::unique_ptr< pivot_cache > &&cache)
 
void insert_worksheet_cache (std::string_view table_name, std::unique_ptr< pivot_cache > &&cache)
 
void insert_pivot_table (pivot_table pt)
 
size_t get_cache_count () const
 
const pivot_cacheget_cache (std::string_view sheet_name, const ixion::abs_range_t &range) const
 
pivot_cacheget_cache (pivot_cache_id_t cache_id)
 
const pivot_cacheget_cache (pivot_cache_id_t cache_id) const
 
void dump_debug_state (std::string_view outdir) const
 

Member Function Documentation

◆ get_cache_count()

size_t orcus::spreadsheet::pivot_collection::get_cache_count ( ) const

Count the number of pivot caches currently stored.

Returns
number of pivot caches currently stored in the document.

◆ insert_worksheet_cache() [1/2]

void orcus::spreadsheet::pivot_collection::insert_worksheet_cache ( std::string_view sheet_name,
const ixion::abs_range_t & range,
std::unique_ptr< pivot_cache > && cache )

Insert a new pivot cache associated with a worksheet source.

Parameters
sheet_namename of the sheet where the source data is.
rangerange of the source data. Note that the sheet indices are not used.
cachepivot cache instance to store.

◆ insert_worksheet_cache() [2/2]

void orcus::spreadsheet::pivot_collection::insert_worksheet_cache ( std::string_view table_name,
std::unique_ptr< pivot_cache > && cache )

Insert a new pivot cache associated with a table name.

Parameters
table_namesource table name.
cachepivot cache instance to store.