Copy as Markdown

Other Tools

//
// Automatically generated by ipdlc.
// Edit at your own risk
//
#ifndef PBackgroundSDBRequest_h
#define PBackgroundSDBRequest_h
#include "mozilla/Attributes.h"
#include "IPCMessageStart.h"
#include "mozilla/RefPtr.h"
#include "nsString.h"
#include "nsTArray.h"
#include "nsTHashtable.h"
#include "mozilla/MozPromise.h"
#include "mozilla/OperatorNewExtensions.h"
#include "mozilla/UniquePtr.h"
#include "mozilla/ipc/ByteBuf.h"
#include "mozilla/ipc/FileDescriptor.h"
#include "mozilla/ipc/IPCForwards.h"
#include "mozilla/ipc/Shmem.h"
// Headers for typedefs
#include "mozilla/ipc/IPDLStructMember.h"
//-----------------------------------------------------------------------------
// Declaration of the IPDL type |struct SDBRequestOpenResponse|
//
namespace mozilla {
namespace dom {
class SDBRequestOpenResponse final
{
private:
public:
#ifdef __clang__
# pragma clang diagnostic push
# if __has_warning("-Wdefaulted-function-deleted")
# pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
# endif
#endif
SDBRequestOpenResponse() = default;
#ifdef __clang__
# pragma clang diagnostic pop
#endif
private:
};
} // namespace dom
} // namespace mozilla
namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::SDBRequestOpenResponse>
{
typedef ::mozilla::dom::SDBRequestOpenResponse paramType;
static void
Write(
IPC::MessageWriter* aWriter,
const paramType& aVar);
static IPC::ReadResult<paramType>
Read(IPC::MessageReader* aReader);
};
} // namespace IPC
//-----------------------------------------------------------------------------
// Declaration of the IPDL type |struct SDBRequestSeekResponse|
//
namespace mozilla {
namespace dom {
class SDBRequestSeekResponse final
{
private:
public:
#ifdef __clang__
# pragma clang diagnostic push
# if __has_warning("-Wdefaulted-function-deleted")
# pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
# endif
#endif
SDBRequestSeekResponse() = default;
#ifdef __clang__
# pragma clang diagnostic pop
#endif
private:
};
} // namespace dom
} // namespace mozilla
namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::SDBRequestSeekResponse>
{
typedef ::mozilla::dom::SDBRequestSeekResponse paramType;
static void
Write(
IPC::MessageWriter* aWriter,
const paramType& aVar);
static IPC::ReadResult<paramType>
Read(IPC::MessageReader* aReader);
};
} // namespace IPC
//-----------------------------------------------------------------------------
// Declaration of the IPDL type |struct SDBRequestReadResponse|
//
namespace mozilla {
namespace dom {
class SDBRequestReadResponse final
{
private:
typedef ::nsCString nsCString;
public:
#ifdef __clang__
# pragma clang diagnostic push
# if __has_warning("-Wdefaulted-function-deleted")
# pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
# endif
#endif
SDBRequestReadResponse() = default;
#ifdef __clang__
# pragma clang diagnostic pop
#endif
MOZ_IMPLICIT SDBRequestReadResponse(const nsCString& _data) :
data_(_data)
{
}
MOZ_IMPLICIT SDBRequestReadResponse(nsCString&& _data) :
data_(std::move(_data))
{
}
nsCString&
data()
{
return data_;
}
const nsCString&
data() const
{
return data_;
}
private:
::mozilla::ipc::IPDLStructMember<nsCString> data_;
};
} // namespace dom
} // namespace mozilla
namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::SDBRequestReadResponse>
{
typedef ::mozilla::dom::SDBRequestReadResponse paramType;
static void
Write(
IPC::MessageWriter* aWriter,
const paramType& aVar);
static IPC::ReadResult<paramType>
Read(IPC::MessageReader* aReader);
};
} // namespace IPC
//-----------------------------------------------------------------------------
// Declaration of the IPDL type |struct SDBRequestWriteResponse|
//
namespace mozilla {
namespace dom {
class SDBRequestWriteResponse final
{
private:
public:
#ifdef __clang__
# pragma clang diagnostic push
# if __has_warning("-Wdefaulted-function-deleted")
# pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
# endif
#endif
SDBRequestWriteResponse() = default;
#ifdef __clang__
# pragma clang diagnostic pop
#endif
private:
};
} // namespace dom
} // namespace mozilla
namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::SDBRequestWriteResponse>
{
typedef ::mozilla::dom::SDBRequestWriteResponse paramType;
static void
Write(
IPC::MessageWriter* aWriter,
const paramType& aVar);
static IPC::ReadResult<paramType>
Read(IPC::MessageReader* aReader);
};
} // namespace IPC
//-----------------------------------------------------------------------------
// Declaration of the IPDL type |struct SDBRequestCloseResponse|
//
namespace mozilla {
namespace dom {
class SDBRequestCloseResponse final
{
private:
public:
#ifdef __clang__
# pragma clang diagnostic push
# if __has_warning("-Wdefaulted-function-deleted")
# pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
# endif
#endif
SDBRequestCloseResponse() = default;
#ifdef __clang__
# pragma clang diagnostic pop
#endif
private:
};
} // namespace dom
} // namespace mozilla
namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::SDBRequestCloseResponse>
{
typedef ::mozilla::dom::SDBRequestCloseResponse paramType;
static void
Write(
IPC::MessageWriter* aWriter,
const paramType& aVar);
static IPC::ReadResult<paramType>
Read(IPC::MessageReader* aReader);
};
} // namespace IPC
//-----------------------------------------------------------------------------
// Declaration of the IPDL type |union SDBRequestResponse|
//
namespace mozilla {
namespace dom {
class SDBRequestResponse final
{
public:
enum Type {
T__None,
Tnsresult = 1,
TSDBRequestOpenResponse,
TSDBRequestSeekResponse,
TSDBRequestReadResponse,
TSDBRequestWriteResponse,
TSDBRequestCloseResponse,
T__Last = TSDBRequestCloseResponse
};
private:
typedef ::nsresult nsresult;
typedef ::mozilla::dom::SDBRequestOpenResponse SDBRequestOpenResponse;
typedef ::mozilla::dom::SDBRequestSeekResponse SDBRequestSeekResponse;
typedef ::mozilla::dom::SDBRequestReadResponse SDBRequestReadResponse;
typedef ::mozilla::dom::SDBRequestWriteResponse SDBRequestWriteResponse;
typedef ::mozilla::dom::SDBRequestCloseResponse SDBRequestCloseResponse;
typedef nsresult nsresult__tdef;
typedef SDBRequestOpenResponse SDBRequestOpenResponse__tdef;
typedef SDBRequestSeekResponse SDBRequestSeekResponse__tdef;
typedef SDBRequestReadResponse SDBRequestReadResponse__tdef;
typedef SDBRequestWriteResponse SDBRequestWriteResponse__tdef;
typedef SDBRequestCloseResponse SDBRequestCloseResponse__tdef;
nsresult*
ptr_nsresult()
{
return (&(mVnsresult));
}
const nsresult*
constptr_nsresult() const
{
return (&(mVnsresult));
}
SDBRequestOpenResponse*
ptr_SDBRequestOpenResponse()
{
return (&(mVSDBRequestOpenResponse));
}
const SDBRequestOpenResponse*
constptr_SDBRequestOpenResponse() const
{
return (&(mVSDBRequestOpenResponse));
}
SDBRequestSeekResponse*
ptr_SDBRequestSeekResponse()
{
return (&(mVSDBRequestSeekResponse));
}
const SDBRequestSeekResponse*
constptr_SDBRequestSeekResponse() const
{
return (&(mVSDBRequestSeekResponse));
}
SDBRequestReadResponse*
ptr_SDBRequestReadResponse()
{
return (&(mVSDBRequestReadResponse));
}
const SDBRequestReadResponse*
constptr_SDBRequestReadResponse() const
{
return (&(mVSDBRequestReadResponse));
}
SDBRequestWriteResponse*
ptr_SDBRequestWriteResponse()
{
return (&(mVSDBRequestWriteResponse));
}
const SDBRequestWriteResponse*
constptr_SDBRequestWriteResponse() const
{
return (&(mVSDBRequestWriteResponse));
}
SDBRequestCloseResponse*
ptr_SDBRequestCloseResponse()
{
return (&(mVSDBRequestCloseResponse));
}
const SDBRequestCloseResponse*
constptr_SDBRequestCloseResponse() const
{
return (&(mVSDBRequestCloseResponse));
}
void
MaybeDestroy();
void
AssertSanity() const
{
MOZ_RELEASE_ASSERT((T__None) <= (mType), "invalid type tag");
MOZ_RELEASE_ASSERT((mType) <= (T__Last), "invalid type tag");
}
void
AssertSanity(Type aType) const
{
AssertSanity();
MOZ_RELEASE_ASSERT((mType) == (aType), "unexpected type tag");
}
public:
MOZ_IMPLICIT SDBRequestResponse() :
mType(T__None)
{
}
MOZ_IMPLICIT SDBRequestResponse(const nsresult& aOther);
MOZ_IMPLICIT SDBRequestResponse(nsresult&& aOther);
MOZ_IMPLICIT SDBRequestResponse(const SDBRequestOpenResponse& aOther);
MOZ_IMPLICIT SDBRequestResponse(SDBRequestOpenResponse&& aOther);
MOZ_IMPLICIT SDBRequestResponse(const SDBRequestSeekResponse& aOther);
MOZ_IMPLICIT SDBRequestResponse(SDBRequestSeekResponse&& aOther);
MOZ_IMPLICIT SDBRequestResponse(const SDBRequestReadResponse& aOther);
MOZ_IMPLICIT SDBRequestResponse(SDBRequestReadResponse&& aOther);
MOZ_IMPLICIT SDBRequestResponse(const SDBRequestWriteResponse& aOther);
MOZ_IMPLICIT SDBRequestResponse(SDBRequestWriteResponse&& aOther);
MOZ_IMPLICIT SDBRequestResponse(const SDBRequestCloseResponse& aOther);
MOZ_IMPLICIT SDBRequestResponse(SDBRequestCloseResponse&& aOther);
MOZ_IMPLICIT SDBRequestResponse(const SDBRequestResponse& aOther);
MOZ_IMPLICIT SDBRequestResponse(SDBRequestResponse&& aOther);
~SDBRequestResponse();
Type
type() const
{
return mType;
}
SDBRequestResponse&
operator=(const nsresult& aRhs);
SDBRequestResponse&
operator=(nsresult&& aRhs);
SDBRequestResponse&
operator=(const SDBRequestOpenResponse& aRhs);
SDBRequestResponse&
operator=(SDBRequestOpenResponse&& aRhs);
SDBRequestResponse&
operator=(const SDBRequestSeekResponse& aRhs);
SDBRequestResponse&
operator=(SDBRequestSeekResponse&& aRhs);
SDBRequestResponse&
operator=(const SDBRequestReadResponse& aRhs);
SDBRequestResponse&
operator=(SDBRequestReadResponse&& aRhs);
SDBRequestResponse&
operator=(const SDBRequestWriteResponse& aRhs);
SDBRequestResponse&
operator=(SDBRequestWriteResponse&& aRhs);
SDBRequestResponse&
operator=(const SDBRequestCloseResponse& aRhs);
SDBRequestResponse&
operator=(SDBRequestCloseResponse&& aRhs);
SDBRequestResponse&
operator=(const SDBRequestResponse& aRhs);
SDBRequestResponse&
operator=(SDBRequestResponse&& aRhs);
nsresult&
get_nsresult()
{
AssertSanity(Tnsresult);
return (*(ptr_nsresult()));
}
const nsresult&
get_nsresult() const
{
AssertSanity(Tnsresult);
return (*(constptr_nsresult()));
}
operator nsresult&()
{
return get_nsresult();
}
operator const nsresult&() const
{
return get_nsresult();
}
SDBRequestOpenResponse&
get_SDBRequestOpenResponse()
{
AssertSanity(TSDBRequestOpenResponse);
return (*(ptr_SDBRequestOpenResponse()));
}
const SDBRequestOpenResponse&
get_SDBRequestOpenResponse() const
{
AssertSanity(TSDBRequestOpenResponse);
return (*(constptr_SDBRequestOpenResponse()));
}
operator SDBRequestOpenResponse&()
{
return get_SDBRequestOpenResponse();
}
operator const SDBRequestOpenResponse&() const
{
return get_SDBRequestOpenResponse();
}
SDBRequestSeekResponse&
get_SDBRequestSeekResponse()
{
AssertSanity(TSDBRequestSeekResponse);
return (*(ptr_SDBRequestSeekResponse()));
}
const SDBRequestSeekResponse&
get_SDBRequestSeekResponse() const
{
AssertSanity(TSDBRequestSeekResponse);
return (*(constptr_SDBRequestSeekResponse()));
}
operator SDBRequestSeekResponse&()
{
return get_SDBRequestSeekResponse();
}
operator const SDBRequestSeekResponse&() const
{
return get_SDBRequestSeekResponse();
}
SDBRequestReadResponse&
get_SDBRequestReadResponse()
{
AssertSanity(TSDBRequestReadResponse);
return (*(ptr_SDBRequestReadResponse()));
}
const SDBRequestReadResponse&
get_SDBRequestReadResponse() const
{
AssertSanity(TSDBRequestReadResponse);
return (*(constptr_SDBRequestReadResponse()));
}
operator SDBRequestReadResponse&()
{
return get_SDBRequestReadResponse();
}
operator const SDBRequestReadResponse&() const
{
return get_SDBRequestReadResponse();
}
SDBRequestWriteResponse&
get_SDBRequestWriteResponse()
{
AssertSanity(TSDBRequestWriteResponse);
return (*(ptr_SDBRequestWriteResponse()));
}
const SDBRequestWriteResponse&
get_SDBRequestWriteResponse() const
{
AssertSanity(TSDBRequestWriteResponse);
return (*(constptr_SDBRequestWriteResponse()));
}
operator SDBRequestWriteResponse&()
{
return get_SDBRequestWriteResponse();
}
operator const SDBRequestWriteResponse&() const
{
return get_SDBRequestWriteResponse();
}
SDBRequestCloseResponse&
get_SDBRequestCloseResponse()
{
AssertSanity(TSDBRequestCloseResponse);
return (*(ptr_SDBRequestCloseResponse()));
}
const SDBRequestCloseResponse&
get_SDBRequestCloseResponse() const
{
AssertSanity(TSDBRequestCloseResponse);
return (*(constptr_SDBRequestCloseResponse()));
}
operator SDBRequestCloseResponse&()
{
return get_SDBRequestCloseResponse();
}
operator const SDBRequestCloseResponse&() const
{
return get_SDBRequestCloseResponse();
}
private:
union {
nsresult mVnsresult;
SDBRequestOpenResponse mVSDBRequestOpenResponse;
SDBRequestSeekResponse mVSDBRequestSeekResponse;
SDBRequestReadResponse mVSDBRequestReadResponse;
SDBRequestWriteResponse mVSDBRequestWriteResponse;
SDBRequestCloseResponse mVSDBRequestCloseResponse;
};
Type mType;
};
} // namespace dom
} // namespace mozilla
namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::SDBRequestResponse>
{
typedef ::mozilla::dom::SDBRequestResponse paramType;
static void
Write(
IPC::MessageWriter* aWriter,
const paramType& aVar);
static IPC::ReadResult<paramType>
Read(IPC::MessageReader* aReader);
};
} // namespace IPC
namespace mozilla {
namespace dom {
class PBackgroundSDBRequestParent;
} // namespace dom
} // namespace mozilla
namespace mozilla {
namespace dom {
class PBackgroundSDBRequestChild;
} // namespace dom
} // namespace mozilla
//-----------------------------------------------------------------------------
// Code common to PBackgroundSDBRequestChild and PBackgroundSDBRequestParent
//
namespace mozilla {
namespace dom {
namespace PBackgroundSDBRequest {
nsresult
CreateEndpoints(
mozilla::ipc::EndpointProcInfo aParentDestInfo,
mozilla::ipc::EndpointProcInfo aChildDestInfo,
mozilla::ipc::Endpoint<::mozilla::dom::PBackgroundSDBRequestParent>* aParent,
mozilla::ipc::Endpoint<::mozilla::dom::PBackgroundSDBRequestChild>* aChild);
enum MessageType {
PBackgroundSDBRequestStart = PBackgroundSDBRequestMsgStart << 16,
Msg___delete____ID,
Reply___delete____ID,
PBackgroundSDBRequestEnd
};
mozilla::UniquePtr<IPC::Message>
Msg___delete__(int32_t routingId);
mozilla::UniquePtr<IPC::Message>
Reply___delete__(int32_t routingId);
} // namespace PBackgroundSDBRequest
} // namespace dom
} // namespace mozilla
#endif // ifndef PBackgroundSDBRequest_h