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

#ifndef PPaymentRequest_h
#define PPaymentRequest_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"
#include "nsIPrincipal.h"


//-----------------------------------------------------------------------------
// Declaration of the IPDL type |struct IPCPaymentMethodData|
//
namespace mozilla {
namespace dom {
class IPCPaymentMethodData final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentMethodData(
            const nsString& _supportedMethods,
            const nsString& _data) :
        supportedMethods_(_supportedMethods),
        data_(_data)
    {
    }

    MOZ_IMPLICIT IPCPaymentMethodData(
            nsString&& _supportedMethods,
            nsString&& _data) :
        supportedMethods_(std::move(_supportedMethods)),
        data_(std::move(_data))
    {
    }

    nsString&
    supportedMethods()
    {
        return supportedMethods_;
    }
    const nsString&
    supportedMethods() const
    {
        return supportedMethods_;
    }

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

private:
    ::mozilla::ipc::IPDLStructMember<nsString> supportedMethods_;
    ::mozilla::ipc::IPDLStructMember<nsString> data_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentMethodData>
{
    typedef ::mozilla::dom::IPCPaymentMethodData 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 IPCPaymentCurrencyAmount|
//
namespace mozilla {
namespace dom {
class IPCPaymentCurrencyAmount final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentCurrencyAmount(
            const nsString& _currency,
            const nsString& _value) :
        currency_(_currency),
        value_(_value)
    {
    }

    MOZ_IMPLICIT IPCPaymentCurrencyAmount(
            nsString&& _currency,
            nsString&& _value) :
        currency_(std::move(_currency)),
        value_(std::move(_value))
    {
    }

    nsString&
    currency()
    {
        return currency_;
    }
    const nsString&
    currency() const
    {
        return currency_;
    }

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

private:
    ::mozilla::ipc::IPDLStructMember<nsString> currency_;
    ::mozilla::ipc::IPDLStructMember<nsString> value_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentCurrencyAmount>
{
    typedef ::mozilla::dom::IPCPaymentCurrencyAmount 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 IPCPaymentItem|
//
namespace mozilla {
namespace dom {
class IPCPaymentItem final
{
private:
    typedef ::nsString nsString;
    typedef ::mozilla::dom::IPCPaymentCurrencyAmount IPCPaymentCurrencyAmount;

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

    MOZ_IMPLICIT IPCPaymentItem(
            const nsString& _label,
            const IPCPaymentCurrencyAmount& _amount,
            const bool& _pending) :
        label_(_label),
        amount_(_amount),
        pending_(_pending)
    {
    }

    MOZ_IMPLICIT IPCPaymentItem(
            nsString&& _label,
            IPCPaymentCurrencyAmount&& _amount,
            bool&& _pending) :
        label_(std::move(_label)),
        amount_(std::move(_amount)),
        pending_(std::move(_pending))
    {
    }

    nsString&
    label()
    {
        return label_;
    }
    const nsString&
    label() const
    {
        return label_;
    }

    IPCPaymentCurrencyAmount&
    amount()
    {
        return amount_;
    }
    const IPCPaymentCurrencyAmount&
    amount() const
    {
        return amount_;
    }

    bool&
    pending()
    {
        return pending_;
    }
    const bool&
    pending() const
    {
        return pending_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> label_;
    ::mozilla::ipc::IPDLStructMember<IPCPaymentCurrencyAmount> amount_;
    ::mozilla::ipc::IPDLStructMember<bool> pending_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentItem>
{
    typedef ::mozilla::dom::IPCPaymentItem 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 IPCPaymentDetailsModifier|
//
namespace mozilla {
namespace dom {
class IPCPaymentDetailsModifier final
{
private:
    typedef ::nsString nsString;
    typedef ::mozilla::dom::IPCPaymentItem IPCPaymentItem;

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

    MOZ_IMPLICIT IPCPaymentDetailsModifier(
            const nsString& _supportedMethods,
            const IPCPaymentItem& _total,
            const nsTArray<IPCPaymentItem>& _additionalDisplayItems,
            const nsString& _data,
            const bool& _additionalDisplayItemsPassed) :
        supportedMethods_(_supportedMethods),
        total_(_total),
        additionalDisplayItems_(_additionalDisplayItems),
        data_(_data),
        additionalDisplayItemsPassed_(_additionalDisplayItemsPassed)
    {
    }

    MOZ_IMPLICIT IPCPaymentDetailsModifier(
            nsString&& _supportedMethods,
            IPCPaymentItem&& _total,
            nsTArray<IPCPaymentItem>&& _additionalDisplayItems,
            nsString&& _data,
            bool&& _additionalDisplayItemsPassed) :
        supportedMethods_(std::move(_supportedMethods)),
        total_(std::move(_total)),
        additionalDisplayItems_(std::move(_additionalDisplayItems)),
        data_(std::move(_data)),
        additionalDisplayItemsPassed_(std::move(_additionalDisplayItemsPassed))
    {
    }

    nsString&
    supportedMethods()
    {
        return supportedMethods_;
    }
    const nsString&
    supportedMethods() const
    {
        return supportedMethods_;
    }

    IPCPaymentItem&
    total()
    {
        return total_;
    }
    const IPCPaymentItem&
    total() const
    {
        return total_;
    }

    nsTArray<IPCPaymentItem>&
    additionalDisplayItems()
    {
        return additionalDisplayItems_;
    }
    const nsTArray<IPCPaymentItem>&
    additionalDisplayItems() const
    {
        return additionalDisplayItems_;
    }

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

    bool&
    additionalDisplayItemsPassed()
    {
        return additionalDisplayItemsPassed_;
    }
    const bool&
    additionalDisplayItemsPassed() const
    {
        return additionalDisplayItemsPassed_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> supportedMethods_;
    ::mozilla::ipc::IPDLStructMember<IPCPaymentItem> total_;
    ::mozilla::ipc::IPDLStructMember<CopyableTArray<IPCPaymentItem>> additionalDisplayItems_;
    ::mozilla::ipc::IPDLStructMember<nsString> data_;
    ::mozilla::ipc::IPDLStructMember<bool> additionalDisplayItemsPassed_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentDetailsModifier>
{
    typedef ::mozilla::dom::IPCPaymentDetailsModifier 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 IPCPaymentShippingOption|
//
namespace mozilla {
namespace dom {
class IPCPaymentShippingOption final
{
private:
    typedef ::nsString nsString;
    typedef ::mozilla::dom::IPCPaymentCurrencyAmount IPCPaymentCurrencyAmount;

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

    MOZ_IMPLICIT IPCPaymentShippingOption(
            const nsString& _id,
            const nsString& _label,
            const IPCPaymentCurrencyAmount& _amount,
            const bool& _selected) :
        id_(_id),
        label_(_label),
        amount_(_amount),
        selected_(_selected)
    {
    }

    MOZ_IMPLICIT IPCPaymentShippingOption(
            nsString&& _id,
            nsString&& _label,
            IPCPaymentCurrencyAmount&& _amount,
            bool&& _selected) :
        id_(std::move(_id)),
        label_(std::move(_label)),
        amount_(std::move(_amount)),
        selected_(std::move(_selected))
    {
    }

    nsString&
    id()
    {
        return id_;
    }
    const nsString&
    id() const
    {
        return id_;
    }

    nsString&
    label()
    {
        return label_;
    }
    const nsString&
    label() const
    {
        return label_;
    }

    IPCPaymentCurrencyAmount&
    amount()
    {
        return amount_;
    }
    const IPCPaymentCurrencyAmount&
    amount() const
    {
        return amount_;
    }

    bool&
    selected()
    {
        return selected_;
    }
    const bool&
    selected() const
    {
        return selected_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> id_;
    ::mozilla::ipc::IPDLStructMember<nsString> label_;
    ::mozilla::ipc::IPDLStructMember<IPCPaymentCurrencyAmount> amount_;
    ::mozilla::ipc::IPDLStructMember<bool> selected_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentShippingOption>
{
    typedef ::mozilla::dom::IPCPaymentShippingOption 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 IPCPaymentDetails|
//
namespace mozilla {
namespace dom {
class IPCPaymentDetails final
{
private:
    typedef ::nsString nsString;
    typedef ::mozilla::dom::IPCPaymentItem IPCPaymentItem;
    typedef ::mozilla::dom::IPCPaymentShippingOption IPCPaymentShippingOption;
    typedef ::mozilla::dom::IPCPaymentDetailsModifier IPCPaymentDetailsModifier;

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

    MOZ_IMPLICIT IPCPaymentDetails(
            const nsString& _id,
            const IPCPaymentItem& _total,
            const nsTArray<IPCPaymentItem>& _displayItems,
            const nsTArray<IPCPaymentShippingOption>& _shippingOptions,
            const nsTArray<IPCPaymentDetailsModifier>& _modifiers,
            const nsString& _error,
            const nsString& _shippingAddressErrors,
            const nsString& _payerErrors,
            const nsString& _paymentMethodErrors) :
        id_(_id),
        total_(_total),
        displayItems_(_displayItems),
        shippingOptions_(_shippingOptions),
        modifiers_(_modifiers),
        error_(_error),
        shippingAddressErrors_(_shippingAddressErrors),
        payerErrors_(_payerErrors),
        paymentMethodErrors_(_paymentMethodErrors)
    {
    }

    MOZ_IMPLICIT IPCPaymentDetails(
            nsString&& _id,
            IPCPaymentItem&& _total,
            nsTArray<IPCPaymentItem>&& _displayItems,
            nsTArray<IPCPaymentShippingOption>&& _shippingOptions,
            nsTArray<IPCPaymentDetailsModifier>&& _modifiers,
            nsString&& _error,
            nsString&& _shippingAddressErrors,
            nsString&& _payerErrors,
            nsString&& _paymentMethodErrors) :
        id_(std::move(_id)),
        total_(std::move(_total)),
        displayItems_(std::move(_displayItems)),
        shippingOptions_(std::move(_shippingOptions)),
        modifiers_(std::move(_modifiers)),
        error_(std::move(_error)),
        shippingAddressErrors_(std::move(_shippingAddressErrors)),
        payerErrors_(std::move(_payerErrors)),
        paymentMethodErrors_(std::move(_paymentMethodErrors))
    {
    }

    nsString&
    id()
    {
        return id_;
    }
    const nsString&
    id() const
    {
        return id_;
    }

    IPCPaymentItem&
    total()
    {
        return total_;
    }
    const IPCPaymentItem&
    total() const
    {
        return total_;
    }

    nsTArray<IPCPaymentItem>&
    displayItems()
    {
        return displayItems_;
    }
    const nsTArray<IPCPaymentItem>&
    displayItems() const
    {
        return displayItems_;
    }

    nsTArray<IPCPaymentShippingOption>&
    shippingOptions()
    {
        return shippingOptions_;
    }
    const nsTArray<IPCPaymentShippingOption>&
    shippingOptions() const
    {
        return shippingOptions_;
    }

    nsTArray<IPCPaymentDetailsModifier>&
    modifiers()
    {
        return modifiers_;
    }
    const nsTArray<IPCPaymentDetailsModifier>&
    modifiers() const
    {
        return modifiers_;
    }

    nsString&
    error()
    {
        return error_;
    }
    const nsString&
    error() const
    {
        return error_;
    }

    nsString&
    shippingAddressErrors()
    {
        return shippingAddressErrors_;
    }
    const nsString&
    shippingAddressErrors() const
    {
        return shippingAddressErrors_;
    }

    nsString&
    payerErrors()
    {
        return payerErrors_;
    }
    const nsString&
    payerErrors() const
    {
        return payerErrors_;
    }

    nsString&
    paymentMethodErrors()
    {
        return paymentMethodErrors_;
    }
    const nsString&
    paymentMethodErrors() const
    {
        return paymentMethodErrors_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> id_;
    ::mozilla::ipc::IPDLStructMember<IPCPaymentItem> total_;
    ::mozilla::ipc::IPDLStructMember<CopyableTArray<IPCPaymentItem>> displayItems_;
    ::mozilla::ipc::IPDLStructMember<CopyableTArray<IPCPaymentShippingOption>> shippingOptions_;
    ::mozilla::ipc::IPDLStructMember<CopyableTArray<IPCPaymentDetailsModifier>> modifiers_;
    ::mozilla::ipc::IPDLStructMember<nsString> error_;
    ::mozilla::ipc::IPDLStructMember<nsString> shippingAddressErrors_;
    ::mozilla::ipc::IPDLStructMember<nsString> payerErrors_;
    ::mozilla::ipc::IPDLStructMember<nsString> paymentMethodErrors_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentDetails>
{
    typedef ::mozilla::dom::IPCPaymentDetails 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 IPCPaymentOptions|
//
namespace mozilla {
namespace dom {
class IPCPaymentOptions final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentOptions(
            const bool& _requestPayerName,
            const bool& _requestPayerEmail,
            const bool& _requestPayerPhone,
            const bool& _requestShipping,
            const bool& _requestBillingAddress,
            const nsString& _shippingType) :
        requestPayerName_(_requestPayerName),
        requestPayerEmail_(_requestPayerEmail),
        requestPayerPhone_(_requestPayerPhone),
        requestShipping_(_requestShipping),
        requestBillingAddress_(_requestBillingAddress),
        shippingType_(_shippingType)
    {
    }

    MOZ_IMPLICIT IPCPaymentOptions(
            bool&& _requestPayerName,
            bool&& _requestPayerEmail,
            bool&& _requestPayerPhone,
            bool&& _requestShipping,
            bool&& _requestBillingAddress,
            nsString&& _shippingType) :
        requestPayerName_(std::move(_requestPayerName)),
        requestPayerEmail_(std::move(_requestPayerEmail)),
        requestPayerPhone_(std::move(_requestPayerPhone)),
        requestShipping_(std::move(_requestShipping)),
        requestBillingAddress_(std::move(_requestBillingAddress)),
        shippingType_(std::move(_shippingType))
    {
    }

    bool&
    requestPayerName()
    {
        return requestPayerName_;
    }
    const bool&
    requestPayerName() const
    {
        return requestPayerName_;
    }

    bool&
    requestPayerEmail()
    {
        return requestPayerEmail_;
    }
    const bool&
    requestPayerEmail() const
    {
        return requestPayerEmail_;
    }

    bool&
    requestPayerPhone()
    {
        return requestPayerPhone_;
    }
    const bool&
    requestPayerPhone() const
    {
        return requestPayerPhone_;
    }

    bool&
    requestShipping()
    {
        return requestShipping_;
    }
    const bool&
    requestShipping() const
    {
        return requestShipping_;
    }

    bool&
    requestBillingAddress()
    {
        return requestBillingAddress_;
    }
    const bool&
    requestBillingAddress() const
    {
        return requestBillingAddress_;
    }

    nsString&
    shippingType()
    {
        return shippingType_;
    }
    const nsString&
    shippingType() const
    {
        return shippingType_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<bool> requestPayerName_;
    ::mozilla::ipc::IPDLStructMember<bool> requestPayerEmail_;
    ::mozilla::ipc::IPDLStructMember<bool> requestPayerPhone_;
    ::mozilla::ipc::IPDLStructMember<bool> requestShipping_;
    ::mozilla::ipc::IPDLStructMember<bool> requestBillingAddress_;
    ::mozilla::ipc::IPDLStructMember<nsString> shippingType_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentOptions>
{
    typedef ::mozilla::dom::IPCPaymentOptions 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 IPCPaymentCreateActionRequest|
//
namespace mozilla {
namespace dom {
class IPCPaymentCreateActionRequest final
{
private:
    typedef ::uint64_t uint64_t;
    typedef ::nsString nsString;
    typedef ::nsIPrincipal nsIPrincipal;
    typedef ::mozilla::dom::IPCPaymentMethodData IPCPaymentMethodData;
    typedef ::mozilla::dom::IPCPaymentDetails IPCPaymentDetails;
    typedef ::mozilla::dom::IPCPaymentOptions IPCPaymentOptions;

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

    MOZ_IMPLICIT IPCPaymentCreateActionRequest(
            const uint64_t& _topOuterWindowId,
            const nsString& _requestId,
            nsIPrincipal* _topLevelPrincipal,
            const nsTArray<IPCPaymentMethodData>& _methodData,
            const IPCPaymentDetails& _details,
            const IPCPaymentOptions& _options,
            const nsString& _shippingOption) :
        requestId_(_requestId),
        topLevelPrincipal_(_topLevelPrincipal),
        methodData_(_methodData),
        details_(_details),
        options_(_options),
        shippingOption_(_shippingOption),
        topOuterWindowId_(_topOuterWindowId)
    {
    }

    MOZ_IMPLICIT IPCPaymentCreateActionRequest(
            uint64_t&& _topOuterWindowId,
            nsString&& _requestId,
            RefPtr<nsIPrincipal>&& _topLevelPrincipal,
            nsTArray<IPCPaymentMethodData>&& _methodData,
            IPCPaymentDetails&& _details,
            IPCPaymentOptions&& _options,
            nsString&& _shippingOption) :
        requestId_(std::move(_requestId)),
        topLevelPrincipal_(std::move(_topLevelPrincipal)),
        methodData_(std::move(_methodData)),
        details_(std::move(_details)),
        options_(std::move(_options)),
        shippingOption_(std::move(_shippingOption)),
        topOuterWindowId_(std::move(_topOuterWindowId))
    {
    }

    uint64_t&
    topOuterWindowId()
    {
        return topOuterWindowId_;
    }
    const uint64_t&
    topOuterWindowId() const
    {
        return topOuterWindowId_;
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

    RefPtr<nsIPrincipal>&
    topLevelPrincipal()
    {
        return topLevelPrincipal_;
    }
    nsIPrincipal*
    topLevelPrincipal() const
    {
        return topLevelPrincipal_;
    }

    nsTArray<IPCPaymentMethodData>&
    methodData()
    {
        return methodData_;
    }
    const nsTArray<IPCPaymentMethodData>&
    methodData() const
    {
        return methodData_;
    }

    IPCPaymentDetails&
    details()
    {
        return details_;
    }
    const IPCPaymentDetails&
    details() const
    {
        return details_;
    }

    IPCPaymentOptions&
    options()
    {
        return options_;
    }
    const IPCPaymentOptions&
    options() const
    {
        return options_;
    }

    nsString&
    shippingOption()
    {
        return shippingOption_;
    }
    const nsString&
    shippingOption() const
    {
        return shippingOption_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
    ::mozilla::ipc::IPDLStructMember<RefPtr<nsIPrincipal>> topLevelPrincipal_;
    ::mozilla::ipc::IPDLStructMember<CopyableTArray<IPCPaymentMethodData>> methodData_;
    ::mozilla::ipc::IPDLStructMember<IPCPaymentDetails> details_;
    ::mozilla::ipc::IPDLStructMember<IPCPaymentOptions> options_;
    ::mozilla::ipc::IPDLStructMember<nsString> shippingOption_;
    ::mozilla::ipc::IPDLStructMember<uint64_t> topOuterWindowId_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentCreateActionRequest>
{
    typedef ::mozilla::dom::IPCPaymentCreateActionRequest 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 IPCPaymentCanMakeActionRequest|
//
namespace mozilla {
namespace dom {
class IPCPaymentCanMakeActionRequest final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentCanMakeActionRequest(const nsString& _requestId) :
        requestId_(_requestId)
    {
    }

    MOZ_IMPLICIT IPCPaymentCanMakeActionRequest(nsString&& _requestId) :
        requestId_(std::move(_requestId))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentCanMakeActionRequest>
{
    typedef ::mozilla::dom::IPCPaymentCanMakeActionRequest 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 IPCPaymentShowActionRequest|
//
namespace mozilla {
namespace dom {
class IPCPaymentShowActionRequest final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentShowActionRequest(
            const nsString& _requestId,
            const bool& _isUpdating) :
        requestId_(_requestId),
        isUpdating_(_isUpdating)
    {
    }

    MOZ_IMPLICIT IPCPaymentShowActionRequest(
            nsString&& _requestId,
            bool&& _isUpdating) :
        requestId_(std::move(_requestId)),
        isUpdating_(std::move(_isUpdating))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

    bool&
    isUpdating()
    {
        return isUpdating_;
    }
    const bool&
    isUpdating() const
    {
        return isUpdating_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
    ::mozilla::ipc::IPDLStructMember<bool> isUpdating_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentShowActionRequest>
{
    typedef ::mozilla::dom::IPCPaymentShowActionRequest 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 IPCPaymentAbortActionRequest|
//
namespace mozilla {
namespace dom {
class IPCPaymentAbortActionRequest final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentAbortActionRequest(const nsString& _requestId) :
        requestId_(_requestId)
    {
    }

    MOZ_IMPLICIT IPCPaymentAbortActionRequest(nsString&& _requestId) :
        requestId_(std::move(_requestId))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentAbortActionRequest>
{
    typedef ::mozilla::dom::IPCPaymentAbortActionRequest 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 IPCPaymentCompleteActionRequest|
//
namespace mozilla {
namespace dom {
class IPCPaymentCompleteActionRequest final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentCompleteActionRequest(
            const nsString& _requestId,
            const nsString& _completeStatus) :
        requestId_(_requestId),
        completeStatus_(_completeStatus)
    {
    }

    MOZ_IMPLICIT IPCPaymentCompleteActionRequest(
            nsString&& _requestId,
            nsString&& _completeStatus) :
        requestId_(std::move(_requestId)),
        completeStatus_(std::move(_completeStatus))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

    nsString&
    completeStatus()
    {
        return completeStatus_;
    }
    const nsString&
    completeStatus() const
    {
        return completeStatus_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
    ::mozilla::ipc::IPDLStructMember<nsString> completeStatus_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentCompleteActionRequest>
{
    typedef ::mozilla::dom::IPCPaymentCompleteActionRequest 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 IPCPaymentUpdateActionRequest|
//
namespace mozilla {
namespace dom {
class IPCPaymentUpdateActionRequest final
{
private:
    typedef ::nsString nsString;
    typedef ::mozilla::dom::IPCPaymentDetails IPCPaymentDetails;

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

    MOZ_IMPLICIT IPCPaymentUpdateActionRequest(
            const nsString& _requestId,
            const IPCPaymentDetails& _details,
            const nsString& _shippingOption) :
        requestId_(_requestId),
        details_(_details),
        shippingOption_(_shippingOption)
    {
    }

    MOZ_IMPLICIT IPCPaymentUpdateActionRequest(
            nsString&& _requestId,
            IPCPaymentDetails&& _details,
            nsString&& _shippingOption) :
        requestId_(std::move(_requestId)),
        details_(std::move(_details)),
        shippingOption_(std::move(_shippingOption))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

    IPCPaymentDetails&
    details()
    {
        return details_;
    }
    const IPCPaymentDetails&
    details() const
    {
        return details_;
    }

    nsString&
    shippingOption()
    {
        return shippingOption_;
    }
    const nsString&
    shippingOption() const
    {
        return shippingOption_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
    ::mozilla::ipc::IPDLStructMember<IPCPaymentDetails> details_;
    ::mozilla::ipc::IPDLStructMember<nsString> shippingOption_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentUpdateActionRequest>
{
    typedef ::mozilla::dom::IPCPaymentUpdateActionRequest 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 IPCPaymentCloseActionRequest|
//
namespace mozilla {
namespace dom {
class IPCPaymentCloseActionRequest final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentCloseActionRequest(const nsString& _requestId) :
        requestId_(_requestId)
    {
    }

    MOZ_IMPLICIT IPCPaymentCloseActionRequest(nsString&& _requestId) :
        requestId_(std::move(_requestId))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentCloseActionRequest>
{
    typedef ::mozilla::dom::IPCPaymentCloseActionRequest 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 IPCPaymentRetryActionRequest|
//
namespace mozilla {
namespace dom {
class IPCPaymentRetryActionRequest final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentRetryActionRequest(
            const nsString& _requestId,
            const nsString& _error,
            const nsString& _payerErrors,
            const nsString& _paymentMethodErrors,
            const nsString& _shippingAddressErrors) :
        requestId_(_requestId),
        error_(_error),
        payerErrors_(_payerErrors),
        paymentMethodErrors_(_paymentMethodErrors),
        shippingAddressErrors_(_shippingAddressErrors)
    {
    }

    MOZ_IMPLICIT IPCPaymentRetryActionRequest(
            nsString&& _requestId,
            nsString&& _error,
            nsString&& _payerErrors,
            nsString&& _paymentMethodErrors,
            nsString&& _shippingAddressErrors) :
        requestId_(std::move(_requestId)),
        error_(std::move(_error)),
        payerErrors_(std::move(_payerErrors)),
        paymentMethodErrors_(std::move(_paymentMethodErrors)),
        shippingAddressErrors_(std::move(_shippingAddressErrors))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

    nsString&
    error()
    {
        return error_;
    }
    const nsString&
    error() const
    {
        return error_;
    }

    nsString&
    payerErrors()
    {
        return payerErrors_;
    }
    const nsString&
    payerErrors() const
    {
        return payerErrors_;
    }

    nsString&
    paymentMethodErrors()
    {
        return paymentMethodErrors_;
    }
    const nsString&
    paymentMethodErrors() const
    {
        return paymentMethodErrors_;
    }

    nsString&
    shippingAddressErrors()
    {
        return shippingAddressErrors_;
    }
    const nsString&
    shippingAddressErrors() const
    {
        return shippingAddressErrors_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
    ::mozilla::ipc::IPDLStructMember<nsString> error_;
    ::mozilla::ipc::IPDLStructMember<nsString> payerErrors_;
    ::mozilla::ipc::IPDLStructMember<nsString> paymentMethodErrors_;
    ::mozilla::ipc::IPDLStructMember<nsString> shippingAddressErrors_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentRetryActionRequest>
{
    typedef ::mozilla::dom::IPCPaymentRetryActionRequest 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 IPCPaymentActionRequest|
//
namespace mozilla {
namespace dom {
class IPCPaymentActionRequest final
{
public:
    enum Type {
        T__None,
        TIPCPaymentCreateActionRequest = 1,
        TIPCPaymentCanMakeActionRequest,
        TIPCPaymentShowActionRequest,
        TIPCPaymentAbortActionRequest,
        TIPCPaymentCompleteActionRequest,
        TIPCPaymentUpdateActionRequest,
        TIPCPaymentCloseActionRequest,
        TIPCPaymentRetryActionRequest,
        T__Last = TIPCPaymentRetryActionRequest
    };

private:
    typedef ::mozilla::dom::IPCPaymentCreateActionRequest IPCPaymentCreateActionRequest;
    typedef ::mozilla::dom::IPCPaymentCanMakeActionRequest IPCPaymentCanMakeActionRequest;
    typedef ::mozilla::dom::IPCPaymentShowActionRequest IPCPaymentShowActionRequest;
    typedef ::mozilla::dom::IPCPaymentAbortActionRequest IPCPaymentAbortActionRequest;
    typedef ::mozilla::dom::IPCPaymentCompleteActionRequest IPCPaymentCompleteActionRequest;
    typedef ::mozilla::dom::IPCPaymentUpdateActionRequest IPCPaymentUpdateActionRequest;
    typedef ::mozilla::dom::IPCPaymentCloseActionRequest IPCPaymentCloseActionRequest;
    typedef ::mozilla::dom::IPCPaymentRetryActionRequest IPCPaymentRetryActionRequest;
    typedef IPCPaymentCreateActionRequest IPCPaymentCreateActionRequest__tdef;
    typedef IPCPaymentCanMakeActionRequest IPCPaymentCanMakeActionRequest__tdef;
    typedef IPCPaymentShowActionRequest IPCPaymentShowActionRequest__tdef;
    typedef IPCPaymentAbortActionRequest IPCPaymentAbortActionRequest__tdef;
    typedef IPCPaymentCompleteActionRequest IPCPaymentCompleteActionRequest__tdef;
    typedef IPCPaymentUpdateActionRequest IPCPaymentUpdateActionRequest__tdef;
    typedef IPCPaymentCloseActionRequest IPCPaymentCloseActionRequest__tdef;
    typedef IPCPaymentRetryActionRequest IPCPaymentRetryActionRequest__tdef;

    IPCPaymentCreateActionRequest*
    ptr_IPCPaymentCreateActionRequest()
    {
        return (&(mVIPCPaymentCreateActionRequest));
    }
    const IPCPaymentCreateActionRequest*
    constptr_IPCPaymentCreateActionRequest() const
    {
        return (&(mVIPCPaymentCreateActionRequest));
    }
    IPCPaymentCanMakeActionRequest*
    ptr_IPCPaymentCanMakeActionRequest()
    {
        return (&(mVIPCPaymentCanMakeActionRequest));
    }
    const IPCPaymentCanMakeActionRequest*
    constptr_IPCPaymentCanMakeActionRequest() const
    {
        return (&(mVIPCPaymentCanMakeActionRequest));
    }
    IPCPaymentShowActionRequest*
    ptr_IPCPaymentShowActionRequest()
    {
        return (&(mVIPCPaymentShowActionRequest));
    }
    const IPCPaymentShowActionRequest*
    constptr_IPCPaymentShowActionRequest() const
    {
        return (&(mVIPCPaymentShowActionRequest));
    }
    IPCPaymentAbortActionRequest*
    ptr_IPCPaymentAbortActionRequest()
    {
        return (&(mVIPCPaymentAbortActionRequest));
    }
    const IPCPaymentAbortActionRequest*
    constptr_IPCPaymentAbortActionRequest() const
    {
        return (&(mVIPCPaymentAbortActionRequest));
    }
    IPCPaymentCompleteActionRequest*
    ptr_IPCPaymentCompleteActionRequest()
    {
        return (&(mVIPCPaymentCompleteActionRequest));
    }
    const IPCPaymentCompleteActionRequest*
    constptr_IPCPaymentCompleteActionRequest() const
    {
        return (&(mVIPCPaymentCompleteActionRequest));
    }
    IPCPaymentUpdateActionRequest*
    ptr_IPCPaymentUpdateActionRequest()
    {
        return (&(mVIPCPaymentUpdateActionRequest));
    }
    const IPCPaymentUpdateActionRequest*
    constptr_IPCPaymentUpdateActionRequest() const
    {
        return (&(mVIPCPaymentUpdateActionRequest));
    }
    IPCPaymentCloseActionRequest*
    ptr_IPCPaymentCloseActionRequest()
    {
        return (&(mVIPCPaymentCloseActionRequest));
    }
    const IPCPaymentCloseActionRequest*
    constptr_IPCPaymentCloseActionRequest() const
    {
        return (&(mVIPCPaymentCloseActionRequest));
    }
    IPCPaymentRetryActionRequest*
    ptr_IPCPaymentRetryActionRequest()
    {
        return (&(mVIPCPaymentRetryActionRequest));
    }
    const IPCPaymentRetryActionRequest*
    constptr_IPCPaymentRetryActionRequest() const
    {
        return (&(mVIPCPaymentRetryActionRequest));
    }

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

    MOZ_IMPLICIT IPCPaymentActionRequest(const IPCPaymentCreateActionRequest& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(IPCPaymentCreateActionRequest&& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(const IPCPaymentCanMakeActionRequest& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(IPCPaymentCanMakeActionRequest&& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(const IPCPaymentShowActionRequest& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(IPCPaymentShowActionRequest&& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(const IPCPaymentAbortActionRequest& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(IPCPaymentAbortActionRequest&& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(const IPCPaymentCompleteActionRequest& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(IPCPaymentCompleteActionRequest&& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(const IPCPaymentUpdateActionRequest& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(IPCPaymentUpdateActionRequest&& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(const IPCPaymentCloseActionRequest& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(IPCPaymentCloseActionRequest&& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(const IPCPaymentRetryActionRequest& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(IPCPaymentRetryActionRequest&& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(const IPCPaymentActionRequest& aOther);

    MOZ_IMPLICIT IPCPaymentActionRequest(IPCPaymentActionRequest&& aOther);

    ~IPCPaymentActionRequest();

    Type
    type() const
    {
        return mType;
    }

    IPCPaymentActionRequest&
    operator=(const IPCPaymentCreateActionRequest& aRhs);

    IPCPaymentActionRequest&
    operator=(IPCPaymentCreateActionRequest&& aRhs);

    IPCPaymentActionRequest&
    operator=(const IPCPaymentCanMakeActionRequest& aRhs);

    IPCPaymentActionRequest&
    operator=(IPCPaymentCanMakeActionRequest&& aRhs);

    IPCPaymentActionRequest&
    operator=(const IPCPaymentShowActionRequest& aRhs);

    IPCPaymentActionRequest&
    operator=(IPCPaymentShowActionRequest&& aRhs);

    IPCPaymentActionRequest&
    operator=(const IPCPaymentAbortActionRequest& aRhs);

    IPCPaymentActionRequest&
    operator=(IPCPaymentAbortActionRequest&& aRhs);

    IPCPaymentActionRequest&
    operator=(const IPCPaymentCompleteActionRequest& aRhs);

    IPCPaymentActionRequest&
    operator=(IPCPaymentCompleteActionRequest&& aRhs);

    IPCPaymentActionRequest&
    operator=(const IPCPaymentUpdateActionRequest& aRhs);

    IPCPaymentActionRequest&
    operator=(IPCPaymentUpdateActionRequest&& aRhs);

    IPCPaymentActionRequest&
    operator=(const IPCPaymentCloseActionRequest& aRhs);

    IPCPaymentActionRequest&
    operator=(IPCPaymentCloseActionRequest&& aRhs);

    IPCPaymentActionRequest&
    operator=(const IPCPaymentRetryActionRequest& aRhs);

    IPCPaymentActionRequest&
    operator=(IPCPaymentRetryActionRequest&& aRhs);

    IPCPaymentActionRequest&
    operator=(const IPCPaymentActionRequest& aRhs);

    IPCPaymentActionRequest&
    operator=(IPCPaymentActionRequest&& aRhs);

    IPCPaymentCreateActionRequest&
    get_IPCPaymentCreateActionRequest()
    {
        AssertSanity(TIPCPaymentCreateActionRequest);
        return (*(ptr_IPCPaymentCreateActionRequest()));
    }
    const IPCPaymentCreateActionRequest&
    get_IPCPaymentCreateActionRequest() const
    {
        AssertSanity(TIPCPaymentCreateActionRequest);
        return (*(constptr_IPCPaymentCreateActionRequest()));
    }
    operator IPCPaymentCreateActionRequest&()
    {
        return get_IPCPaymentCreateActionRequest();
    }
    operator const IPCPaymentCreateActionRequest&() const
    {
        return get_IPCPaymentCreateActionRequest();
    }

    IPCPaymentCanMakeActionRequest&
    get_IPCPaymentCanMakeActionRequest()
    {
        AssertSanity(TIPCPaymentCanMakeActionRequest);
        return (*(ptr_IPCPaymentCanMakeActionRequest()));
    }
    const IPCPaymentCanMakeActionRequest&
    get_IPCPaymentCanMakeActionRequest() const
    {
        AssertSanity(TIPCPaymentCanMakeActionRequest);
        return (*(constptr_IPCPaymentCanMakeActionRequest()));
    }
    operator IPCPaymentCanMakeActionRequest&()
    {
        return get_IPCPaymentCanMakeActionRequest();
    }
    operator const IPCPaymentCanMakeActionRequest&() const
    {
        return get_IPCPaymentCanMakeActionRequest();
    }

    IPCPaymentShowActionRequest&
    get_IPCPaymentShowActionRequest()
    {
        AssertSanity(TIPCPaymentShowActionRequest);
        return (*(ptr_IPCPaymentShowActionRequest()));
    }
    const IPCPaymentShowActionRequest&
    get_IPCPaymentShowActionRequest() const
    {
        AssertSanity(TIPCPaymentShowActionRequest);
        return (*(constptr_IPCPaymentShowActionRequest()));
    }
    operator IPCPaymentShowActionRequest&()
    {
        return get_IPCPaymentShowActionRequest();
    }
    operator const IPCPaymentShowActionRequest&() const
    {
        return get_IPCPaymentShowActionRequest();
    }

    IPCPaymentAbortActionRequest&
    get_IPCPaymentAbortActionRequest()
    {
        AssertSanity(TIPCPaymentAbortActionRequest);
        return (*(ptr_IPCPaymentAbortActionRequest()));
    }
    const IPCPaymentAbortActionRequest&
    get_IPCPaymentAbortActionRequest() const
    {
        AssertSanity(TIPCPaymentAbortActionRequest);
        return (*(constptr_IPCPaymentAbortActionRequest()));
    }
    operator IPCPaymentAbortActionRequest&()
    {
        return get_IPCPaymentAbortActionRequest();
    }
    operator const IPCPaymentAbortActionRequest&() const
    {
        return get_IPCPaymentAbortActionRequest();
    }

    IPCPaymentCompleteActionRequest&
    get_IPCPaymentCompleteActionRequest()
    {
        AssertSanity(TIPCPaymentCompleteActionRequest);
        return (*(ptr_IPCPaymentCompleteActionRequest()));
    }
    const IPCPaymentCompleteActionRequest&
    get_IPCPaymentCompleteActionRequest() const
    {
        AssertSanity(TIPCPaymentCompleteActionRequest);
        return (*(constptr_IPCPaymentCompleteActionRequest()));
    }
    operator IPCPaymentCompleteActionRequest&()
    {
        return get_IPCPaymentCompleteActionRequest();
    }
    operator const IPCPaymentCompleteActionRequest&() const
    {
        return get_IPCPaymentCompleteActionRequest();
    }

    IPCPaymentUpdateActionRequest&
    get_IPCPaymentUpdateActionRequest()
    {
        AssertSanity(TIPCPaymentUpdateActionRequest);
        return (*(ptr_IPCPaymentUpdateActionRequest()));
    }
    const IPCPaymentUpdateActionRequest&
    get_IPCPaymentUpdateActionRequest() const
    {
        AssertSanity(TIPCPaymentUpdateActionRequest);
        return (*(constptr_IPCPaymentUpdateActionRequest()));
    }
    operator IPCPaymentUpdateActionRequest&()
    {
        return get_IPCPaymentUpdateActionRequest();
    }
    operator const IPCPaymentUpdateActionRequest&() const
    {
        return get_IPCPaymentUpdateActionRequest();
    }

    IPCPaymentCloseActionRequest&
    get_IPCPaymentCloseActionRequest()
    {
        AssertSanity(TIPCPaymentCloseActionRequest);
        return (*(ptr_IPCPaymentCloseActionRequest()));
    }
    const IPCPaymentCloseActionRequest&
    get_IPCPaymentCloseActionRequest() const
    {
        AssertSanity(TIPCPaymentCloseActionRequest);
        return (*(constptr_IPCPaymentCloseActionRequest()));
    }
    operator IPCPaymentCloseActionRequest&()
    {
        return get_IPCPaymentCloseActionRequest();
    }
    operator const IPCPaymentCloseActionRequest&() const
    {
        return get_IPCPaymentCloseActionRequest();
    }

    IPCPaymentRetryActionRequest&
    get_IPCPaymentRetryActionRequest()
    {
        AssertSanity(TIPCPaymentRetryActionRequest);
        return (*(ptr_IPCPaymentRetryActionRequest()));
    }
    const IPCPaymentRetryActionRequest&
    get_IPCPaymentRetryActionRequest() const
    {
        AssertSanity(TIPCPaymentRetryActionRequest);
        return (*(constptr_IPCPaymentRetryActionRequest()));
    }
    operator IPCPaymentRetryActionRequest&()
    {
        return get_IPCPaymentRetryActionRequest();
    }
    operator const IPCPaymentRetryActionRequest&() const
    {
        return get_IPCPaymentRetryActionRequest();
    }

private:
    union {
        IPCPaymentCreateActionRequest mVIPCPaymentCreateActionRequest;
        IPCPaymentCanMakeActionRequest mVIPCPaymentCanMakeActionRequest;
        IPCPaymentShowActionRequest mVIPCPaymentShowActionRequest;
        IPCPaymentAbortActionRequest mVIPCPaymentAbortActionRequest;
        IPCPaymentCompleteActionRequest mVIPCPaymentCompleteActionRequest;
        IPCPaymentUpdateActionRequest mVIPCPaymentUpdateActionRequest;
        IPCPaymentCloseActionRequest mVIPCPaymentCloseActionRequest;
        IPCPaymentRetryActionRequest mVIPCPaymentRetryActionRequest;
    };
    Type mType;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentActionRequest>
{
    typedef ::mozilla::dom::IPCPaymentActionRequest 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 IPCPaymentCanMakeActionResponse|
//
namespace mozilla {
namespace dom {
class IPCPaymentCanMakeActionResponse final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentCanMakeActionResponse(
            const nsString& _requestId,
            const bool& _result) :
        requestId_(_requestId),
        result_(_result)
    {
    }

    MOZ_IMPLICIT IPCPaymentCanMakeActionResponse(
            nsString&& _requestId,
            bool&& _result) :
        requestId_(std::move(_requestId)),
        result_(std::move(_result))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

    bool&
    result()
    {
        return result_;
    }
    const bool&
    result() const
    {
        return result_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
    ::mozilla::ipc::IPDLStructMember<bool> result_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentCanMakeActionResponse>
{
    typedef ::mozilla::dom::IPCPaymentCanMakeActionResponse 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 IPCPaymentAddress|
//
namespace mozilla {
namespace dom {
class IPCPaymentAddress final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentAddress(
            const nsString& _country,
            const nsTArray<nsString>& _addressLine,
            const nsString& _region,
            const nsString& _regionCode,
            const nsString& _city,
            const nsString& _dependentLocality,
            const nsString& _postalCode,
            const nsString& _sortingCode,
            const nsString& _organization,
            const nsString& _recipient,
            const nsString& _phone) :
        country_(_country),
        addressLine_(_addressLine),
        region_(_region),
        regionCode_(_regionCode),
        city_(_city),
        dependentLocality_(_dependentLocality),
        postalCode_(_postalCode),
        sortingCode_(_sortingCode),
        organization_(_organization),
        recipient_(_recipient),
        phone_(_phone)
    {
    }

    MOZ_IMPLICIT IPCPaymentAddress(
            nsString&& _country,
            nsTArray<nsString>&& _addressLine,
            nsString&& _region,
            nsString&& _regionCode,
            nsString&& _city,
            nsString&& _dependentLocality,
            nsString&& _postalCode,
            nsString&& _sortingCode,
            nsString&& _organization,
            nsString&& _recipient,
            nsString&& _phone) :
        country_(std::move(_country)),
        addressLine_(std::move(_addressLine)),
        region_(std::move(_region)),
        regionCode_(std::move(_regionCode)),
        city_(std::move(_city)),
        dependentLocality_(std::move(_dependentLocality)),
        postalCode_(std::move(_postalCode)),
        sortingCode_(std::move(_sortingCode)),
        organization_(std::move(_organization)),
        recipient_(std::move(_recipient)),
        phone_(std::move(_phone))
    {
    }

    nsString&
    country()
    {
        return country_;
    }
    const nsString&
    country() const
    {
        return country_;
    }

    nsTArray<nsString>&
    addressLine()
    {
        return addressLine_;
    }
    const nsTArray<nsString>&
    addressLine() const
    {
        return addressLine_;
    }

    nsString&
    region()
    {
        return region_;
    }
    const nsString&
    region() const
    {
        return region_;
    }

    nsString&
    regionCode()
    {
        return regionCode_;
    }
    const nsString&
    regionCode() const
    {
        return regionCode_;
    }

    nsString&
    city()
    {
        return city_;
    }
    const nsString&
    city() const
    {
        return city_;
    }

    nsString&
    dependentLocality()
    {
        return dependentLocality_;
    }
    const nsString&
    dependentLocality() const
    {
        return dependentLocality_;
    }

    nsString&
    postalCode()
    {
        return postalCode_;
    }
    const nsString&
    postalCode() const
    {
        return postalCode_;
    }

    nsString&
    sortingCode()
    {
        return sortingCode_;
    }
    const nsString&
    sortingCode() const
    {
        return sortingCode_;
    }

    nsString&
    organization()
    {
        return organization_;
    }
    const nsString&
    organization() const
    {
        return organization_;
    }

    nsString&
    recipient()
    {
        return recipient_;
    }
    const nsString&
    recipient() const
    {
        return recipient_;
    }

    nsString&
    phone()
    {
        return phone_;
    }
    const nsString&
    phone() const
    {
        return phone_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> country_;
    ::mozilla::ipc::IPDLStructMember<CopyableTArray<nsString>> addressLine_;
    ::mozilla::ipc::IPDLStructMember<nsString> region_;
    ::mozilla::ipc::IPDLStructMember<nsString> regionCode_;
    ::mozilla::ipc::IPDLStructMember<nsString> city_;
    ::mozilla::ipc::IPDLStructMember<nsString> dependentLocality_;
    ::mozilla::ipc::IPDLStructMember<nsString> postalCode_;
    ::mozilla::ipc::IPDLStructMember<nsString> sortingCode_;
    ::mozilla::ipc::IPDLStructMember<nsString> organization_;
    ::mozilla::ipc::IPDLStructMember<nsString> recipient_;
    ::mozilla::ipc::IPDLStructMember<nsString> phone_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentAddress>
{
    typedef ::mozilla::dom::IPCPaymentAddress 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 IPCGeneralResponse|
//
namespace mozilla {
namespace dom {
class IPCGeneralResponse final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCGeneralResponse(const nsString& _data) :
        data_(_data)
    {
    }

    MOZ_IMPLICIT IPCGeneralResponse(nsString&& _data) :
        data_(std::move(_data))
    {
    }

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

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

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCGeneralResponse>
{
    typedef ::mozilla::dom::IPCGeneralResponse 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 IPCBasicCardResponse|
//
namespace mozilla {
namespace dom {
class IPCBasicCardResponse final
{
private:
    typedef ::nsString nsString;
    typedef ::mozilla::dom::IPCPaymentAddress IPCPaymentAddress;

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

    MOZ_IMPLICIT IPCBasicCardResponse(
            const nsString& _cardholderName,
            const nsString& _cardNumber,
            const nsString& _expiryMonth,
            const nsString& _expiryYear,
            const nsString& _cardSecurityCode,
            const IPCPaymentAddress& _billingAddress) :
        cardholderName_(_cardholderName),
        cardNumber_(_cardNumber),
        expiryMonth_(_expiryMonth),
        expiryYear_(_expiryYear),
        cardSecurityCode_(_cardSecurityCode),
        billingAddress_(_billingAddress)
    {
    }

    MOZ_IMPLICIT IPCBasicCardResponse(
            nsString&& _cardholderName,
            nsString&& _cardNumber,
            nsString&& _expiryMonth,
            nsString&& _expiryYear,
            nsString&& _cardSecurityCode,
            IPCPaymentAddress&& _billingAddress) :
        cardholderName_(std::move(_cardholderName)),
        cardNumber_(std::move(_cardNumber)),
        expiryMonth_(std::move(_expiryMonth)),
        expiryYear_(std::move(_expiryYear)),
        cardSecurityCode_(std::move(_cardSecurityCode)),
        billingAddress_(std::move(_billingAddress))
    {
    }

    nsString&
    cardholderName()
    {
        return cardholderName_;
    }
    const nsString&
    cardholderName() const
    {
        return cardholderName_;
    }

    nsString&
    cardNumber()
    {
        return cardNumber_;
    }
    const nsString&
    cardNumber() const
    {
        return cardNumber_;
    }

    nsString&
    expiryMonth()
    {
        return expiryMonth_;
    }
    const nsString&
    expiryMonth() const
    {
        return expiryMonth_;
    }

    nsString&
    expiryYear()
    {
        return expiryYear_;
    }
    const nsString&
    expiryYear() const
    {
        return expiryYear_;
    }

    nsString&
    cardSecurityCode()
    {
        return cardSecurityCode_;
    }
    const nsString&
    cardSecurityCode() const
    {
        return cardSecurityCode_;
    }

    IPCPaymentAddress&
    billingAddress()
    {
        return billingAddress_;
    }
    const IPCPaymentAddress&
    billingAddress() const
    {
        return billingAddress_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> cardholderName_;
    ::mozilla::ipc::IPDLStructMember<nsString> cardNumber_;
    ::mozilla::ipc::IPDLStructMember<nsString> expiryMonth_;
    ::mozilla::ipc::IPDLStructMember<nsString> expiryYear_;
    ::mozilla::ipc::IPDLStructMember<nsString> cardSecurityCode_;
    ::mozilla::ipc::IPDLStructMember<IPCPaymentAddress> billingAddress_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCBasicCardResponse>
{
    typedef ::mozilla::dom::IPCBasicCardResponse 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 IPCPaymentResponseData|
//
namespace mozilla {
namespace dom {
class IPCPaymentResponseData final
{
public:
    enum Type {
        T__None,
        TIPCGeneralResponse = 1,
        TIPCBasicCardResponse,
        T__Last = TIPCBasicCardResponse
    };

private:
    typedef ::mozilla::dom::IPCGeneralResponse IPCGeneralResponse;
    typedef ::mozilla::dom::IPCBasicCardResponse IPCBasicCardResponse;
    typedef IPCGeneralResponse IPCGeneralResponse__tdef;
    typedef IPCBasicCardResponse IPCBasicCardResponse__tdef;

    IPCGeneralResponse*
    ptr_IPCGeneralResponse()
    {
        return (&(mVIPCGeneralResponse));
    }
    const IPCGeneralResponse*
    constptr_IPCGeneralResponse() const
    {
        return (&(mVIPCGeneralResponse));
    }
    IPCBasicCardResponse*
    ptr_IPCBasicCardResponse()
    {
        return (&(mVIPCBasicCardResponse));
    }
    const IPCBasicCardResponse*
    constptr_IPCBasicCardResponse() const
    {
        return (&(mVIPCBasicCardResponse));
    }

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

    MOZ_IMPLICIT IPCPaymentResponseData(const IPCGeneralResponse& aOther);

    MOZ_IMPLICIT IPCPaymentResponseData(IPCGeneralResponse&& aOther);

    MOZ_IMPLICIT IPCPaymentResponseData(const IPCBasicCardResponse& aOther);

    MOZ_IMPLICIT IPCPaymentResponseData(IPCBasicCardResponse&& aOther);

    MOZ_IMPLICIT IPCPaymentResponseData(const IPCPaymentResponseData& aOther);

    MOZ_IMPLICIT IPCPaymentResponseData(IPCPaymentResponseData&& aOther);

    ~IPCPaymentResponseData();

    Type
    type() const
    {
        return mType;
    }

    IPCPaymentResponseData&
    operator=(const IPCGeneralResponse& aRhs);

    IPCPaymentResponseData&
    operator=(IPCGeneralResponse&& aRhs);

    IPCPaymentResponseData&
    operator=(const IPCBasicCardResponse& aRhs);

    IPCPaymentResponseData&
    operator=(IPCBasicCardResponse&& aRhs);

    IPCPaymentResponseData&
    operator=(const IPCPaymentResponseData& aRhs);

    IPCPaymentResponseData&
    operator=(IPCPaymentResponseData&& aRhs);

    IPCGeneralResponse&
    get_IPCGeneralResponse()
    {
        AssertSanity(TIPCGeneralResponse);
        return (*(ptr_IPCGeneralResponse()));
    }
    const IPCGeneralResponse&
    get_IPCGeneralResponse() const
    {
        AssertSanity(TIPCGeneralResponse);
        return (*(constptr_IPCGeneralResponse()));
    }
    operator IPCGeneralResponse&()
    {
        return get_IPCGeneralResponse();
    }
    operator const IPCGeneralResponse&() const
    {
        return get_IPCGeneralResponse();
    }

    IPCBasicCardResponse&
    get_IPCBasicCardResponse()
    {
        AssertSanity(TIPCBasicCardResponse);
        return (*(ptr_IPCBasicCardResponse()));
    }
    const IPCBasicCardResponse&
    get_IPCBasicCardResponse() const
    {
        AssertSanity(TIPCBasicCardResponse);
        return (*(constptr_IPCBasicCardResponse()));
    }
    operator IPCBasicCardResponse&()
    {
        return get_IPCBasicCardResponse();
    }
    operator const IPCBasicCardResponse&() const
    {
        return get_IPCBasicCardResponse();
    }

private:
    union {
        IPCGeneralResponse mVIPCGeneralResponse;
        IPCBasicCardResponse mVIPCBasicCardResponse;
    };
    Type mType;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentResponseData>
{
    typedef ::mozilla::dom::IPCPaymentResponseData 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 IPCPaymentShowActionResponse|
//
namespace mozilla {
namespace dom {
class IPCPaymentShowActionResponse final
{
private:
    typedef ::nsString nsString;
    typedef ::uint32_t uint32_t;
    typedef ::mozilla::dom::IPCPaymentResponseData IPCPaymentResponseData;

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

    MOZ_IMPLICIT IPCPaymentShowActionResponse(
            const nsString& _requestId,
            const uint32_t& _status,
            const nsString& _methodName,
            const IPCPaymentResponseData& _data,
            const nsString& _payerName,
            const nsString& _payerEmail,
            const nsString& _payerPhone) :
        requestId_(_requestId),
        methodName_(_methodName),
        data_(_data),
        payerName_(_payerName),
        payerEmail_(_payerEmail),
        payerPhone_(_payerPhone),
        status_(_status)
    {
    }

    MOZ_IMPLICIT IPCPaymentShowActionResponse(
            nsString&& _requestId,
            uint32_t&& _status,
            nsString&& _methodName,
            IPCPaymentResponseData&& _data,
            nsString&& _payerName,
            nsString&& _payerEmail,
            nsString&& _payerPhone) :
        requestId_(std::move(_requestId)),
        methodName_(std::move(_methodName)),
        data_(std::move(_data)),
        payerName_(std::move(_payerName)),
        payerEmail_(std::move(_payerEmail)),
        payerPhone_(std::move(_payerPhone)),
        status_(std::move(_status))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

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

    nsString&
    methodName()
    {
        return methodName_;
    }
    const nsString&
    methodName() const
    {
        return methodName_;
    }

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

    nsString&
    payerName()
    {
        return payerName_;
    }
    const nsString&
    payerName() const
    {
        return payerName_;
    }

    nsString&
    payerEmail()
    {
        return payerEmail_;
    }
    const nsString&
    payerEmail() const
    {
        return payerEmail_;
    }

    nsString&
    payerPhone()
    {
        return payerPhone_;
    }
    const nsString&
    payerPhone() const
    {
        return payerPhone_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
    ::mozilla::ipc::IPDLStructMember<nsString> methodName_;
    ::mozilla::ipc::IPDLStructMember<IPCPaymentResponseData> data_;
    ::mozilla::ipc::IPDLStructMember<nsString> payerName_;
    ::mozilla::ipc::IPDLStructMember<nsString> payerEmail_;
    ::mozilla::ipc::IPDLStructMember<nsString> payerPhone_;
    ::mozilla::ipc::IPDLStructMember<uint32_t> status_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentShowActionResponse>
{
    typedef ::mozilla::dom::IPCPaymentShowActionResponse 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 IPCPaymentAbortActionResponse|
//
namespace mozilla {
namespace dom {
class IPCPaymentAbortActionResponse final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentAbortActionResponse(
            const nsString& _requestId,
            const bool& _isSucceeded) :
        requestId_(_requestId),
        isSucceeded_(_isSucceeded)
    {
    }

    MOZ_IMPLICIT IPCPaymentAbortActionResponse(
            nsString&& _requestId,
            bool&& _isSucceeded) :
        requestId_(std::move(_requestId)),
        isSucceeded_(std::move(_isSucceeded))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

    bool&
    isSucceeded()
    {
        return isSucceeded_;
    }
    const bool&
    isSucceeded() const
    {
        return isSucceeded_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
    ::mozilla::ipc::IPDLStructMember<bool> isSucceeded_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentAbortActionResponse>
{
    typedef ::mozilla::dom::IPCPaymentAbortActionResponse 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 IPCPaymentCompleteActionResponse|
//
namespace mozilla {
namespace dom {
class IPCPaymentCompleteActionResponse final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCPaymentCompleteActionResponse(
            const nsString& _requestId,
            const bool& _isCompleted) :
        requestId_(_requestId),
        isCompleted_(_isCompleted)
    {
    }

    MOZ_IMPLICIT IPCPaymentCompleteActionResponse(
            nsString&& _requestId,
            bool&& _isCompleted) :
        requestId_(std::move(_requestId)),
        isCompleted_(std::move(_isCompleted))
    {
    }

    nsString&
    requestId()
    {
        return requestId_;
    }
    const nsString&
    requestId() const
    {
        return requestId_;
    }

    bool&
    isCompleted()
    {
        return isCompleted_;
    }
    const bool&
    isCompleted() const
    {
        return isCompleted_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> requestId_;
    ::mozilla::ipc::IPDLStructMember<bool> isCompleted_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentCompleteActionResponse>
{
    typedef ::mozilla::dom::IPCPaymentCompleteActionResponse 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 IPCPaymentActionResponse|
//
namespace mozilla {
namespace dom {
class IPCPaymentActionResponse final
{
public:
    enum Type {
        T__None,
        TIPCPaymentCanMakeActionResponse = 1,
        TIPCPaymentShowActionResponse,
        TIPCPaymentAbortActionResponse,
        TIPCPaymentCompleteActionResponse,
        T__Last = TIPCPaymentCompleteActionResponse
    };

private:
    typedef ::mozilla::dom::IPCPaymentCanMakeActionResponse IPCPaymentCanMakeActionResponse;
    typedef ::mozilla::dom::IPCPaymentShowActionResponse IPCPaymentShowActionResponse;
    typedef ::mozilla::dom::IPCPaymentAbortActionResponse IPCPaymentAbortActionResponse;
    typedef ::mozilla::dom::IPCPaymentCompleteActionResponse IPCPaymentCompleteActionResponse;
    typedef IPCPaymentCanMakeActionResponse IPCPaymentCanMakeActionResponse__tdef;
    typedef IPCPaymentShowActionResponse IPCPaymentShowActionResponse__tdef;
    typedef IPCPaymentAbortActionResponse IPCPaymentAbortActionResponse__tdef;
    typedef IPCPaymentCompleteActionResponse IPCPaymentCompleteActionResponse__tdef;

    IPCPaymentCanMakeActionResponse*
    ptr_IPCPaymentCanMakeActionResponse()
    {
        return (&(mVIPCPaymentCanMakeActionResponse));
    }
    const IPCPaymentCanMakeActionResponse*
    constptr_IPCPaymentCanMakeActionResponse() const
    {
        return (&(mVIPCPaymentCanMakeActionResponse));
    }
    IPCPaymentShowActionResponse*
    ptr_IPCPaymentShowActionResponse()
    {
        return (&(mVIPCPaymentShowActionResponse));
    }
    const IPCPaymentShowActionResponse*
    constptr_IPCPaymentShowActionResponse() const
    {
        return (&(mVIPCPaymentShowActionResponse));
    }
    IPCPaymentAbortActionResponse*
    ptr_IPCPaymentAbortActionResponse()
    {
        return (&(mVIPCPaymentAbortActionResponse));
    }
    const IPCPaymentAbortActionResponse*
    constptr_IPCPaymentAbortActionResponse() const
    {
        return (&(mVIPCPaymentAbortActionResponse));
    }
    IPCPaymentCompleteActionResponse*
    ptr_IPCPaymentCompleteActionResponse()
    {
        return (&(mVIPCPaymentCompleteActionResponse));
    }
    const IPCPaymentCompleteActionResponse*
    constptr_IPCPaymentCompleteActionResponse() const
    {
        return (&(mVIPCPaymentCompleteActionResponse));
    }

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

    MOZ_IMPLICIT IPCPaymentActionResponse(const IPCPaymentCanMakeActionResponse& aOther);

    MOZ_IMPLICIT IPCPaymentActionResponse(IPCPaymentCanMakeActionResponse&& aOther);

    MOZ_IMPLICIT IPCPaymentActionResponse(const IPCPaymentShowActionResponse& aOther);

    MOZ_IMPLICIT IPCPaymentActionResponse(IPCPaymentShowActionResponse&& aOther);

    MOZ_IMPLICIT IPCPaymentActionResponse(const IPCPaymentAbortActionResponse& aOther);

    MOZ_IMPLICIT IPCPaymentActionResponse(IPCPaymentAbortActionResponse&& aOther);

    MOZ_IMPLICIT IPCPaymentActionResponse(const IPCPaymentCompleteActionResponse& aOther);

    MOZ_IMPLICIT IPCPaymentActionResponse(IPCPaymentCompleteActionResponse&& aOther);

    MOZ_IMPLICIT IPCPaymentActionResponse(const IPCPaymentActionResponse& aOther);

    MOZ_IMPLICIT IPCPaymentActionResponse(IPCPaymentActionResponse&& aOther);

    ~IPCPaymentActionResponse();

    Type
    type() const
    {
        return mType;
    }

    IPCPaymentActionResponse&
    operator=(const IPCPaymentCanMakeActionResponse& aRhs);

    IPCPaymentActionResponse&
    operator=(IPCPaymentCanMakeActionResponse&& aRhs);

    IPCPaymentActionResponse&
    operator=(const IPCPaymentShowActionResponse& aRhs);

    IPCPaymentActionResponse&
    operator=(IPCPaymentShowActionResponse&& aRhs);

    IPCPaymentActionResponse&
    operator=(const IPCPaymentAbortActionResponse& aRhs);

    IPCPaymentActionResponse&
    operator=(IPCPaymentAbortActionResponse&& aRhs);

    IPCPaymentActionResponse&
    operator=(const IPCPaymentCompleteActionResponse& aRhs);

    IPCPaymentActionResponse&
    operator=(IPCPaymentCompleteActionResponse&& aRhs);

    IPCPaymentActionResponse&
    operator=(const IPCPaymentActionResponse& aRhs);

    IPCPaymentActionResponse&
    operator=(IPCPaymentActionResponse&& aRhs);

    IPCPaymentCanMakeActionResponse&
    get_IPCPaymentCanMakeActionResponse()
    {
        AssertSanity(TIPCPaymentCanMakeActionResponse);
        return (*(ptr_IPCPaymentCanMakeActionResponse()));
    }
    const IPCPaymentCanMakeActionResponse&
    get_IPCPaymentCanMakeActionResponse() const
    {
        AssertSanity(TIPCPaymentCanMakeActionResponse);
        return (*(constptr_IPCPaymentCanMakeActionResponse()));
    }
    operator IPCPaymentCanMakeActionResponse&()
    {
        return get_IPCPaymentCanMakeActionResponse();
    }
    operator const IPCPaymentCanMakeActionResponse&() const
    {
        return get_IPCPaymentCanMakeActionResponse();
    }

    IPCPaymentShowActionResponse&
    get_IPCPaymentShowActionResponse()
    {
        AssertSanity(TIPCPaymentShowActionResponse);
        return (*(ptr_IPCPaymentShowActionResponse()));
    }
    const IPCPaymentShowActionResponse&
    get_IPCPaymentShowActionResponse() const
    {
        AssertSanity(TIPCPaymentShowActionResponse);
        return (*(constptr_IPCPaymentShowActionResponse()));
    }
    operator IPCPaymentShowActionResponse&()
    {
        return get_IPCPaymentShowActionResponse();
    }
    operator const IPCPaymentShowActionResponse&() const
    {
        return get_IPCPaymentShowActionResponse();
    }

    IPCPaymentAbortActionResponse&
    get_IPCPaymentAbortActionResponse()
    {
        AssertSanity(TIPCPaymentAbortActionResponse);
        return (*(ptr_IPCPaymentAbortActionResponse()));
    }
    const IPCPaymentAbortActionResponse&
    get_IPCPaymentAbortActionResponse() const
    {
        AssertSanity(TIPCPaymentAbortActionResponse);
        return (*(constptr_IPCPaymentAbortActionResponse()));
    }
    operator IPCPaymentAbortActionResponse&()
    {
        return get_IPCPaymentAbortActionResponse();
    }
    operator const IPCPaymentAbortActionResponse&() const
    {
        return get_IPCPaymentAbortActionResponse();
    }

    IPCPaymentCompleteActionResponse&
    get_IPCPaymentCompleteActionResponse()
    {
        AssertSanity(TIPCPaymentCompleteActionResponse);
        return (*(ptr_IPCPaymentCompleteActionResponse()));
    }
    const IPCPaymentCompleteActionResponse&
    get_IPCPaymentCompleteActionResponse() const
    {
        AssertSanity(TIPCPaymentCompleteActionResponse);
        return (*(constptr_IPCPaymentCompleteActionResponse()));
    }
    operator IPCPaymentCompleteActionResponse&()
    {
        return get_IPCPaymentCompleteActionResponse();
    }
    operator const IPCPaymentCompleteActionResponse&() const
    {
        return get_IPCPaymentCompleteActionResponse();
    }

private:
    union {
        IPCPaymentCanMakeActionResponse mVIPCPaymentCanMakeActionResponse;
        IPCPaymentShowActionResponse mVIPCPaymentShowActionResponse;
        IPCPaymentAbortActionResponse mVIPCPaymentAbortActionResponse;
        IPCPaymentCompleteActionResponse mVIPCPaymentCompleteActionResponse;
    };
    Type mType;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCPaymentActionResponse>
{
    typedef ::mozilla::dom::IPCPaymentActionResponse 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 IPCGeneralChangeDetails|
//
namespace mozilla {
namespace dom {
class IPCGeneralChangeDetails final
{
private:
    typedef ::nsString nsString;

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

    MOZ_IMPLICIT IPCGeneralChangeDetails(const nsString& _details) :
        details_(_details)
    {
    }

    MOZ_IMPLICIT IPCGeneralChangeDetails(nsString&& _details) :
        details_(std::move(_details))
    {
    }

    nsString&
    details()
    {
        return details_;
    }
    const nsString&
    details() const
    {
        return details_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<nsString> details_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCGeneralChangeDetails>
{
    typedef ::mozilla::dom::IPCGeneralChangeDetails 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 IPCBasicCardChangeDetails|
//
namespace mozilla {
namespace dom {
class IPCBasicCardChangeDetails final
{
private:
    typedef ::mozilla::dom::IPCPaymentAddress IPCPaymentAddress;

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

    MOZ_IMPLICIT IPCBasicCardChangeDetails(const IPCPaymentAddress& _billingAddress) :
        billingAddress_(_billingAddress)
    {
    }

    MOZ_IMPLICIT IPCBasicCardChangeDetails(IPCPaymentAddress&& _billingAddress) :
        billingAddress_(std::move(_billingAddress))
    {
    }

    IPCPaymentAddress&
    billingAddress()
    {
        return billingAddress_;
    }
    const IPCPaymentAddress&
    billingAddress() const
    {
        return billingAddress_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<IPCPaymentAddress> billingAddress_;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCBasicCardChangeDetails>
{
    typedef ::mozilla::dom::IPCBasicCardChangeDetails 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 IPCMethodChangeDetails|
//
namespace mozilla {
namespace dom {
class IPCMethodChangeDetails final
{
public:
    enum Type {
        T__None,
        TIPCGeneralChangeDetails = 1,
        TIPCBasicCardChangeDetails,
        T__Last = TIPCBasicCardChangeDetails
    };

private:
    typedef ::mozilla::dom::IPCGeneralChangeDetails IPCGeneralChangeDetails;
    typedef ::mozilla::dom::IPCBasicCardChangeDetails IPCBasicCardChangeDetails;
    typedef IPCGeneralChangeDetails IPCGeneralChangeDetails__tdef;
    typedef IPCBasicCardChangeDetails IPCBasicCardChangeDetails__tdef;

    IPCGeneralChangeDetails*
    ptr_IPCGeneralChangeDetails()
    {
        return (&(mVIPCGeneralChangeDetails));
    }
    const IPCGeneralChangeDetails*
    constptr_IPCGeneralChangeDetails() const
    {
        return (&(mVIPCGeneralChangeDetails));
    }
    IPCBasicCardChangeDetails*
    ptr_IPCBasicCardChangeDetails()
    {
        return (&(mVIPCBasicCardChangeDetails));
    }
    const IPCBasicCardChangeDetails*
    constptr_IPCBasicCardChangeDetails() const
    {
        return (&(mVIPCBasicCardChangeDetails));
    }

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

    MOZ_IMPLICIT IPCMethodChangeDetails(const IPCGeneralChangeDetails& aOther);

    MOZ_IMPLICIT IPCMethodChangeDetails(IPCGeneralChangeDetails&& aOther);

    MOZ_IMPLICIT IPCMethodChangeDetails(const IPCBasicCardChangeDetails& aOther);

    MOZ_IMPLICIT IPCMethodChangeDetails(IPCBasicCardChangeDetails&& aOther);

    MOZ_IMPLICIT IPCMethodChangeDetails(const IPCMethodChangeDetails& aOther);

    MOZ_IMPLICIT IPCMethodChangeDetails(IPCMethodChangeDetails&& aOther);

    ~IPCMethodChangeDetails();

    Type
    type() const
    {
        return mType;
    }

    IPCMethodChangeDetails&
    operator=(const IPCGeneralChangeDetails& aRhs);

    IPCMethodChangeDetails&
    operator=(IPCGeneralChangeDetails&& aRhs);

    IPCMethodChangeDetails&
    operator=(const IPCBasicCardChangeDetails& aRhs);

    IPCMethodChangeDetails&
    operator=(IPCBasicCardChangeDetails&& aRhs);

    IPCMethodChangeDetails&
    operator=(const IPCMethodChangeDetails& aRhs);

    IPCMethodChangeDetails&
    operator=(IPCMethodChangeDetails&& aRhs);

    IPCGeneralChangeDetails&
    get_IPCGeneralChangeDetails()
    {
        AssertSanity(TIPCGeneralChangeDetails);
        return (*(ptr_IPCGeneralChangeDetails()));
    }
    const IPCGeneralChangeDetails&
    get_IPCGeneralChangeDetails() const
    {
        AssertSanity(TIPCGeneralChangeDetails);
        return (*(constptr_IPCGeneralChangeDetails()));
    }
    operator IPCGeneralChangeDetails&()
    {
        return get_IPCGeneralChangeDetails();
    }
    operator const IPCGeneralChangeDetails&() const
    {
        return get_IPCGeneralChangeDetails();
    }

    IPCBasicCardChangeDetails&
    get_IPCBasicCardChangeDetails()
    {
        AssertSanity(TIPCBasicCardChangeDetails);
        return (*(ptr_IPCBasicCardChangeDetails()));
    }
    const IPCBasicCardChangeDetails&
    get_IPCBasicCardChangeDetails() const
    {
        AssertSanity(TIPCBasicCardChangeDetails);
        return (*(constptr_IPCBasicCardChangeDetails()));
    }
    operator IPCBasicCardChangeDetails&()
    {
        return get_IPCBasicCardChangeDetails();
    }
    operator const IPCBasicCardChangeDetails&() const
    {
        return get_IPCBasicCardChangeDetails();
    }

private:
    union {
        IPCGeneralChangeDetails mVIPCGeneralChangeDetails;
        IPCBasicCardChangeDetails mVIPCBasicCardChangeDetails;
    };
    Type mType;
};
} // namespace dom
} // namespace mozilla

namespace IPC {
template<>
struct ParamTraits <::mozilla::dom::IPCMethodChangeDetails>
{
    typedef ::mozilla::dom::IPCMethodChangeDetails 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 PPaymentRequestParent;
} // namespace dom
} // namespace mozilla
namespace mozilla {
namespace dom {
class PPaymentRequestChild;
} // namespace dom
} // namespace mozilla

//-----------------------------------------------------------------------------
// Code common to PPaymentRequestChild and PPaymentRequestParent
//
namespace mozilla {
namespace dom {
namespace PPaymentRequest {

nsresult
CreateEndpoints(
        mozilla::ipc::EndpointProcInfo aParentDestInfo,
        mozilla::ipc::EndpointProcInfo aChildDestInfo,
        mozilla::ipc::Endpoint<::mozilla::dom::PPaymentRequestParent>* aParent,
        mozilla::ipc::Endpoint<::mozilla::dom::PPaymentRequestChild>* aChild);

enum MessageType {
    PPaymentRequestStart = PPaymentRequestMsgStart << 16,
    Msg___delete____ID,
    Reply___delete____ID,
    Msg_RequestPayment__ID,
    Msg_RespondPayment__ID,
    Msg_ChangeShippingAddress__ID,
    Msg_ChangeShippingOption__ID,
    Msg_ChangePayerDetail__ID,
    Msg_ChangePaymentMethod__ID,
    PPaymentRequestEnd
};

mozilla::UniquePtr<IPC::Message>
Msg___delete__(IPC::Message::routeid_t routingId);
mozilla::UniquePtr<IPC::Message>
Reply___delete__(IPC::Message::routeid_t routingId);

mozilla::UniquePtr<IPC::Message>
Msg_RequestPayment(IPC::Message::routeid_t routingId);

mozilla::UniquePtr<IPC::Message>
Msg_RespondPayment(IPC::Message::routeid_t routingId);

mozilla::UniquePtr<IPC::Message>
Msg_ChangeShippingAddress(IPC::Message::routeid_t routingId);

mozilla::UniquePtr<IPC::Message>
Msg_ChangeShippingOption(IPC::Message::routeid_t routingId);

mozilla::UniquePtr<IPC::Message>
Msg_ChangePayerDetail(IPC::Message::routeid_t routingId);

mozilla::UniquePtr<IPC::Message>
Msg_ChangePaymentMethod(IPC::Message::routeid_t routingId);



} // namespace PPaymentRequest
} // namespace dom
} // namespace mozilla

#endif // ifndef PPaymentRequest_h
