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

#ifndef PRemoteSpellcheckEngineChild_h
#define PRemoteSpellcheckEngineChild_h

#include "mozilla/PRemoteSpellcheckEngine.h"
#ifdef DEBUG
#include "prenv.h"
#endif // DEBUG
#include "base/id_map.h"
#include "mozilla/ipc/MessageChannel.h"

namespace mozilla {
namespace dom {
class PContentChild;
} // namespace dom
} // namespace mozilla
namespace mozilla {
namespace dom {
class PContentParent;
} // namespace dom
} // namespace mozilla

namespace mozilla {
namespace dom {
class PContentChild;
} // namespace dom
} // namespace mozilla

namespace mozilla {


class PRemoteSpellcheckEngineChild :
    public mozilla::ipc::IProtocol
{
    friend class mozilla::dom::PContentChild;

protected:
    typedef mozilla::ipc::ActorHandle ActorHandle;
    template<class FooSide> using Endpoint = mozilla::ipc::Endpoint<FooSide>;
    typedef mozilla::ipc::FileDescriptor FileDescriptor;
    typedef base::ProcessId ProcessId;
    typedef mozilla::ipc::ProtocolId ProtocolId;
    typedef mozilla::ipc::Shmem Shmem;
    typedef mozilla::ipc::Transport Transport;
    typedef mozilla::ipc::TransportDescriptor TransportDescriptor;
    typedef mozilla::dom::PContentChild PContentChild;
    typedef mozilla::dom::PContentParent PContentParent;

    typedef PRemoteSpellcheckEngine::State State;


    virtual void
    ActorDestroy(ActorDestroyReason aWhy);

public:
    typedef mozilla::ipc::IProtocol ProtocolBase;
    typedef IPC::Message Message;
    typedef mozilla::ipc::MessageChannel Channel;
    typedef mozilla::ipc::IProtocol ChannelListener;
    typedef base::ProcessHandle ProcessHandle;
    typedef mozilla::ipc::MessageChannel MessageChannel;
    typedef mozilla::ipc::SharedMemory SharedMemory;
    typedef mozilla::ipc::Trigger Trigger;

public:
    MOZ_IMPLICIT PRemoteSpellcheckEngineChild();

    virtual ~PRemoteSpellcheckEngineChild();

    PContentChild*
    Manager() const;

    PRemoteSpellcheckEngine::State
    state();

    static bool
    Send__delete__(PRemoteSpellcheckEngineChild* actor);

    bool
    SendCheck(
            const nsString& aWord,
            bool* aIsMisspelled);

    bool
    SendCheckAndSuggest(
            const nsString& aWord,
            bool* aIsMisspelled,
            nsTArray<nsString>* aSuggestions);

    bool
    SendSetDictionary(
            const nsString& aDictionary,
            bool* success);

    virtual void
    RemoveManagee(
            int32_t aProtocolId,
            ProtocolBase* aListener);

    virtual Result
    OnMessageReceived(const Message& msg__);

    virtual Result
    OnMessageReceived(
            const Message& msg__,
            Message*& reply__);

    virtual Result
    OnCallReceived(
            const Message& msg__,
            Message*& reply__);

    int32_t
    GetProtocolTypeId();

private:
    virtual const char*
    ProtocolName() const;

    void
    DestroySubtree(ActorDestroyReason why);

    void
    DeallocSubtree();

    template<typename T>
    void
    Write(
            const T& v__,
            Message* msg__)
    {
        IPC::WriteParam(msg__, v__);
    }

    template<typename T>
    bool
    Read(
            T* v__,
            const Message* msg__,
            PickleIterator* iter__)
    {
        return IPC::ReadParam(msg__, iter__, v__);
    }

    void
    Write(
            const PRemoteSpellcheckEngineChild* v__,
            Message* msg__,
            bool nullable__);

    MOZ_MUST_USE bool
    Read(
            PRemoteSpellcheckEngineChild** v__,
            const Message* msg__,
            PickleIterator* iter__,
            bool nullable__);

    State mState;
};


} // namespace mozilla

#if 0

//-----------------------------------------------------------------------------
// Skeleton implementation of abstract actor class

// Header file contents
namespace mozilla {
class RemoteSpellcheckEngineChild :
    public PRemoteSpellcheckEngineChild
{
    MOZ_IMPLICIT RemoteSpellcheckEngineChild();
    virtual ~RemoteSpellcheckEngineChild();
};
} // namespace mozilla


// C++ file contents
namespace mozilla {
MOZ_IMPLICIT RemoteSpellcheckEngineChild::RemoteSpellcheckEngineChild()
{
    MOZ_COUNT_CTOR(RemoteSpellcheckEngineChild);
}

MOZ_IMPLICIT RemoteSpellcheckEngineChild::~RemoteSpellcheckEngineChild()
{
    MOZ_COUNT_DTOR(RemoteSpellcheckEngineChild);
}

} // namespace mozilla
#endif // if 0

#endif // ifndef PRemoteSpellcheckEngineChild_h
