8 #ifndef INCLUDED_ORCUS_SPREADSHEET_PIVOT_HPP 9 #define INCLUDED_ORCUS_SPREADSHEET_PIVOT_HPP 11 #include "orcus/env.hpp" 12 #include "orcus/pstring.hpp" 13 #include "orcus/types.hpp" 14 #include "orcus/spreadsheet/types.hpp" 20 #include <boost/optional.hpp> 32 namespace spreadsheet {
36 using pivot_cache_indices_t = std::vector<size_t>;
81 size_t shared_item_index;
96 using pivot_cache_record_t = std::vector<pivot_cache_record_value_t>;
102 unknown = 0, boolean, date_time, character, numeric, blank, error
156 using pivot_cache_items_t = std::vector<pivot_cache_item_t>;
165 pivot_cache_group_by_t group_by = pivot_cache_group_by_t::range;
167 bool auto_start =
true;
168 bool auto_end =
true;
172 double interval = 1.0;
186 boost::optional<range_grouping_type> range_grouping;
211 pivot_cache_items_t items;
213 boost::optional<double> min_value;
214 boost::optional<double> max_value;
216 boost::optional<date_time_t> min_date;
217 boost::optional<date_time_t> max_date;
219 std::unique_ptr<pivot_cache_group_data_t> group_data;
230 std::unique_ptr<impl> mp_impl;
233 using fields_type = std::vector<pivot_cache_field_t>;
234 using records_type = std::vector<pivot_cache_record_t>;
245 void insert_fields(fields_type fields);
247 void insert_records(records_type record);
249 size_t get_field_count()
const;
261 pivot_cache_id_t get_id()
const;
263 const records_type& get_all_records()
const;
269 std::unique_ptr<impl> mp_impl;
283 void insert_worksheet_cache(
284 const pstring& sheet_name,
const ixion::abs_range_t& range, std::unique_ptr<pivot_cache>&& cache);
292 void insert_worksheet_cache(
const pstring& table_name, std::unique_ptr<pivot_cache>&& cache);
299 size_t get_cache_count()
const;
302 const pstring& sheet_name,
const ixion::abs_range_t& range)
const;
306 const pivot_cache* get_cache(pivot_cache_id_t cache_id)
const;
Definition: pstring.hpp:27
Definition: types.hpp:444
Definition: pivot.hpp:266
Definition: pivot.hpp:163
Definition: document.hpp:47
size_t base_field
Definition: pivot.hpp:194
pivot_cache_indices_t base_to_group_indices
Definition: pivot.hpp:184
Definition: document.hpp:18
Definition: pivot.hpp:161
pivot_cache_items_t items
Definition: pivot.hpp:191
Definition: string_pool.hpp:23
Definition: pivot.hpp:203
Definition: pivot.hpp:227
Definition: base64.hpp:15
pstring name
Definition: pivot.hpp:209