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

#ifndef ServiceWorkerConfiguration_h
#define ServiceWorkerConfiguration_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 "mozilla/dom/ServiceWorkerRegistrarTypes.h"


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

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

    MOZ_IMPLICIT ServiceWorkerConfiguration(const nsTArray<ServiceWorkerRegistrationData>& _serviceWorkerRegistrations) :
        serviceWorkerRegistrations_(_serviceWorkerRegistrations)
    {
    }

    MOZ_IMPLICIT ServiceWorkerConfiguration(nsTArray<ServiceWorkerRegistrationData>&& _serviceWorkerRegistrations) :
        serviceWorkerRegistrations_(std::move(_serviceWorkerRegistrations))
    {
    }

    nsTArray<ServiceWorkerRegistrationData>&
    serviceWorkerRegistrations()
    {
        return serviceWorkerRegistrations_;
    }
    const nsTArray<ServiceWorkerRegistrationData>&
    serviceWorkerRegistrations() const
    {
        return serviceWorkerRegistrations_;
    }

private:
    ::mozilla::ipc::IPDLStructMember<CopyableTArray<ServiceWorkerRegistrationData>> serviceWorkerRegistrations_;
};
} // namespace dom
} // namespace mozilla

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

#endif // ifndef ServiceWorkerConfiguration_h
