libBeatsaber/include/beatsaber-impl/beatsetimpl.h

34 lines
841 B
C++

#include "beatset.h"
#include <nlohmann/json_fwd.hpp>
using json = nlohmann::json;
#include "filereader.h"
namespace Beatsaber {
class BeatSetImpl : public BeatSet, public std::enable_shared_from_this<BeatSetImpl> {
protected:
std::weak_ptr<BeatMap> parent;
std::shared_ptr<FileReader> reader;
const json& base;
BeatmapCharacteristic::BeatmapCharacteristic characteristic;
std::vector<std::shared_ptr<BeatLevel>> level;
public:
BeatSetImpl(std::weak_ptr<BeatMap> p, std::shared_ptr<FileReader> r, const json& j);
BeatSetImpl(const BeatSetImpl& c) = default;
BeatSetImpl() = default;
virtual ~BeatSetImpl();
bool load();
virtual void printDebug() const override;
virtual BeatmapCharacteristic::BeatmapCharacteristic getCharacteristic() const override;
virtual std::shared_ptr<BeatMap> getBeatMap() const override;
};
}