//
// Automatically generated by ipdlc.
// Edit at your own risk
//

#ifndef InputStreamParams_h
#define InputStreamParams_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/RemoteLazyInputStream.h"
#include "mozilla/ipc/DataPipe.h"
#include "mozilla/ipc/IPDLStructMember.h"
#include "mozilla/ipc/ProtocolTypes.h"


//-----------------------------------------------------------------------------
// Declaration of the IPDL type |struct HeaderEntry|
//
namespace mozilla {
namespace ipc {
class HeaderEntry 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
    HeaderEntry() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT HeaderEntry(
            const nsCString& _name,
            const nsCString& _value) :
        name_(_name),
        value_(_value)
    {
    }

    MOZ_IMPLICIT HeaderEntry(
            nsCString&& _name,
            nsCString&& _value) :
        name_(std::move(_name)),
        value_(std::move(_value))
    {
    }

    nsCString&
    name()
    {
        return name_;
    }
    const nsCString&
    name() const
    {
        return name_;
    }

    nsCString&
    value()
    {
        return value_;
    }
    const nsCString&
    value() const
    {
        return value_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsCString> name_;
    ::mozilla::ipc::IPDLStructMember<nsCString> value_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::HeaderEntry>
{
    typedef ::mozilla::ipc::HeaderEntry 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 StringInputStreamParams|
//
namespace mozilla {
namespace ipc {
class StringInputStreamParams 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
    StringInputStreamParams() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT StringInputStreamParams(const nsCString& _data) :
        data_(_data)
    {
    }

    MOZ_IMPLICIT StringInputStreamParams(nsCString&& _data) :
        data_(std::move(_data))
    {
    }

    nsCString&
    data()
    {
        return data_;
    }
    const nsCString&
    data() const
    {
        return data_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsCString> data_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::StringInputStreamParams>
{
    typedef ::mozilla::ipc::StringInputStreamParams 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 FileInputStreamParams|
//
namespace mozilla {
namespace ipc {
class FileInputStreamParams final
{
private:
    typedef ::mozilla::ipc::FileDescriptor FileDescriptor;
    typedef ::int32_t int32_t;

public:
#ifdef __clang__
#  pragma clang diagnostic push
#  if __has_warning("-Wdefaulted-function-deleted")
#    pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
#  endif
#endif
    FileInputStreamParams() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT FileInputStreamParams(
            const FileDescriptor& _fileDescriptor,
            const int32_t& _behaviorFlags,
            const int32_t& _ioFlags) :
        fileDescriptor_(_fileDescriptor),
        behaviorFlags_(_behaviorFlags),
        ioFlags_(_ioFlags)
    {
    }

    MOZ_IMPLICIT FileInputStreamParams(
            FileDescriptor&& _fileDescriptor,
            int32_t&& _behaviorFlags,
            int32_t&& _ioFlags) :
        fileDescriptor_(std::move(_fileDescriptor)),
        behaviorFlags_(std::move(_behaviorFlags)),
        ioFlags_(std::move(_ioFlags))
    {
    }

    FileDescriptor&
    fileDescriptor()
    {
        return fileDescriptor_;
    }
    const FileDescriptor&
    fileDescriptor() const
    {
        return fileDescriptor_;
    }

    int32_t&
    behaviorFlags()
    {
        return behaviorFlags_;
    }
    const int32_t&
    behaviorFlags() const
    {
        return behaviorFlags_;
    }

    int32_t&
    ioFlags()
    {
        return ioFlags_;
    }
    const int32_t&
    ioFlags() const
    {
        return ioFlags_;
    }

private:
    void
    StaticAssertions() const;
    ::mozilla::ipc::IPDLStructMember<FileDescriptor> fileDescriptor_;
    ::mozilla::ipc::IPDLStructMember<int32_t> behaviorFlags_;
    ::mozilla::ipc::IPDLStructMember<int32_t> ioFlags_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::FileInputStreamParams>
{
    typedef ::mozilla::ipc::FileInputStreamParams 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 RemoteLazyInputStreamParams|
//
namespace mozilla {
namespace ipc {
class RemoteLazyInputStreamParams final
{
private:
    typedef ::mozilla::RemoteLazyInputStream RemoteLazyInputStream;

public:
#ifdef __clang__
#  pragma clang diagnostic push
#  if __has_warning("-Wdefaulted-function-deleted")
#    pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
#  endif
#endif
    RemoteLazyInputStreamParams() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT RemoteLazyInputStreamParams(mozilla::NotNull<RemoteLazyInputStream*> _stream) :
        stream_(_stream)
    {
    }

    MOZ_IMPLICIT RemoteLazyInputStreamParams(mozilla::NotNull<RefPtr<RemoteLazyInputStream>>&& _stream) :
        stream_(std::move(_stream))
    {
    }

    mozilla::NotNull<RefPtr<RemoteLazyInputStream>>&
    stream()
    {
        return stream_;
    }
    mozilla::NotNull<RemoteLazyInputStream*>
    stream() const
    {
        return stream_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<mozilla::NotNull<RefPtr<RemoteLazyInputStream>>> stream_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::RemoteLazyInputStreamParams>
{
    typedef ::mozilla::ipc::RemoteLazyInputStreamParams 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 DataPipeReceiverStreamParams|
//
namespace mozilla {
namespace ipc {
class DataPipeReceiverStreamParams final
{
private:
    typedef ::mozilla::ipc::DataPipeReceiver DataPipeReceiver;

public:
#ifdef __clang__
#  pragma clang diagnostic push
#  if __has_warning("-Wdefaulted-function-deleted")
#    pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
#  endif
#endif
    DataPipeReceiverStreamParams() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT DataPipeReceiverStreamParams(mozilla::NotNull<DataPipeReceiver*> _pipe) :
        pipe_(_pipe)
    {
    }

    MOZ_IMPLICIT DataPipeReceiverStreamParams(mozilla::NotNull<RefPtr<DataPipeReceiver>>&& _pipe) :
        pipe_(std::move(_pipe))
    {
    }

    mozilla::NotNull<RefPtr<DataPipeReceiver>>&
    pipe()
    {
        return pipe_;
    }
    mozilla::NotNull<DataPipeReceiver*>
    pipe() const
    {
        return pipe_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<mozilla::NotNull<RefPtr<DataPipeReceiver>>> pipe_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::DataPipeReceiverStreamParams>
{
    typedef ::mozilla::ipc::DataPipeReceiverStreamParams paramType;
    static void
    Write(
            IPC::MessageWriter* aWriter,
            const paramType& aVar);
    static IPC::ReadResult<paramType>
    Read(IPC::MessageReader* aReader);
};
} // namespace IPC

namespace mozilla {
namespace ipc {
class BufferedInputStreamParams;
} // namespace ipc
} // namespace mozilla
namespace mozilla {
namespace ipc {
class MIMEInputStreamParams;
} // namespace ipc
} // namespace mozilla
namespace mozilla {
namespace ipc {
class MultiplexInputStreamParams;
} // namespace ipc
} // namespace mozilla
namespace mozilla {
namespace ipc {
class SlicedInputStreamParams;
} // namespace ipc
} // namespace mozilla
namespace mozilla {
namespace ipc {
class InputStreamLengthWrapperParams;
} // namespace ipc
} // namespace mozilla
namespace mozilla {
namespace ipc {
class EncryptedFileInputStreamParams;
} // namespace ipc
} // namespace mozilla

//-----------------------------------------------------------------------------
// Declaration of the IPDL type |union InputStreamParams|
//
namespace mozilla {
namespace ipc {
class InputStreamParams final
{
public:
    enum Type {
        T__None,
        TStringInputStreamParams = 1,
        TFileInputStreamParams,
        TBufferedInputStreamParams,
        TMIMEInputStreamParams,
        TMultiplexInputStreamParams,
        TSlicedInputStreamParams,
        TRemoteLazyInputStreamParams,
        TInputStreamLengthWrapperParams,
        TEncryptedFileInputStreamParams,
        TDataPipeReceiverStreamParams,
        T__Last = TDataPipeReceiverStreamParams
    };

private:
    typedef ::mozilla::ipc::StringInputStreamParams StringInputStreamParams;
    typedef ::mozilla::ipc::FileInputStreamParams FileInputStreamParams;
    typedef ::mozilla::ipc::BufferedInputStreamParams BufferedInputStreamParams;
    typedef ::mozilla::ipc::MIMEInputStreamParams MIMEInputStreamParams;
    typedef ::mozilla::ipc::MultiplexInputStreamParams MultiplexInputStreamParams;
    typedef ::mozilla::ipc::SlicedInputStreamParams SlicedInputStreamParams;
    typedef ::mozilla::ipc::RemoteLazyInputStreamParams RemoteLazyInputStreamParams;
    typedef ::mozilla::ipc::InputStreamLengthWrapperParams InputStreamLengthWrapperParams;
    typedef ::mozilla::ipc::EncryptedFileInputStreamParams EncryptedFileInputStreamParams;
    typedef ::mozilla::ipc::DataPipeReceiverStreamParams DataPipeReceiverStreamParams;
    typedef StringInputStreamParams StringInputStreamParams__tdef;
    typedef FileInputStreamParams FileInputStreamParams__tdef;
    typedef BufferedInputStreamParams* BufferedInputStreamParams__tdef;
    typedef MIMEInputStreamParams* MIMEInputStreamParams__tdef;
    typedef MultiplexInputStreamParams* MultiplexInputStreamParams__tdef;
    typedef SlicedInputStreamParams* SlicedInputStreamParams__tdef;
    typedef RemoteLazyInputStreamParams RemoteLazyInputStreamParams__tdef;
    typedef InputStreamLengthWrapperParams* InputStreamLengthWrapperParams__tdef;
    typedef EncryptedFileInputStreamParams* EncryptedFileInputStreamParams__tdef;
    typedef DataPipeReceiverStreamParams DataPipeReceiverStreamParams__tdef;

    StringInputStreamParams*
    ptr_StringInputStreamParams()
    {
        return (&(mVStringInputStreamParams));
    }
    const StringInputStreamParams*
    constptr_StringInputStreamParams() const
    {
        return (&(mVStringInputStreamParams));
    }
    FileInputStreamParams*
    ptr_FileInputStreamParams()
    {
        return (&(mVFileInputStreamParams));
    }
    const FileInputStreamParams*
    constptr_FileInputStreamParams() const
    {
        return (&(mVFileInputStreamParams));
    }
    BufferedInputStreamParams*&
    ptr_BufferedInputStreamParams()
    {
        return mVBufferedInputStreamParams;
    }
    const BufferedInputStreamParams*
    constptr_BufferedInputStreamParams() const
    {
        return mVBufferedInputStreamParams;
    }
    MIMEInputStreamParams*&
    ptr_MIMEInputStreamParams()
    {
        return mVMIMEInputStreamParams;
    }
    const MIMEInputStreamParams*
    constptr_MIMEInputStreamParams() const
    {
        return mVMIMEInputStreamParams;
    }
    MultiplexInputStreamParams*&
    ptr_MultiplexInputStreamParams()
    {
        return mVMultiplexInputStreamParams;
    }
    const MultiplexInputStreamParams*
    constptr_MultiplexInputStreamParams() const
    {
        return mVMultiplexInputStreamParams;
    }
    SlicedInputStreamParams*&
    ptr_SlicedInputStreamParams()
    {
        return mVSlicedInputStreamParams;
    }
    const SlicedInputStreamParams*
    constptr_SlicedInputStreamParams() const
    {
        return mVSlicedInputStreamParams;
    }
    RemoteLazyInputStreamParams*
    ptr_RemoteLazyInputStreamParams()
    {
        return (&(mVRemoteLazyInputStreamParams));
    }
    const RemoteLazyInputStreamParams*
    constptr_RemoteLazyInputStreamParams() const
    {
        return (&(mVRemoteLazyInputStreamParams));
    }
    InputStreamLengthWrapperParams*&
    ptr_InputStreamLengthWrapperParams()
    {
        return mVInputStreamLengthWrapperParams;
    }
    const InputStreamLengthWrapperParams*
    constptr_InputStreamLengthWrapperParams() const
    {
        return mVInputStreamLengthWrapperParams;
    }
    EncryptedFileInputStreamParams*&
    ptr_EncryptedFileInputStreamParams()
    {
        return mVEncryptedFileInputStreamParams;
    }
    const EncryptedFileInputStreamParams*
    constptr_EncryptedFileInputStreamParams() const
    {
        return mVEncryptedFileInputStreamParams;
    }
    DataPipeReceiverStreamParams*
    ptr_DataPipeReceiverStreamParams()
    {
        return (&(mVDataPipeReceiverStreamParams));
    }
    const DataPipeReceiverStreamParams*
    constptr_DataPipeReceiverStreamParams() const
    {
        return (&(mVDataPipeReceiverStreamParams));
    }

    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 InputStreamParams() :
        mType(T__None)
    {
    }

    MOZ_IMPLICIT InputStreamParams(const StringInputStreamParams& aOther);

    MOZ_IMPLICIT InputStreamParams(StringInputStreamParams&& aOther);

    MOZ_IMPLICIT InputStreamParams(const FileInputStreamParams& aOther);

    MOZ_IMPLICIT InputStreamParams(FileInputStreamParams&& aOther);

    MOZ_IMPLICIT InputStreamParams(const BufferedInputStreamParams& aOther);

    MOZ_IMPLICIT InputStreamParams(BufferedInputStreamParams&& aOther);

    MOZ_IMPLICIT InputStreamParams(const MIMEInputStreamParams& aOther);

    MOZ_IMPLICIT InputStreamParams(MIMEInputStreamParams&& aOther);

    MOZ_IMPLICIT InputStreamParams(const MultiplexInputStreamParams& aOther);

    MOZ_IMPLICIT InputStreamParams(MultiplexInputStreamParams&& aOther);

    MOZ_IMPLICIT InputStreamParams(const SlicedInputStreamParams& aOther);

    MOZ_IMPLICIT InputStreamParams(SlicedInputStreamParams&& aOther);

    MOZ_IMPLICIT InputStreamParams(const RemoteLazyInputStreamParams& aOther);

    MOZ_IMPLICIT InputStreamParams(RemoteLazyInputStreamParams&& aOther);

    MOZ_IMPLICIT InputStreamParams(const InputStreamLengthWrapperParams& aOther);

    MOZ_IMPLICIT InputStreamParams(InputStreamLengthWrapperParams&& aOther);

    MOZ_IMPLICIT InputStreamParams(const EncryptedFileInputStreamParams& aOther);

    MOZ_IMPLICIT InputStreamParams(EncryptedFileInputStreamParams&& aOther);

    MOZ_IMPLICIT InputStreamParams(const DataPipeReceiverStreamParams& aOther);

    MOZ_IMPLICIT InputStreamParams(DataPipeReceiverStreamParams&& aOther);

    MOZ_IMPLICIT InputStreamParams(const InputStreamParams& aOther);

    MOZ_IMPLICIT InputStreamParams(InputStreamParams&& aOther);

    ~InputStreamParams();

    Type
    type() const
    {
        return mType;
    }

    InputStreamParams&
    operator=(const StringInputStreamParams& aRhs);

    InputStreamParams&
    operator=(StringInputStreamParams&& aRhs);

    InputStreamParams&
    operator=(const FileInputStreamParams& aRhs);

    InputStreamParams&
    operator=(FileInputStreamParams&& aRhs);

    InputStreamParams&
    operator=(const BufferedInputStreamParams& aRhs);

    InputStreamParams&
    operator=(BufferedInputStreamParams&& aRhs);

    InputStreamParams&
    operator=(const MIMEInputStreamParams& aRhs);

    InputStreamParams&
    operator=(MIMEInputStreamParams&& aRhs);

    InputStreamParams&
    operator=(const MultiplexInputStreamParams& aRhs);

    InputStreamParams&
    operator=(MultiplexInputStreamParams&& aRhs);

    InputStreamParams&
    operator=(const SlicedInputStreamParams& aRhs);

    InputStreamParams&
    operator=(SlicedInputStreamParams&& aRhs);

    InputStreamParams&
    operator=(const RemoteLazyInputStreamParams& aRhs);

    InputStreamParams&
    operator=(RemoteLazyInputStreamParams&& aRhs);

    InputStreamParams&
    operator=(const InputStreamLengthWrapperParams& aRhs);

    InputStreamParams&
    operator=(InputStreamLengthWrapperParams&& aRhs);

    InputStreamParams&
    operator=(const EncryptedFileInputStreamParams& aRhs);

    InputStreamParams&
    operator=(EncryptedFileInputStreamParams&& aRhs);

    InputStreamParams&
    operator=(const DataPipeReceiverStreamParams& aRhs);

    InputStreamParams&
    operator=(DataPipeReceiverStreamParams&& aRhs);

    InputStreamParams&
    operator=(const InputStreamParams& aRhs);

    InputStreamParams&
    operator=(InputStreamParams&& aRhs);

    StringInputStreamParams&
    get_StringInputStreamParams()
    {
        AssertSanity(TStringInputStreamParams);
        return (*(ptr_StringInputStreamParams()));
    }
    const StringInputStreamParams&
    get_StringInputStreamParams() const
    {
        AssertSanity(TStringInputStreamParams);
        return (*(constptr_StringInputStreamParams()));
    }
    operator StringInputStreamParams&()
    {
        return get_StringInputStreamParams();
    }
    operator const StringInputStreamParams&() const
    {
        return get_StringInputStreamParams();
    }

    FileInputStreamParams&
    get_FileInputStreamParams()
    {
        AssertSanity(TFileInputStreamParams);
        return (*(ptr_FileInputStreamParams()));
    }
    const FileInputStreamParams&
    get_FileInputStreamParams() const
    {
        AssertSanity(TFileInputStreamParams);
        return (*(constptr_FileInputStreamParams()));
    }
    operator FileInputStreamParams&()
    {
        return get_FileInputStreamParams();
    }
    operator const FileInputStreamParams&() const
    {
        return get_FileInputStreamParams();
    }

    BufferedInputStreamParams&
    get_BufferedInputStreamParams()
    {
        AssertSanity(TBufferedInputStreamParams);
        return (*(ptr_BufferedInputStreamParams()));
    }
    const BufferedInputStreamParams&
    get_BufferedInputStreamParams() const
    {
        AssertSanity(TBufferedInputStreamParams);
        return (*(constptr_BufferedInputStreamParams()));
    }
    operator BufferedInputStreamParams&()
    {
        return get_BufferedInputStreamParams();
    }
    operator const BufferedInputStreamParams&() const
    {
        return get_BufferedInputStreamParams();
    }

    MIMEInputStreamParams&
    get_MIMEInputStreamParams()
    {
        AssertSanity(TMIMEInputStreamParams);
        return (*(ptr_MIMEInputStreamParams()));
    }
    const MIMEInputStreamParams&
    get_MIMEInputStreamParams() const
    {
        AssertSanity(TMIMEInputStreamParams);
        return (*(constptr_MIMEInputStreamParams()));
    }
    operator MIMEInputStreamParams&()
    {
        return get_MIMEInputStreamParams();
    }
    operator const MIMEInputStreamParams&() const
    {
        return get_MIMEInputStreamParams();
    }

    MultiplexInputStreamParams&
    get_MultiplexInputStreamParams()
    {
        AssertSanity(TMultiplexInputStreamParams);
        return (*(ptr_MultiplexInputStreamParams()));
    }
    const MultiplexInputStreamParams&
    get_MultiplexInputStreamParams() const
    {
        AssertSanity(TMultiplexInputStreamParams);
        return (*(constptr_MultiplexInputStreamParams()));
    }
    operator MultiplexInputStreamParams&()
    {
        return get_MultiplexInputStreamParams();
    }
    operator const MultiplexInputStreamParams&() const
    {
        return get_MultiplexInputStreamParams();
    }

    SlicedInputStreamParams&
    get_SlicedInputStreamParams()
    {
        AssertSanity(TSlicedInputStreamParams);
        return (*(ptr_SlicedInputStreamParams()));
    }
    const SlicedInputStreamParams&
    get_SlicedInputStreamParams() const
    {
        AssertSanity(TSlicedInputStreamParams);
        return (*(constptr_SlicedInputStreamParams()));
    }
    operator SlicedInputStreamParams&()
    {
        return get_SlicedInputStreamParams();
    }
    operator const SlicedInputStreamParams&() const
    {
        return get_SlicedInputStreamParams();
    }

    RemoteLazyInputStreamParams&
    get_RemoteLazyInputStreamParams()
    {
        AssertSanity(TRemoteLazyInputStreamParams);
        return (*(ptr_RemoteLazyInputStreamParams()));
    }
    const RemoteLazyInputStreamParams&
    get_RemoteLazyInputStreamParams() const
    {
        AssertSanity(TRemoteLazyInputStreamParams);
        return (*(constptr_RemoteLazyInputStreamParams()));
    }
    operator RemoteLazyInputStreamParams&()
    {
        return get_RemoteLazyInputStreamParams();
    }
    operator const RemoteLazyInputStreamParams&() const
    {
        return get_RemoteLazyInputStreamParams();
    }

    InputStreamLengthWrapperParams&
    get_InputStreamLengthWrapperParams()
    {
        AssertSanity(TInputStreamLengthWrapperParams);
        return (*(ptr_InputStreamLengthWrapperParams()));
    }
    const InputStreamLengthWrapperParams&
    get_InputStreamLengthWrapperParams() const
    {
        AssertSanity(TInputStreamLengthWrapperParams);
        return (*(constptr_InputStreamLengthWrapperParams()));
    }
    operator InputStreamLengthWrapperParams&()
    {
        return get_InputStreamLengthWrapperParams();
    }
    operator const InputStreamLengthWrapperParams&() const
    {
        return get_InputStreamLengthWrapperParams();
    }

    EncryptedFileInputStreamParams&
    get_EncryptedFileInputStreamParams()
    {
        AssertSanity(TEncryptedFileInputStreamParams);
        return (*(ptr_EncryptedFileInputStreamParams()));
    }
    const EncryptedFileInputStreamParams&
    get_EncryptedFileInputStreamParams() const
    {
        AssertSanity(TEncryptedFileInputStreamParams);
        return (*(constptr_EncryptedFileInputStreamParams()));
    }
    operator EncryptedFileInputStreamParams&()
    {
        return get_EncryptedFileInputStreamParams();
    }
    operator const EncryptedFileInputStreamParams&() const
    {
        return get_EncryptedFileInputStreamParams();
    }

    DataPipeReceiverStreamParams&
    get_DataPipeReceiverStreamParams()
    {
        AssertSanity(TDataPipeReceiverStreamParams);
        return (*(ptr_DataPipeReceiverStreamParams()));
    }
    const DataPipeReceiverStreamParams&
    get_DataPipeReceiverStreamParams() const
    {
        AssertSanity(TDataPipeReceiverStreamParams);
        return (*(constptr_DataPipeReceiverStreamParams()));
    }
    operator DataPipeReceiverStreamParams&()
    {
        return get_DataPipeReceiverStreamParams();
    }
    operator const DataPipeReceiverStreamParams&() const
    {
        return get_DataPipeReceiverStreamParams();
    }

private:
    union {
        StringInputStreamParams mVStringInputStreamParams;
        FileInputStreamParams mVFileInputStreamParams;
        BufferedInputStreamParams* mVBufferedInputStreamParams;
        MIMEInputStreamParams* mVMIMEInputStreamParams;
        MultiplexInputStreamParams* mVMultiplexInputStreamParams;
        SlicedInputStreamParams* mVSlicedInputStreamParams;
        RemoteLazyInputStreamParams mVRemoteLazyInputStreamParams;
        InputStreamLengthWrapperParams* mVInputStreamLengthWrapperParams;
        EncryptedFileInputStreamParams* mVEncryptedFileInputStreamParams;
        DataPipeReceiverStreamParams mVDataPipeReceiverStreamParams;
    };
    Type mType;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::InputStreamParams>
{
    typedef ::mozilla::ipc::InputStreamParams 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 MultiplexInputStreamParams|
//
namespace mozilla {
namespace ipc {
class MultiplexInputStreamParams final
{
private:
    typedef ::mozilla::ipc::InputStreamParams InputStreamParams;
    typedef ::uint32_t uint32_t;
    typedef ::nsresult nsresult;

public:
#ifdef __clang__
#  pragma clang diagnostic push
#  if __has_warning("-Wdefaulted-function-deleted")
#    pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
#  endif
#endif
    MultiplexInputStreamParams() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT MultiplexInputStreamParams(
            const nsTArray<InputStreamParams>& _streams,
            const uint32_t& _currentStream,
            const nsresult& _status,
            const bool& _startedReadingCurrent) :
        streams_(_streams),
        status_(_status),
        startedReadingCurrent_(_startedReadingCurrent),
        currentStream_(_currentStream)
    {
    }

    MOZ_IMPLICIT MultiplexInputStreamParams(
            nsTArray<InputStreamParams>&& _streams,
            uint32_t&& _currentStream,
            nsresult&& _status,
            bool&& _startedReadingCurrent) :
        streams_(std::move(_streams)),
        status_(std::move(_status)),
        startedReadingCurrent_(std::move(_startedReadingCurrent)),
        currentStream_(std::move(_currentStream))
    {
    }

    nsTArray<InputStreamParams>&
    streams()
    {
        return streams_;
    }
    const nsTArray<InputStreamParams>&
    streams() const
    {
        return streams_;
    }

    uint32_t&
    currentStream()
    {
        return currentStream_;
    }
    const uint32_t&
    currentStream() const
    {
        return currentStream_;
    }

    nsresult&
    status()
    {
        return status_;
    }
    const nsresult&
    status() const
    {
        return status_;
    }

    bool&
    startedReadingCurrent()
    {
        return startedReadingCurrent_;
    }
    const bool&
    startedReadingCurrent() const
    {
        return startedReadingCurrent_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<CopyableTArray<InputStreamParams>> streams_;
    ::mozilla::ipc::IPDLStructMember<nsresult> status_;
    ::mozilla::ipc::IPDLStructMember<bool> startedReadingCurrent_;
    ::mozilla::ipc::IPDLStructMember<uint32_t> currentStream_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::MultiplexInputStreamParams>
{
    typedef ::mozilla::ipc::MultiplexInputStreamParams 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 SlicedInputStreamParams|
//
namespace mozilla {
namespace ipc {
class SlicedInputStreamParams final
{
private:
    typedef ::mozilla::ipc::InputStreamParams InputStreamParams;
    typedef ::uint64_t uint64_t;

public:
#ifdef __clang__
#  pragma clang diagnostic push
#  if __has_warning("-Wdefaulted-function-deleted")
#    pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
#  endif
#endif
    SlicedInputStreamParams() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT SlicedInputStreamParams(
            const InputStreamParams& _stream,
            const uint64_t& _start,
            const uint64_t& _length,
            const uint64_t& _curPos,
            const bool& _closed) :
        stream_(_stream),
        closed_(_closed),
        start_(_start),
        length_(_length),
        curPos_(_curPos)
    {
    }

    MOZ_IMPLICIT SlicedInputStreamParams(
            InputStreamParams&& _stream,
            uint64_t&& _start,
            uint64_t&& _length,
            uint64_t&& _curPos,
            bool&& _closed) :
        stream_(std::move(_stream)),
        closed_(std::move(_closed)),
        start_(std::move(_start)),
        length_(std::move(_length)),
        curPos_(std::move(_curPos))
    {
    }

    InputStreamParams&
    stream()
    {
        return stream_;
    }
    const InputStreamParams&
    stream() const
    {
        return stream_;
    }

    uint64_t&
    start()
    {
        return start_;
    }
    const uint64_t&
    start() const
    {
        return start_;
    }

    uint64_t&
    length()
    {
        return length_;
    }
    const uint64_t&
    length() const
    {
        return length_;
    }

    uint64_t&
    curPos()
    {
        return curPos_;
    }
    const uint64_t&
    curPos() const
    {
        return curPos_;
    }

    bool&
    closed()
    {
        return closed_;
    }
    const bool&
    closed() const
    {
        return closed_;
    }

private:
    void
    StaticAssertions() const;
    ::mozilla::ipc::IPDLStructMember<InputStreamParams> stream_;
    ::mozilla::ipc::IPDLStructMember<bool> closed_;
    ::mozilla::ipc::IPDLStructMember<uint64_t> start_;
    ::mozilla::ipc::IPDLStructMember<uint64_t> length_;
    ::mozilla::ipc::IPDLStructMember<uint64_t> curPos_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::SlicedInputStreamParams>
{
    typedef ::mozilla::ipc::SlicedInputStreamParams 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 EncryptedFileInputStreamParams|
//
namespace mozilla {
namespace ipc {
class EncryptedFileInputStreamParams final
{
private:
    typedef ::mozilla::ipc::InputStreamParams InputStreamParams;
    typedef ::uint8_t uint8_t;
    typedef ::uint32_t uint32_t;

public:
#ifdef __clang__
#  pragma clang diagnostic push
#  if __has_warning("-Wdefaulted-function-deleted")
#    pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
#  endif
#endif
    EncryptedFileInputStreamParams() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT EncryptedFileInputStreamParams(
            const InputStreamParams& _inputStreamParams,
            const nsTArray<uint8_t>& _key,
            const uint32_t& _blockSize) :
        inputStreamParams_(_inputStreamParams),
        key_(_key),
        blockSize_(_blockSize)
    {
    }

    MOZ_IMPLICIT EncryptedFileInputStreamParams(
            InputStreamParams&& _inputStreamParams,
            nsTArray<uint8_t>&& _key,
            uint32_t&& _blockSize) :
        inputStreamParams_(std::move(_inputStreamParams)),
        key_(std::move(_key)),
        blockSize_(std::move(_blockSize))
    {
    }

    InputStreamParams&
    inputStreamParams()
    {
        return inputStreamParams_;
    }
    const InputStreamParams&
    inputStreamParams() const
    {
        return inputStreamParams_;
    }

    nsTArray<uint8_t>&
    key()
    {
        return key_;
    }
    const nsTArray<uint8_t>&
    key() const
    {
        return key_;
    }

    uint32_t&
    blockSize()
    {
        return blockSize_;
    }
    const uint32_t&
    blockSize() const
    {
        return blockSize_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<InputStreamParams> inputStreamParams_;
    ::mozilla::ipc::IPDLStructMember<CopyableTArray<uint8_t>> key_;
    ::mozilla::ipc::IPDLStructMember<uint32_t> blockSize_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::EncryptedFileInputStreamParams>
{
    typedef ::mozilla::ipc::EncryptedFileInputStreamParams 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 BufferedInputStreamParams|
//
namespace mozilla {
namespace ipc {
class BufferedInputStreamParams final
{
private:
    typedef ::mozilla::ipc::InputStreamParams InputStreamParams;
    typedef ::uint32_t uint32_t;

public:
#ifdef __clang__
#  pragma clang diagnostic push
#  if __has_warning("-Wdefaulted-function-deleted")
#    pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
#  endif
#endif
    BufferedInputStreamParams() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT BufferedInputStreamParams(
            const mozilla::Maybe<InputStreamParams>& _optionalStream,
            const uint32_t& _bufferSize) :
        optionalStream_(_optionalStream),
        bufferSize_(_bufferSize)
    {
    }

    MOZ_IMPLICIT BufferedInputStreamParams(
            mozilla::Maybe<InputStreamParams>&& _optionalStream,
            uint32_t&& _bufferSize) :
        optionalStream_(std::move(_optionalStream)),
        bufferSize_(std::move(_bufferSize))
    {
    }

    mozilla::Maybe<InputStreamParams>&
    optionalStream()
    {
        return optionalStream_;
    }
    const mozilla::Maybe<InputStreamParams>&
    optionalStream() const
    {
        return optionalStream_;
    }

    uint32_t&
    bufferSize()
    {
        return bufferSize_;
    }
    const uint32_t&
    bufferSize() const
    {
        return bufferSize_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<mozilla::Maybe<InputStreamParams>> optionalStream_;
    ::mozilla::ipc::IPDLStructMember<uint32_t> bufferSize_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::BufferedInputStreamParams>
{
    typedef ::mozilla::ipc::BufferedInputStreamParams 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 MIMEInputStreamParams|
//
namespace mozilla {
namespace ipc {
class MIMEInputStreamParams final
{
private:
    typedef ::mozilla::ipc::InputStreamParams InputStreamParams;
    typedef ::mozilla::ipc::HeaderEntry HeaderEntry;

public:
#ifdef __clang__
#  pragma clang diagnostic push
#  if __has_warning("-Wdefaulted-function-deleted")
#    pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
#  endif
#endif
    MIMEInputStreamParams() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT MIMEInputStreamParams(
            const mozilla::Maybe<InputStreamParams>& _optionalStream,
            const nsTArray<HeaderEntry>& _headers,
            const bool& _startedReading) :
        optionalStream_(_optionalStream),
        headers_(_headers),
        startedReading_(_startedReading)
    {
    }

    MOZ_IMPLICIT MIMEInputStreamParams(
            mozilla::Maybe<InputStreamParams>&& _optionalStream,
            nsTArray<HeaderEntry>&& _headers,
            bool&& _startedReading) :
        optionalStream_(std::move(_optionalStream)),
        headers_(std::move(_headers)),
        startedReading_(std::move(_startedReading))
    {
    }

    mozilla::Maybe<InputStreamParams>&
    optionalStream()
    {
        return optionalStream_;
    }
    const mozilla::Maybe<InputStreamParams>&
    optionalStream() const
    {
        return optionalStream_;
    }

    nsTArray<HeaderEntry>&
    headers()
    {
        return headers_;
    }
    const nsTArray<HeaderEntry>&
    headers() const
    {
        return headers_;
    }

    bool&
    startedReading()
    {
        return startedReading_;
    }
    const bool&
    startedReading() const
    {
        return startedReading_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<mozilla::Maybe<InputStreamParams>> optionalStream_;
    ::mozilla::ipc::IPDLStructMember<CopyableTArray<HeaderEntry>> headers_;
    ::mozilla::ipc::IPDLStructMember<bool> startedReading_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::MIMEInputStreamParams>
{
    typedef ::mozilla::ipc::MIMEInputStreamParams 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 InputStreamLengthWrapperParams|
//
namespace mozilla {
namespace ipc {
class InputStreamLengthWrapperParams final
{
private:
    typedef ::mozilla::ipc::InputStreamParams InputStreamParams;
    typedef ::int64_t int64_t;

public:
#ifdef __clang__
#  pragma clang diagnostic push
#  if __has_warning("-Wdefaulted-function-deleted")
#    pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
#  endif
#endif
    InputStreamLengthWrapperParams() = default;
#ifdef __clang__
#  pragma clang diagnostic pop
#endif

    MOZ_IMPLICIT InputStreamLengthWrapperParams(
            const InputStreamParams& _stream,
            const int64_t& _length,
            const bool& _consumed) :
        stream_(_stream),
        consumed_(_consumed),
        length_(_length)
    {
    }

    MOZ_IMPLICIT InputStreamLengthWrapperParams(
            InputStreamParams&& _stream,
            int64_t&& _length,
            bool&& _consumed) :
        stream_(std::move(_stream)),
        consumed_(std::move(_consumed)),
        length_(std::move(_length))
    {
    }

    InputStreamParams&
    stream()
    {
        return stream_;
    }
    const InputStreamParams&
    stream() const
    {
        return stream_;
    }

    int64_t&
    length()
    {
        return length_;
    }
    const int64_t&
    length() const
    {
        return length_;
    }

    bool&
    consumed()
    {
        return consumed_;
    }
    const bool&
    consumed() const
    {
        return consumed_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<InputStreamParams> stream_;
    ::mozilla::ipc::IPDLStructMember<bool> consumed_;
    ::mozilla::ipc::IPDLStructMember<int64_t> length_;
};
} // namespace ipc
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::ipc::InputStreamLengthWrapperParams>
{
    typedef ::mozilla::ipc::InputStreamLengthWrapperParams paramType;
    static void
    Write(
            IPC::MessageWriter* aWriter,
            const paramType& aVar);
    static IPC::ReadResult<paramType>
    Read(IPC::MessageReader* aReader);
};
} // namespace IPC

#endif // ifndef InputStreamParams_h
