#pragma once

#include <cxx-qt/casting.h>
#include <cxx-qt/signalhandler.h>
#include <cxx-qt/threading.h>
#include <cxx-qt/type.h>

namespace CXX {
class AfcBackend;
using AfcBackendCxxQtThread = ::rust::cxxqt1::CxxQtThread<AfcBackend>;

} // namespace CXX

namespace CXX::rust::cxxqtgen1 {
using AfcBackendCxxQtSignalHandlercheck_is_dir_and_list_finished = ::rust::cxxqt1::SignalHandler<struct AfcBackendCxxQtSignalParamscheck_is_dir_and_list_finished *>;
} // namespace CXX::rust::cxxqtgen1

namespace CXX::rust::cxxqtgen1 {
using AfcBackendCxxQtSignalHandleralbum_list_loaded = ::rust::cxxqt1::SignalHandler<struct AfcBackendCxxQtSignalParamsalbum_list_loaded *>;
} // namespace CXX::rust::cxxqtgen1


#include "idescriptor_rust_codebase/src/afc_services.cxx.h"


namespace CXX::rust::cxxqtgen1 {
::QMetaObject::Connection
AfcBackend_check_is_dir_and_list_finishedConnect(CXX::AfcBackend& self, ::CXX::rust::cxxqtgen1::AfcBackendCxxQtSignalHandlercheck_is_dir_and_list_finished closure, ::Qt::ConnectionType type);
} // namespace CXX::rust::cxxqtgen1

namespace CXX::rust::cxxqtgen1 {
::QMetaObject::Connection
AfcBackend_album_list_loadedConnect(CXX::AfcBackend& self, ::CXX::rust::cxxqtgen1::AfcBackendCxxQtSignalHandleralbum_list_loaded closure, ::Qt::ConnectionType type);
} // namespace CXX::rust::cxxqtgen1

namespace CXX {
class AfcBackend : public QObject, private ::rust::cxxqt1::CxxQtType<RAfcBackend>, private ::rust::cxxqt1::CxxQtThreading<AfcBackend>
{
  Q_OBJECT
public:
  

  virtual ~AfcBackend() = default;

public:
  Q_INVOKABLE void set_udid(QString const& udid) noexcept;
  Q_INVOKABLE void load_album_list() noexcept;
  Q_INVOKABLE QList_QString list_dir(QString const& path) const noexcept;
  Q_INVOKABLE QByteArray file_to_buffer(QString const& file_path) const noexcept;
  Q_INVOKABLE bool is_directory(QString const& path) const noexcept;
  Q_INVOKABLE ::std::int64_t get_file_size(QString const& path) const noexcept;
  Q_INVOKABLE QByteArray read_file_range(QString const& path, ::std::int64_t offset, ::std::int64_t len) const noexcept;
  Q_INVOKABLE void check_is_dir_and_list(QString const& path) const noexcept;
  Q_INVOKABLE ::std::int64_t get_dirs_item_count(QList_QString const& dir) const noexcept;
  Q_INVOKABLE QList_QString list_files_flat(QString const& dir) const noexcept;
  Q_INVOKABLE QString start_video_stream(QString const& file_path) const noexcept;
  Q_INVOKABLE QMap_QString_QVariant list_dir_with_creation_date(QString const& path) const noexcept;
  Q_INVOKABLE bool delete_path(QString const& path) const noexcept;
  Q_SIGNAL void check_is_dir_and_list_finished(bool success, QMap_QString_QVariant const& entries);
  Q_SIGNAL void album_list_loaded(QString udid, QList_QString album_list);
  explicit AfcBackend(QString arg0);

private:
  template<typename T>
friend auto ::rust::cxxqt1::qtThread(const T& qobject) -> ::rust::cxxqt1::CxxQtThread<T>;
  explicit AfcBackend(::CXX::cxx_qt_AfcBackend::CxxQtConstructorArguments0&& args);


private:
  template<typename Inner, typename Outer>
  friend Inner& ::rust::cxxqt1::unsafeRustMut(Outer& outer);

  template<typename Inner, typename Outer>
  friend const Inner& ::rust::cxxqt1::unsafeRust(const Outer& outer);
};

static_assert(::std::is_base_of<QObject, AfcBackend>::value, "AfcBackend must inherit from QObject");
} // namespace CXX



Q_DECLARE_METATYPE(CXX::AfcBackend*)

