Horizon
Loading...
Searching...
No Matches
stock_info_provider.hpp
1#pragma once
2#include <gtkmm.h>
3#include <memory>
4#include <list>
5#include "util/uuid.hpp"
6
7namespace horizon {
8
10public:
11 virtual void append(const StockInfoRecord &other)
12 {
13 }
14 virtual const UUID &get_uuid() const = 0;
15 virtual ~StockInfoRecord()
16 {
17 }
18};
19
21public:
22 virtual void add_columns(Gtk::TreeView *treeview,
23 Gtk::TreeModelColumn<std::shared_ptr<StockInfoRecord>> column) = 0;
24 virtual Gtk::Widget *create_status_widget() = 0;
25 virtual void update_parts(const std::list<UUID> &parts) = 0;
26 virtual std::list<std::shared_ptr<StockInfoRecord>> get_records() = 0;
27 virtual ~StockInfoProvider()
28 {
29 }
30 Glib::Dispatcher dispatcher;
31
32 static std::unique_ptr<StockInfoProvider> create(const std::string &pool_base_path);
33 static void init_db();
34 static void cleanup();
35};
36
37
38} // namespace horizon
Definition stock_info_provider.hpp:20
Definition stock_info_provider.hpp:9
This class encapsulates a UUID and allows it to be uses as a value type.
Definition uuid.hpp:16