LibreOffice Module sc (master) 1
SparklineList.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 */
10
11#pragma once
12
13#include "scdllapi.h"
14#include <memory>
15#include <map>
16
17#include "Sparkline.hxx"
18#include "SparklineGroup.hxx"
19
20namespace sc
21{
28{
29private:
30 std::vector<std::weak_ptr<SparklineGroup>> m_aSparklineGroups;
31 std::map<std::weak_ptr<SparklineGroup>, std::vector<std::weak_ptr<Sparkline>>,
32 std::owner_less<>>
34
35public:
37
38 void addSparkline(std::shared_ptr<Sparkline> const& pSparkline);
39 void removeSparkline(std::shared_ptr<Sparkline> const& pSparkline);
40
41 std::vector<std::shared_ptr<SparklineGroup>> getSparklineGroups();
42
43 std::vector<std::shared_ptr<Sparkline>>
44 getSparklinesFor(std::shared_ptr<SparklineGroup> const& pSparklineGroup);
45};
46
47} // end sc
48
49/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Tracks and gathers all created sparklines and sparkline groups.
std::vector< std::weak_ptr< SparklineGroup > > m_aSparklineGroups
std::map< std::weak_ptr< SparklineGroup >, std::vector< std::weak_ptr< Sparkline > >, std::owner_less<> > m_aSparklineGroupMap
CAUTION! The following defines must be in the same namespace as the respective type.
#define SC_DLLPUBLIC
Definition: scdllapi.h:27