///
/// HybridOneCalendarSpec.hpp
/// This file was generated by nitrogen. DO NOT MODIFY THIS FILE.
/// https://github.com/mrousavy/nitro
/// Copyright © Marc Rousavy @ Margelo
///

#pragma once

#if __has_include(<NitroModules/HybridObject.hpp>)
#include <NitroModules/HybridObject.hpp>
#else
#error NitroModules cannot be found! Are you sure you installed NitroModules properly?
#endif

// Forward declaration of `CalendarPermissionStatus` to properly resolve imports.
namespace margelo::nitro::one { enum class CalendarPermissionStatus; }
// Forward declaration of `CalendarEvent` to properly resolve imports.
namespace margelo::nitro::one { struct CalendarEvent; }
// Forward declaration of `CalendarEventInput` to properly resolve imports.
namespace margelo::nitro::one { struct CalendarEventInput; }
// Forward declaration of `CalendarEventChanges` to properly resolve imports.
namespace margelo::nitro::one { struct CalendarEventChanges; }
// Forward declaration of `ReminderInfo` to properly resolve imports.
namespace margelo::nitro::one { struct ReminderInfo; }
// Forward declaration of `ReminderInput` to properly resolve imports.
namespace margelo::nitro::one { struct ReminderInput; }

#include "CalendarPermissionStatus.hpp"
#include <NitroModules/Promise.hpp>
#include "CalendarEvent.hpp"
#include <vector>
#include <string>
#include "CalendarEventInput.hpp"
#include "CalendarEventChanges.hpp"
#include "ReminderInfo.hpp"
#include "ReminderInput.hpp"

namespace margelo::nitro::one {

  using namespace margelo::nitro;

  /**
   * An abstract base class for `OneCalendar`
   * Inherit this class to create instances of `HybridOneCalendarSpec` in C++.
   * You must explicitly call `HybridObject`'s constructor yourself, because it is virtual.
   * @example
   * ```cpp
   * class HybridOneCalendar: public HybridOneCalendarSpec {
   * public:
   *   HybridOneCalendar(...): HybridObject(TAG) { ... }
   *   // ...
   * };
   * ```
   */
  class HybridOneCalendarSpec: public virtual HybridObject {
    public:
      // Constructor
      explicit HybridOneCalendarSpec(): HybridObject(TAG) { }

      // Destructor
      ~HybridOneCalendarSpec() override = default;

    public:
      // Properties
      

    public:
      // Methods
      virtual CalendarPermissionStatus getPermissionStatus() = 0;
      virtual std::shared_ptr<Promise<CalendarPermissionStatus>> requestPermission() = 0;
      virtual std::shared_ptr<Promise<std::vector<CalendarEvent>>> list(double startMs, double endMs, double limit) = 0;
      virtual std::shared_ptr<Promise<std::string>> create(const CalendarEventInput& input) = 0;
      virtual std::shared_ptr<Promise<CalendarEvent>> update(const std::string& identifier, double originalStartMs, const CalendarEventChanges& changes) = 0;
      virtual std::shared_ptr<Promise<void>> remove(const std::string& identifier, double startMs) = 0;
      virtual CalendarPermissionStatus getRemindersPermissionStatus() = 0;
      virtual std::shared_ptr<Promise<CalendarPermissionStatus>> requestRemindersPermission() = 0;
      virtual std::shared_ptr<Promise<std::vector<ReminderInfo>>> listReminders(double limit, bool includeCompleted) = 0;
      virtual std::shared_ptr<Promise<std::string>> createReminder(const ReminderInput& input) = 0;
      virtual std::shared_ptr<Promise<void>> setReminderCompleted(const std::string& identifier, bool completed) = 0;
      virtual std::shared_ptr<Promise<void>> removeReminder(const std::string& identifier) = 0;

    protected:
      // Hybrid Setup
      void loadHybridMethods() override;

    protected:
      // Tag for logging
      static constexpr auto TAG = "OneCalendar";
  };

} // namespace margelo::nitro::one
