mirror of
https://github.com/aaronpo97/the-biergarten-app.git
synced 2026-06-01 10:04:00 +00:00
* Refactor ApplicationOptions to separate config concerns * add prompt dir app option * readability updates: remove magic numbers, update comments * codebase formatting * Update docs * Extract argument parsing, timer out of
43 lines
1.2 KiB
C++
43 lines
1.2 KiB
C++
#ifndef BIERGARTEN_PIPELINE_INCLUDES_SERVICES_EXPORT_SERVICE_H_
|
|
#define BIERGARTEN_PIPELINE_INCLUDES_SERVICES_EXPORT_SERVICE_H_
|
|
|
|
/**
|
|
* @file services/export_service.h
|
|
* @brief Abstraction for persisting generated brewery data.
|
|
*/
|
|
|
|
#include <cstdint>
|
|
|
|
#include "data_model/generated_brewery.h"
|
|
|
|
/**
|
|
* @brief Interface for services that persist generated brewery records.
|
|
*/
|
|
class IExportService {
|
|
public:
|
|
IExportService() = default;
|
|
|
|
/// @brief Virtual destructor for polymorphic cleanup.
|
|
virtual ~IExportService() = default;
|
|
|
|
IExportService(const IExportService&) = delete;
|
|
IExportService& operator=(const IExportService&) = delete;
|
|
IExportService(IExportService&&) = delete;
|
|
IExportService& operator=(IExportService&&) = delete;
|
|
|
|
/// @brief Prepares the export destination for a new run.
|
|
virtual void Initialize() = 0;
|
|
|
|
/**
|
|
* @brief Persists one generated brewery record.
|
|
*
|
|
* @param brewery Generated brewery payload to store.
|
|
*/
|
|
virtual uint64_t ProcessRecord(const GeneratedBrewery& brewery) = 0;
|
|
|
|
/// @brief Finalizes the export destination.
|
|
virtual void Finalize() = 0;
|
|
};
|
|
|
|
#endif // BIERGARTEN_PIPELINE_INCLUDES_SERVICES_EXPORT_SERVICE_H_
|