Orcus
sheet_range.hpp
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This Source Code Form is subject to the terms of the Mozilla Public
4  * License, v. 2.0. If a copy of the MPL was not distributed with this
5  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
6  */
7 
8 #ifndef INCLUDED_ORCUS_SPREADSHEET_SHEET_RANGE_HPP
9 #define INCLUDED_ORCUS_SPREADSHEET_SHEET_RANGE_HPP
10 
11 #include "orcus/env.hpp"
12 #include "orcus/spreadsheet/types.hpp"
13 #include <memory>
14 #include <mdds/multi_type_vector/collection.hpp>
15 #include <ixion/column_store_type.hpp>
16 
17 namespace ixion {
18 
19 class model_context;
20 
21 }
22 
23 namespace orcus { namespace spreadsheet {
24 
25 class sheet;
26 
27 class ORCUS_SPM_DLLPUBLIC sheet_range
28 {
29  typedef mdds::mtv::collection<ixion::column_store_t> columns_type;
30 
31  friend class sheet;
32 
33  struct impl;
34  std::unique_ptr<impl> mp_impl;
35 
37  const ixion::model_context& cxt,
38  const ixion::column_stores_t& stores,
39  row_t row_start, col_t col_start, row_t row_end, col_t col_end);
40 
41 public:
42  typedef columns_type::const_iterator const_row_iterator;
43 
44  sheet_range();
45  sheet_range(const sheet_range& other);
46  sheet_range(sheet_range&& other);
47  ~sheet_range();
48 
49  sheet_range& operator= (sheet_range other);
50 
51  void swap(sheet_range& other);
52 
53  const_row_iterator row_begin() const;
54  const_row_iterator row_end() const;
55 
56  const std::string* get_string(ixion::string_id_t sid) const;
57 };
58 
59 }}
60 
61 #endif
62 
63 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Definition: sheet_range.hpp:28
Definition: sheet.hpp:36