///
/// HybridOneNotificationsSpec.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 `NativePermissionResponse` to properly resolve imports.
namespace margelo::nitro::one { struct NativePermissionResponse; }
// Forward declaration of `NativePermissionRequest` to properly resolve imports.
namespace margelo::nitro::one { struct NativePermissionRequest; }
// Forward declaration of `NativeNotificationCategory` to properly resolve imports.
namespace margelo::nitro::one { struct NativeNotificationCategory; }
// Forward declaration of `NativeChannel` to properly resolve imports.
namespace margelo::nitro::one { struct NativeChannel; }
// Forward declaration of `NativeChannelInput` to properly resolve imports.
namespace margelo::nitro::one { struct NativeChannelInput; }
// Forward declaration of `NativeScheduleInput` to properly resolve imports.
namespace margelo::nitro::one { struct NativeScheduleInput; }
// Forward declaration of `NativeNotificationRequest` to properly resolve imports.
namespace margelo::nitro::one { struct NativeNotificationRequest; }
// Forward declaration of `NativeNotification` to properly resolve imports.
namespace margelo::nitro::one { struct NativeNotification; }
// Forward declaration of `NativePushToken` to properly resolve imports.
namespace margelo::nitro::one { struct NativePushToken; }
// Forward declaration of `NativeNotificationResponse` to properly resolve imports.
namespace margelo::nitro::one { struct NativeNotificationResponse; }
// Forward declaration of `NotificationBehavior` to properly resolve imports.
namespace margelo::nitro::one { struct NotificationBehavior; }

#include "NativePermissionResponse.hpp"
#include <NitroModules/Promise.hpp>
#include "NativePermissionRequest.hpp"
#include "NativeNotificationCategory.hpp"
#include <vector>
#include <string>
#include "NativeChannel.hpp"
#include <optional>
#include "NativeChannelInput.hpp"
#include "NativeScheduleInput.hpp"
#include "NativeNotificationRequest.hpp"
#include "NativeNotification.hpp"
#include "NativePushToken.hpp"
#include <functional>
#include "NativeNotificationResponse.hpp"
#include "NotificationBehavior.hpp"

namespace margelo::nitro::one {

  using namespace margelo::nitro;

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

      // Destructor
      ~HybridOneNotificationsSpec() override = default;

    public:
      // Properties
      

    public:
      // Methods
      virtual std::shared_ptr<Promise<NativePermissionResponse>> getPermissions() = 0;
      virtual std::shared_ptr<Promise<NativePermissionResponse>> requestPermissions(const NativePermissionRequest& options) = 0;
      virtual std::shared_ptr<Promise<double>> getBadgeCount() = 0;
      virtual std::shared_ptr<Promise<bool>> setBadgeCount(double count) = 0;
      virtual std::shared_ptr<Promise<NativeNotificationCategory>> setNotificationCategory(const NativeNotificationCategory& category) = 0;
      virtual std::shared_ptr<Promise<std::vector<NativeNotificationCategory>>> getNotificationCategories() = 0;
      virtual std::shared_ptr<Promise<bool>> deleteNotificationCategory(const std::string& identifier) = 0;
      virtual std::shared_ptr<Promise<std::optional<NativeChannel>>> setNotificationChannel(const std::string& channelId, const NativeChannelInput& channel) = 0;
      virtual std::shared_ptr<Promise<std::optional<NativeChannel>>> getNotificationChannel(const std::string& channelId) = 0;
      virtual std::shared_ptr<Promise<std::vector<NativeChannel>>> getNotificationChannels() = 0;
      virtual std::shared_ptr<Promise<void>> deleteNotificationChannel(const std::string& channelId) = 0;
      virtual std::shared_ptr<Promise<std::string>> scheduleNotification(const NativeScheduleInput& request) = 0;
      virtual std::shared_ptr<Promise<void>> cancelScheduledNotification(const std::string& identifier) = 0;
      virtual std::shared_ptr<Promise<void>> cancelAllScheduledNotifications() = 0;
      virtual std::shared_ptr<Promise<std::vector<NativeNotificationRequest>>> getAllScheduledNotifications() = 0;
      virtual std::shared_ptr<Promise<std::vector<NativeNotification>>> getPresentedNotifications() = 0;
      virtual std::shared_ptr<Promise<void>> dismissNotification(const std::string& identifier) = 0;
      virtual std::shared_ptr<Promise<void>> dismissAllNotifications() = 0;
      virtual std::shared_ptr<Promise<NativePushToken>> getDevicePushToken() = 0;
      virtual void setListeners(const std::function<void(const std::string& /* requestId */, const NativeNotification& /* notification */)>& onReceived, const std::function<void(const NativeNotificationResponse& /* response */)>& onResponse, const std::function<void(const NativePushToken& /* token */)>& onPushToken) = 0;
      virtual void presentNotification(const std::string& requestId, const NotificationBehavior& behavior) = 0;
      virtual std::optional<NativeNotificationResponse> getLastNotificationResponse() = 0;
      virtual void clearLastNotificationResponse() = 0;

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

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

} // namespace margelo::nitro::one
