subsurface/core/divelog.h
Berthold Stoeger 73f2605ab1 core: remove device C access code
This was used from C, so there was lots of access code, which is
not necessary.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2024-08-13 19:28:30 +02:00

34 lines
778 B
C++

// SPDX-License-Identifier: GPL-2.0
// A structure that contains all the data we store in a divelog files
#ifndef DIVELOG_H
#define DIVELOG_H
#include <memory>
#include <vector>
struct dive_table;
struct trip_table;
class dive_site_table;
struct device;
struct filter_preset_table;
struct divelog {
std::unique_ptr<dive_table> dives;
std::unique_ptr<trip_table> trips;
std::unique_ptr<dive_site_table> sites;
std::vector<device> devices;
std::unique_ptr<filter_preset_table> filter_presets;
bool autogroup;
divelog();
~divelog();
divelog(divelog &&); // move constructor (argument is consumed).
divelog &operator=(divelog &&); // move assignment (argument is consumed).
void delete_single_dive(int idx);
void clear();
};
extern struct divelog divelog;
#endif