// Generated by Cap'n Proto compiler, DO NOT EDIT
// source: init.capnp

#pragma once

#include <capnp/generated-header-support.h>
#include <kj/windows-sanity.h>
#if !CAPNP_LITE
#include <capnp/capability.h>
#endif  // !CAPNP_LITE

#ifndef CAPNP_VERSION
#error "CAPNP_VERSION is not defined, is capnp/generated-header-support.h missing?"
#elif CAPNP_VERSION != 1002000
#error "Version mismatch between generated code and library headers.  You must use the same version of the Cap'n Proto compiler and library."
#endif

#include <mp/proxy.capnp.h>
#include "echo.capnp.h"
#include "mining.capnp.h"

CAPNP_BEGIN_HEADER

namespace capnp {
namespace schemas {

CAPNP_DECLARE_SCHEMA(8838c700ba5cba65);
CAPNP_DECLARE_SCHEMA(d0094f43e65f70fa);
CAPNP_DECLARE_SCHEMA(cff59c9cb0856a9d);
CAPNP_DECLARE_SCHEMA(d1eaffd3f12b7a9a);
CAPNP_DECLARE_SCHEMA(c6b83de56dc761c7);
CAPNP_DECLARE_SCHEMA(ecc9a12bacbb6a49);
CAPNP_DECLARE_SCHEMA(b40b3d0b48ea1c10);

}  // namespace schemas
}  // namespace capnp

namespace ipc {
namespace capnp {
namespace messages {

struct Init {
  Init() = delete;

#if !CAPNP_LITE
  class Client;
  class Server;
#endif  // !CAPNP_LITE

  struct ConstructParams;
  struct ConstructResults;
  struct MakeEchoParams;
  struct MakeEchoResults;
  struct MakeMiningParams;
  struct MakeMiningResults;

  #if !CAPNP_LITE
  struct _capnpPrivate {
    CAPNP_DECLARE_INTERFACE_HEADER(8838c700ba5cba65)
    static constexpr ::capnp::_::RawBrandedSchema const* brand() { return &schema->defaultBrand; }
  };
  #endif  // !CAPNP_LITE
};

struct Init::ConstructParams {
  ConstructParams() = delete;

  class Reader;
  class Builder;
  class Pipeline;

  struct _capnpPrivate {
    CAPNP_DECLARE_STRUCT_HEADER(d0094f43e65f70fa, 0, 1)
    #if !CAPNP_LITE
    static constexpr ::capnp::_::RawBrandedSchema const* brand() { return &schema->defaultBrand; }
    #endif  // !CAPNP_LITE
  };
};

struct Init::ConstructResults {
  ConstructResults() = delete;

  class Reader;
  class Builder;
  class Pipeline;

  struct _capnpPrivate {
    CAPNP_DECLARE_STRUCT_HEADER(cff59c9cb0856a9d, 0, 1)
    #if !CAPNP_LITE
    static constexpr ::capnp::_::RawBrandedSchema const* brand() { return &schema->defaultBrand; }
    #endif  // !CAPNP_LITE
  };
};

struct Init::MakeEchoParams {
  MakeEchoParams() = delete;

  class Reader;
  class Builder;
  class Pipeline;

  struct _capnpPrivate {
    CAPNP_DECLARE_STRUCT_HEADER(d1eaffd3f12b7a9a, 0, 1)
    #if !CAPNP_LITE
    static constexpr ::capnp::_::RawBrandedSchema const* brand() { return &schema->defaultBrand; }
    #endif  // !CAPNP_LITE
  };
};

struct Init::MakeEchoResults {
  MakeEchoResults() = delete;

  class Reader;
  class Builder;
  class Pipeline;

  struct _capnpPrivate {
    CAPNP_DECLARE_STRUCT_HEADER(c6b83de56dc761c7, 0, 1)
    #if !CAPNP_LITE
    static constexpr ::capnp::_::RawBrandedSchema const* brand() { return &schema->defaultBrand; }
    #endif  // !CAPNP_LITE
  };
};

struct Init::MakeMiningParams {
  MakeMiningParams() = delete;

  class Reader;
  class Builder;
  class Pipeline;

  struct _capnpPrivate {
    CAPNP_DECLARE_STRUCT_HEADER(ecc9a12bacbb6a49, 0, 1)
    #if !CAPNP_LITE
    static constexpr ::capnp::_::RawBrandedSchema const* brand() { return &schema->defaultBrand; }
    #endif  // !CAPNP_LITE
  };
};

struct Init::MakeMiningResults {
  MakeMiningResults() = delete;

  class Reader;
  class Builder;
  class Pipeline;

  struct _capnpPrivate {
    CAPNP_DECLARE_STRUCT_HEADER(b40b3d0b48ea1c10, 0, 1)
    #if !CAPNP_LITE
    static constexpr ::capnp::_::RawBrandedSchema const* brand() { return &schema->defaultBrand; }
    #endif  // !CAPNP_LITE
  };
};

// =======================================================================================

#if !CAPNP_LITE
class Init::Client
    : public virtual ::capnp::Capability::Client {
public:
  typedef Init Calls;
  typedef Init Reads;

  Client(decltype(nullptr));
  explicit Client(::kj::Own< ::capnp::ClientHook>&& hook);
  template <typename _t, typename = ::kj::EnableIf< ::kj::canConvert<_t*, Server*>()>>
  Client(::kj::Own<_t>&& server);
  template <typename _t, typename = ::kj::EnableIf< ::kj::canConvert<_t*, Client*>()>>
  Client(::kj::Promise<_t>&& promise);
  Client(::kj::Exception&& exception);
  Client(Client&) = default;
  Client(Client&&) = default;
  Client& operator=(Client& other);
  Client& operator=(Client&& other);

  ::capnp::Request< ::ipc::capnp::messages::Init::ConstructParams,  ::ipc::capnp::messages::Init::ConstructResults> constructRequest(
      ::kj::Maybe< ::capnp::MessageSize> sizeHint = nullptr);
  ::capnp::Request< ::ipc::capnp::messages::Init::MakeEchoParams,  ::ipc::capnp::messages::Init::MakeEchoResults> makeEchoRequest(
      ::kj::Maybe< ::capnp::MessageSize> sizeHint = nullptr);
  ::capnp::Request< ::ipc::capnp::messages::Init::MakeMiningParams,  ::ipc::capnp::messages::Init::MakeMiningResults> makeMiningRequest(
      ::kj::Maybe< ::capnp::MessageSize> sizeHint = nullptr);

protected:
  Client() = default;
};

class Init::Server
    : public virtual ::capnp::Capability::Server {
public:
  typedef Init Serves;

  ::capnp::Capability::Server::DispatchCallResult dispatchCall(
      uint64_t interfaceId, uint16_t methodId,
      ::capnp::CallContext< ::capnp::AnyPointer, ::capnp::AnyPointer> context)
      override;

protected:
  typedef  ::ipc::capnp::messages::Init::ConstructParams ConstructParams;
  typedef  ::ipc::capnp::messages::Init::ConstructResults ConstructResults;
  typedef ::capnp::CallContext<ConstructParams, ConstructResults> ConstructContext;
  virtual ::kj::Promise<void> construct(ConstructContext context);
  typedef  ::ipc::capnp::messages::Init::MakeEchoParams MakeEchoParams;
  typedef  ::ipc::capnp::messages::Init::MakeEchoResults MakeEchoResults;
  typedef ::capnp::CallContext<MakeEchoParams, MakeEchoResults> MakeEchoContext;
  virtual ::kj::Promise<void> makeEcho(MakeEchoContext context);
  typedef  ::ipc::capnp::messages::Init::MakeMiningParams MakeMiningParams;
  typedef  ::ipc::capnp::messages::Init::MakeMiningResults MakeMiningResults;
  typedef ::capnp::CallContext<MakeMiningParams, MakeMiningResults> MakeMiningContext;
  virtual ::kj::Promise<void> makeMining(MakeMiningContext context);

  inline  ::ipc::capnp::messages::Init::Client thisCap() {
    return ::capnp::Capability::Server::thisCap()
        .template castAs< ::ipc::capnp::messages::Init>();
  }

  ::capnp::Capability::Server::DispatchCallResult dispatchCallInternal(
      uint16_t methodId,
      ::capnp::CallContext< ::capnp::AnyPointer, ::capnp::AnyPointer> context);
};
#endif  // !CAPNP_LITE

class Init::ConstructParams::Reader {
public:
  typedef ConstructParams Reads;

  Reader() = default;
  inline explicit Reader(::capnp::_::StructReader base): _reader(base) {}

  inline ::capnp::MessageSize totalSize() const {
    return _reader.totalSize().asPublic();
  }

#if !CAPNP_LITE
  inline ::kj::StringTree toString() const {
    return ::capnp::_::structString(_reader, *_capnpPrivate::brand());
  }
#endif  // !CAPNP_LITE

  inline bool hasThreadMap() const;
#if !CAPNP_LITE
  inline  ::mp::ThreadMap::Client getThreadMap() const;
#endif  // !CAPNP_LITE

private:
  ::capnp::_::StructReader _reader;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::List;
  friend class ::capnp::MessageBuilder;
  friend class ::capnp::Orphanage;
};

class Init::ConstructParams::Builder {
public:
  typedef ConstructParams Builds;

  Builder() = delete;  // Deleted to discourage incorrect usage.
                       // You can explicitly initialize to nullptr instead.
  inline Builder(decltype(nullptr)) {}
  inline explicit Builder(::capnp::_::StructBuilder base): _builder(base) {}
  inline operator Reader() const { return Reader(_builder.asReader()); }
  inline Reader asReader() const { return *this; }

  inline ::capnp::MessageSize totalSize() const { return asReader().totalSize(); }
#if !CAPNP_LITE
  inline ::kj::StringTree toString() const { return asReader().toString(); }
#endif  // !CAPNP_LITE

  inline bool hasThreadMap();
#if !CAPNP_LITE
  inline  ::mp::ThreadMap::Client getThreadMap();
  inline void setThreadMap( ::mp::ThreadMap::Client&& value);
  inline void setThreadMap( ::mp::ThreadMap::Client& value);
  inline void adoptThreadMap(::capnp::Orphan< ::mp::ThreadMap>&& value);
  inline ::capnp::Orphan< ::mp::ThreadMap> disownThreadMap();
#endif  // !CAPNP_LITE

private:
  ::capnp::_::StructBuilder _builder;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  friend class ::capnp::Orphanage;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
};

#if !CAPNP_LITE
class Init::ConstructParams::Pipeline {
public:
  typedef ConstructParams Pipelines;

  inline Pipeline(decltype(nullptr)): _typeless(nullptr) {}
  inline explicit Pipeline(::capnp::AnyPointer::Pipeline&& typeless)
      : _typeless(kj::mv(typeless)) {}

  inline  ::mp::ThreadMap::Client getThreadMap();
private:
  ::capnp::AnyPointer::Pipeline _typeless;
  friend class ::capnp::PipelineHook;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
};
#endif  // !CAPNP_LITE

class Init::ConstructResults::Reader {
public:
  typedef ConstructResults Reads;

  Reader() = default;
  inline explicit Reader(::capnp::_::StructReader base): _reader(base) {}

  inline ::capnp::MessageSize totalSize() const {
    return _reader.totalSize().asPublic();
  }

#if !CAPNP_LITE
  inline ::kj::StringTree toString() const {
    return ::capnp::_::structString(_reader, *_capnpPrivate::brand());
  }
#endif  // !CAPNP_LITE

  inline bool hasThreadMap() const;
#if !CAPNP_LITE
  inline  ::mp::ThreadMap::Client getThreadMap() const;
#endif  // !CAPNP_LITE

private:
  ::capnp::_::StructReader _reader;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::List;
  friend class ::capnp::MessageBuilder;
  friend class ::capnp::Orphanage;
};

class Init::ConstructResults::Builder {
public:
  typedef ConstructResults Builds;

  Builder() = delete;  // Deleted to discourage incorrect usage.
                       // You can explicitly initialize to nullptr instead.
  inline Builder(decltype(nullptr)) {}
  inline explicit Builder(::capnp::_::StructBuilder base): _builder(base) {}
  inline operator Reader() const { return Reader(_builder.asReader()); }
  inline Reader asReader() const { return *this; }

  inline ::capnp::MessageSize totalSize() const { return asReader().totalSize(); }
#if !CAPNP_LITE
  inline ::kj::StringTree toString() const { return asReader().toString(); }
#endif  // !CAPNP_LITE

  inline bool hasThreadMap();
#if !CAPNP_LITE
  inline  ::mp::ThreadMap::Client getThreadMap();
  inline void setThreadMap( ::mp::ThreadMap::Client&& value);
  inline void setThreadMap( ::mp::ThreadMap::Client& value);
  inline void adoptThreadMap(::capnp::Orphan< ::mp::ThreadMap>&& value);
  inline ::capnp::Orphan< ::mp::ThreadMap> disownThreadMap();
#endif  // !CAPNP_LITE

private:
  ::capnp::_::StructBuilder _builder;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  friend class ::capnp::Orphanage;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
};

#if !CAPNP_LITE
class Init::ConstructResults::Pipeline {
public:
  typedef ConstructResults Pipelines;

  inline Pipeline(decltype(nullptr)): _typeless(nullptr) {}
  inline explicit Pipeline(::capnp::AnyPointer::Pipeline&& typeless)
      : _typeless(kj::mv(typeless)) {}

  inline  ::mp::ThreadMap::Client getThreadMap();
private:
  ::capnp::AnyPointer::Pipeline _typeless;
  friend class ::capnp::PipelineHook;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
};
#endif  // !CAPNP_LITE

class Init::MakeEchoParams::Reader {
public:
  typedef MakeEchoParams Reads;

  Reader() = default;
  inline explicit Reader(::capnp::_::StructReader base): _reader(base) {}

  inline ::capnp::MessageSize totalSize() const {
    return _reader.totalSize().asPublic();
  }

#if !CAPNP_LITE
  inline ::kj::StringTree toString() const {
    return ::capnp::_::structString(_reader, *_capnpPrivate::brand());
  }
#endif  // !CAPNP_LITE

  inline bool hasContext() const;
  inline  ::mp::Context::Reader getContext() const;

private:
  ::capnp::_::StructReader _reader;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::List;
  friend class ::capnp::MessageBuilder;
  friend class ::capnp::Orphanage;
};

class Init::MakeEchoParams::Builder {
public:
  typedef MakeEchoParams Builds;

  Builder() = delete;  // Deleted to discourage incorrect usage.
                       // You can explicitly initialize to nullptr instead.
  inline Builder(decltype(nullptr)) {}
  inline explicit Builder(::capnp::_::StructBuilder base): _builder(base) {}
  inline operator Reader() const { return Reader(_builder.asReader()); }
  inline Reader asReader() const { return *this; }

  inline ::capnp::MessageSize totalSize() const { return asReader().totalSize(); }
#if !CAPNP_LITE
  inline ::kj::StringTree toString() const { return asReader().toString(); }
#endif  // !CAPNP_LITE

  inline bool hasContext();
  inline  ::mp::Context::Builder getContext();
  inline void setContext( ::mp::Context::Reader value);
  inline  ::mp::Context::Builder initContext();
  inline void adoptContext(::capnp::Orphan< ::mp::Context>&& value);
  inline ::capnp::Orphan< ::mp::Context> disownContext();

private:
  ::capnp::_::StructBuilder _builder;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  friend class ::capnp::Orphanage;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
};

#if !CAPNP_LITE
class Init::MakeEchoParams::Pipeline {
public:
  typedef MakeEchoParams Pipelines;

  inline Pipeline(decltype(nullptr)): _typeless(nullptr) {}
  inline explicit Pipeline(::capnp::AnyPointer::Pipeline&& typeless)
      : _typeless(kj::mv(typeless)) {}

  inline  ::mp::Context::Pipeline getContext();
private:
  ::capnp::AnyPointer::Pipeline _typeless;
  friend class ::capnp::PipelineHook;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
};
#endif  // !CAPNP_LITE

class Init::MakeEchoResults::Reader {
public:
  typedef MakeEchoResults Reads;

  Reader() = default;
  inline explicit Reader(::capnp::_::StructReader base): _reader(base) {}

  inline ::capnp::MessageSize totalSize() const {
    return _reader.totalSize().asPublic();
  }

#if !CAPNP_LITE
  inline ::kj::StringTree toString() const {
    return ::capnp::_::structString(_reader, *_capnpPrivate::brand());
  }
#endif  // !CAPNP_LITE

  inline bool hasResult() const;
#if !CAPNP_LITE
  inline  ::ipc::capnp::messages::Echo::Client getResult() const;
#endif  // !CAPNP_LITE

private:
  ::capnp::_::StructReader _reader;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::List;
  friend class ::capnp::MessageBuilder;
  friend class ::capnp::Orphanage;
};

class Init::MakeEchoResults::Builder {
public:
  typedef MakeEchoResults Builds;

  Builder() = delete;  // Deleted to discourage incorrect usage.
                       // You can explicitly initialize to nullptr instead.
  inline Builder(decltype(nullptr)) {}
  inline explicit Builder(::capnp::_::StructBuilder base): _builder(base) {}
  inline operator Reader() const { return Reader(_builder.asReader()); }
  inline Reader asReader() const { return *this; }

  inline ::capnp::MessageSize totalSize() const { return asReader().totalSize(); }
#if !CAPNP_LITE
  inline ::kj::StringTree toString() const { return asReader().toString(); }
#endif  // !CAPNP_LITE

  inline bool hasResult();
#if !CAPNP_LITE
  inline  ::ipc::capnp::messages::Echo::Client getResult();
  inline void setResult( ::ipc::capnp::messages::Echo::Client&& value);
  inline void setResult( ::ipc::capnp::messages::Echo::Client& value);
  inline void adoptResult(::capnp::Orphan< ::ipc::capnp::messages::Echo>&& value);
  inline ::capnp::Orphan< ::ipc::capnp::messages::Echo> disownResult();
#endif  // !CAPNP_LITE

private:
  ::capnp::_::StructBuilder _builder;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  friend class ::capnp::Orphanage;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
};

#if !CAPNP_LITE
class Init::MakeEchoResults::Pipeline {
public:
  typedef MakeEchoResults Pipelines;

  inline Pipeline(decltype(nullptr)): _typeless(nullptr) {}
  inline explicit Pipeline(::capnp::AnyPointer::Pipeline&& typeless)
      : _typeless(kj::mv(typeless)) {}

  inline  ::ipc::capnp::messages::Echo::Client getResult();
private:
  ::capnp::AnyPointer::Pipeline _typeless;
  friend class ::capnp::PipelineHook;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
};
#endif  // !CAPNP_LITE

class Init::MakeMiningParams::Reader {
public:
  typedef MakeMiningParams Reads;

  Reader() = default;
  inline explicit Reader(::capnp::_::StructReader base): _reader(base) {}

  inline ::capnp::MessageSize totalSize() const {
    return _reader.totalSize().asPublic();
  }

#if !CAPNP_LITE
  inline ::kj::StringTree toString() const {
    return ::capnp::_::structString(_reader, *_capnpPrivate::brand());
  }
#endif  // !CAPNP_LITE

  inline bool hasContext() const;
  inline  ::mp::Context::Reader getContext() const;

private:
  ::capnp::_::StructReader _reader;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::List;
  friend class ::capnp::MessageBuilder;
  friend class ::capnp::Orphanage;
};

class Init::MakeMiningParams::Builder {
public:
  typedef MakeMiningParams Builds;

  Builder() = delete;  // Deleted to discourage incorrect usage.
                       // You can explicitly initialize to nullptr instead.
  inline Builder(decltype(nullptr)) {}
  inline explicit Builder(::capnp::_::StructBuilder base): _builder(base) {}
  inline operator Reader() const { return Reader(_builder.asReader()); }
  inline Reader asReader() const { return *this; }

  inline ::capnp::MessageSize totalSize() const { return asReader().totalSize(); }
#if !CAPNP_LITE
  inline ::kj::StringTree toString() const { return asReader().toString(); }
#endif  // !CAPNP_LITE

  inline bool hasContext();
  inline  ::mp::Context::Builder getContext();
  inline void setContext( ::mp::Context::Reader value);
  inline  ::mp::Context::Builder initContext();
  inline void adoptContext(::capnp::Orphan< ::mp::Context>&& value);
  inline ::capnp::Orphan< ::mp::Context> disownContext();

private:
  ::capnp::_::StructBuilder _builder;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  friend class ::capnp::Orphanage;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
};

#if !CAPNP_LITE
class Init::MakeMiningParams::Pipeline {
public:
  typedef MakeMiningParams Pipelines;

  inline Pipeline(decltype(nullptr)): _typeless(nullptr) {}
  inline explicit Pipeline(::capnp::AnyPointer::Pipeline&& typeless)
      : _typeless(kj::mv(typeless)) {}

  inline  ::mp::Context::Pipeline getContext();
private:
  ::capnp::AnyPointer::Pipeline _typeless;
  friend class ::capnp::PipelineHook;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
};
#endif  // !CAPNP_LITE

class Init::MakeMiningResults::Reader {
public:
  typedef MakeMiningResults Reads;

  Reader() = default;
  inline explicit Reader(::capnp::_::StructReader base): _reader(base) {}

  inline ::capnp::MessageSize totalSize() const {
    return _reader.totalSize().asPublic();
  }

#if !CAPNP_LITE
  inline ::kj::StringTree toString() const {
    return ::capnp::_::structString(_reader, *_capnpPrivate::brand());
  }
#endif  // !CAPNP_LITE

  inline bool hasResult() const;
#if !CAPNP_LITE
  inline  ::ipc::capnp::messages::Mining::Client getResult() const;
#endif  // !CAPNP_LITE

private:
  ::capnp::_::StructReader _reader;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::List;
  friend class ::capnp::MessageBuilder;
  friend class ::capnp::Orphanage;
};

class Init::MakeMiningResults::Builder {
public:
  typedef MakeMiningResults Builds;

  Builder() = delete;  // Deleted to discourage incorrect usage.
                       // You can explicitly initialize to nullptr instead.
  inline Builder(decltype(nullptr)) {}
  inline explicit Builder(::capnp::_::StructBuilder base): _builder(base) {}
  inline operator Reader() const { return Reader(_builder.asReader()); }
  inline Reader asReader() const { return *this; }

  inline ::capnp::MessageSize totalSize() const { return asReader().totalSize(); }
#if !CAPNP_LITE
  inline ::kj::StringTree toString() const { return asReader().toString(); }
#endif  // !CAPNP_LITE

  inline bool hasResult();
#if !CAPNP_LITE
  inline  ::ipc::capnp::messages::Mining::Client getResult();
  inline void setResult( ::ipc::capnp::messages::Mining::Client&& value);
  inline void setResult( ::ipc::capnp::messages::Mining::Client& value);
  inline void adoptResult(::capnp::Orphan< ::ipc::capnp::messages::Mining>&& value);
  inline ::capnp::Orphan< ::ipc::capnp::messages::Mining> disownResult();
#endif  // !CAPNP_LITE

private:
  ::capnp::_::StructBuilder _builder;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
  friend class ::capnp::Orphanage;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::_::PointerHelpers;
};

#if !CAPNP_LITE
class Init::MakeMiningResults::Pipeline {
public:
  typedef MakeMiningResults Pipelines;

  inline Pipeline(decltype(nullptr)): _typeless(nullptr) {}
  inline explicit Pipeline(::capnp::AnyPointer::Pipeline&& typeless)
      : _typeless(kj::mv(typeless)) {}

  inline  ::ipc::capnp::messages::Mining::Client getResult();
private:
  ::capnp::AnyPointer::Pipeline _typeless;
  friend class ::capnp::PipelineHook;
  template <typename, ::capnp::Kind>
  friend struct ::capnp::ToDynamic_;
};
#endif  // !CAPNP_LITE

// =======================================================================================

#if !CAPNP_LITE
inline Init::Client::Client(decltype(nullptr))
    : ::capnp::Capability::Client(nullptr) {}
inline Init::Client::Client(
    ::kj::Own< ::capnp::ClientHook>&& hook)
    : ::capnp::Capability::Client(::kj::mv(hook)) {}
template <typename _t, typename>
inline Init::Client::Client(::kj::Own<_t>&& server)
    : ::capnp::Capability::Client(::kj::mv(server)) {}
template <typename _t, typename>
inline Init::Client::Client(::kj::Promise<_t>&& promise)
    : ::capnp::Capability::Client(::kj::mv(promise)) {}
inline Init::Client::Client(::kj::Exception&& exception)
    : ::capnp::Capability::Client(::kj::mv(exception)) {}
inline  ::ipc::capnp::messages::Init::Client& Init::Client::operator=(Client& other) {
  ::capnp::Capability::Client::operator=(other);
  return *this;
}
inline  ::ipc::capnp::messages::Init::Client& Init::Client::operator=(Client&& other) {
  ::capnp::Capability::Client::operator=(kj::mv(other));
  return *this;
}

#endif  // !CAPNP_LITE
inline bool Init::ConstructParams::Reader::hasThreadMap() const {
  return !_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
inline bool Init::ConstructParams::Builder::hasThreadMap() {
  return !_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
#if !CAPNP_LITE
inline  ::mp::ThreadMap::Client Init::ConstructParams::Reader::getThreadMap() const {
  return ::capnp::_::PointerHelpers< ::mp::ThreadMap>::get(_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline  ::mp::ThreadMap::Client Init::ConstructParams::Builder::getThreadMap() {
  return ::capnp::_::PointerHelpers< ::mp::ThreadMap>::get(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline  ::mp::ThreadMap::Client Init::ConstructParams::Pipeline::getThreadMap() {
  return  ::mp::ThreadMap::Client(_typeless.getPointerField(0).asCap());
}
inline void Init::ConstructParams::Builder::setThreadMap( ::mp::ThreadMap::Client&& cap) {
  ::capnp::_::PointerHelpers< ::mp::ThreadMap>::set(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), kj::mv(cap));
}
inline void Init::ConstructParams::Builder::setThreadMap( ::mp::ThreadMap::Client& cap) {
  ::capnp::_::PointerHelpers< ::mp::ThreadMap>::set(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), cap);
}
inline void Init::ConstructParams::Builder::adoptThreadMap(
    ::capnp::Orphan< ::mp::ThreadMap>&& value) {
  ::capnp::_::PointerHelpers< ::mp::ThreadMap>::adopt(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), kj::mv(value));
}
inline ::capnp::Orphan< ::mp::ThreadMap> Init::ConstructParams::Builder::disownThreadMap() {
  return ::capnp::_::PointerHelpers< ::mp::ThreadMap>::disown(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
#endif  // !CAPNP_LITE

inline bool Init::ConstructResults::Reader::hasThreadMap() const {
  return !_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
inline bool Init::ConstructResults::Builder::hasThreadMap() {
  return !_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
#if !CAPNP_LITE
inline  ::mp::ThreadMap::Client Init::ConstructResults::Reader::getThreadMap() const {
  return ::capnp::_::PointerHelpers< ::mp::ThreadMap>::get(_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline  ::mp::ThreadMap::Client Init::ConstructResults::Builder::getThreadMap() {
  return ::capnp::_::PointerHelpers< ::mp::ThreadMap>::get(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline  ::mp::ThreadMap::Client Init::ConstructResults::Pipeline::getThreadMap() {
  return  ::mp::ThreadMap::Client(_typeless.getPointerField(0).asCap());
}
inline void Init::ConstructResults::Builder::setThreadMap( ::mp::ThreadMap::Client&& cap) {
  ::capnp::_::PointerHelpers< ::mp::ThreadMap>::set(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), kj::mv(cap));
}
inline void Init::ConstructResults::Builder::setThreadMap( ::mp::ThreadMap::Client& cap) {
  ::capnp::_::PointerHelpers< ::mp::ThreadMap>::set(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), cap);
}
inline void Init::ConstructResults::Builder::adoptThreadMap(
    ::capnp::Orphan< ::mp::ThreadMap>&& value) {
  ::capnp::_::PointerHelpers< ::mp::ThreadMap>::adopt(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), kj::mv(value));
}
inline ::capnp::Orphan< ::mp::ThreadMap> Init::ConstructResults::Builder::disownThreadMap() {
  return ::capnp::_::PointerHelpers< ::mp::ThreadMap>::disown(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
#endif  // !CAPNP_LITE

inline bool Init::MakeEchoParams::Reader::hasContext() const {
  return !_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
inline bool Init::MakeEchoParams::Builder::hasContext() {
  return !_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
inline  ::mp::Context::Reader Init::MakeEchoParams::Reader::getContext() const {
  return ::capnp::_::PointerHelpers< ::mp::Context>::get(_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline  ::mp::Context::Builder Init::MakeEchoParams::Builder::getContext() {
  return ::capnp::_::PointerHelpers< ::mp::Context>::get(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
#if !CAPNP_LITE
inline  ::mp::Context::Pipeline Init::MakeEchoParams::Pipeline::getContext() {
  return  ::mp::Context::Pipeline(_typeless.getPointerField(0));
}
#endif  // !CAPNP_LITE
inline void Init::MakeEchoParams::Builder::setContext( ::mp::Context::Reader value) {
  ::capnp::_::PointerHelpers< ::mp::Context>::set(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), value);
}
inline  ::mp::Context::Builder Init::MakeEchoParams::Builder::initContext() {
  return ::capnp::_::PointerHelpers< ::mp::Context>::init(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline void Init::MakeEchoParams::Builder::adoptContext(
    ::capnp::Orphan< ::mp::Context>&& value) {
  ::capnp::_::PointerHelpers< ::mp::Context>::adopt(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), kj::mv(value));
}
inline ::capnp::Orphan< ::mp::Context> Init::MakeEchoParams::Builder::disownContext() {
  return ::capnp::_::PointerHelpers< ::mp::Context>::disown(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}

inline bool Init::MakeEchoResults::Reader::hasResult() const {
  return !_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
inline bool Init::MakeEchoResults::Builder::hasResult() {
  return !_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
#if !CAPNP_LITE
inline  ::ipc::capnp::messages::Echo::Client Init::MakeEchoResults::Reader::getResult() const {
  return ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Echo>::get(_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline  ::ipc::capnp::messages::Echo::Client Init::MakeEchoResults::Builder::getResult() {
  return ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Echo>::get(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline  ::ipc::capnp::messages::Echo::Client Init::MakeEchoResults::Pipeline::getResult() {
  return  ::ipc::capnp::messages::Echo::Client(_typeless.getPointerField(0).asCap());
}
inline void Init::MakeEchoResults::Builder::setResult( ::ipc::capnp::messages::Echo::Client&& cap) {
  ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Echo>::set(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), kj::mv(cap));
}
inline void Init::MakeEchoResults::Builder::setResult( ::ipc::capnp::messages::Echo::Client& cap) {
  ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Echo>::set(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), cap);
}
inline void Init::MakeEchoResults::Builder::adoptResult(
    ::capnp::Orphan< ::ipc::capnp::messages::Echo>&& value) {
  ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Echo>::adopt(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), kj::mv(value));
}
inline ::capnp::Orphan< ::ipc::capnp::messages::Echo> Init::MakeEchoResults::Builder::disownResult() {
  return ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Echo>::disown(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
#endif  // !CAPNP_LITE

inline bool Init::MakeMiningParams::Reader::hasContext() const {
  return !_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
inline bool Init::MakeMiningParams::Builder::hasContext() {
  return !_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
inline  ::mp::Context::Reader Init::MakeMiningParams::Reader::getContext() const {
  return ::capnp::_::PointerHelpers< ::mp::Context>::get(_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline  ::mp::Context::Builder Init::MakeMiningParams::Builder::getContext() {
  return ::capnp::_::PointerHelpers< ::mp::Context>::get(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
#if !CAPNP_LITE
inline  ::mp::Context::Pipeline Init::MakeMiningParams::Pipeline::getContext() {
  return  ::mp::Context::Pipeline(_typeless.getPointerField(0));
}
#endif  // !CAPNP_LITE
inline void Init::MakeMiningParams::Builder::setContext( ::mp::Context::Reader value) {
  ::capnp::_::PointerHelpers< ::mp::Context>::set(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), value);
}
inline  ::mp::Context::Builder Init::MakeMiningParams::Builder::initContext() {
  return ::capnp::_::PointerHelpers< ::mp::Context>::init(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline void Init::MakeMiningParams::Builder::adoptContext(
    ::capnp::Orphan< ::mp::Context>&& value) {
  ::capnp::_::PointerHelpers< ::mp::Context>::adopt(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), kj::mv(value));
}
inline ::capnp::Orphan< ::mp::Context> Init::MakeMiningParams::Builder::disownContext() {
  return ::capnp::_::PointerHelpers< ::mp::Context>::disown(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}

inline bool Init::MakeMiningResults::Reader::hasResult() const {
  return !_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
inline bool Init::MakeMiningResults::Builder::hasResult() {
  return !_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS).isNull();
}
#if !CAPNP_LITE
inline  ::ipc::capnp::messages::Mining::Client Init::MakeMiningResults::Reader::getResult() const {
  return ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Mining>::get(_reader.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline  ::ipc::capnp::messages::Mining::Client Init::MakeMiningResults::Builder::getResult() {
  return ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Mining>::get(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
inline  ::ipc::capnp::messages::Mining::Client Init::MakeMiningResults::Pipeline::getResult() {
  return  ::ipc::capnp::messages::Mining::Client(_typeless.getPointerField(0).asCap());
}
inline void Init::MakeMiningResults::Builder::setResult( ::ipc::capnp::messages::Mining::Client&& cap) {
  ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Mining>::set(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), kj::mv(cap));
}
inline void Init::MakeMiningResults::Builder::setResult( ::ipc::capnp::messages::Mining::Client& cap) {
  ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Mining>::set(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), cap);
}
inline void Init::MakeMiningResults::Builder::adoptResult(
    ::capnp::Orphan< ::ipc::capnp::messages::Mining>&& value) {
  ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Mining>::adopt(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS), kj::mv(value));
}
inline ::capnp::Orphan< ::ipc::capnp::messages::Mining> Init::MakeMiningResults::Builder::disownResult() {
  return ::capnp::_::PointerHelpers< ::ipc::capnp::messages::Mining>::disown(_builder.getPointerField(
      ::capnp::bounded<0>() * ::capnp::POINTERS));
}
#endif  // !CAPNP_LITE

}  // namespace
}  // namespace
}  // namespace

CAPNP_END_HEADER

