/** @file MOMGuideSearchEvent.h
 *
 * Copyright (C) Espial Limited 2014 - Company confidential - All rights reserved.
 *
 */

#ifndef MOMGuideSearchEvent_h
#define MOMGuideSearchEvent_h

#if ENABLE(RMAI)

#include <wtf/PassRefPtr.h>
#include <wtf/RefCounted.h>
#include <wtf/text/AtomicString.h>

#include "MOMEvent.h"

namespace WebCore {

class MOMContentItem;

class MOMGuideSearchEvent : public MOMEvent {
public:
    enum {
        COMPLETE = 0,
        DATA_AVAILABLE = 1,
        INVALIDATED = 2,
        DESCRIPTION_FETCHED = 3,
    };
    static PassRefPtr<MOMGuideSearchEvent> create()
    {
        return adoptRef(new MOMGuideSearchEvent);
    }
    
    int state() const { return getIntParam(mom_event_GUIDESEARCH_TYPE); }
    MOMContentItem* programme() const { return m_object.get(); }

    MOMGuideSearchEvent(const mom_event_params* params, ScriptExecutionContext* context);
private:
    mutable RefPtr<MOMContentItem> m_object;
    MOMGuideSearchEvent();
};

} // namespace WebCore

#endif // ENABLE(RMAI)

#endif // MOMGuideSearchEvent_h
