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

#ifndef MOMSatelliteManager_h
#define MOMSatelliteManager_h

#if ENABLE(RMAI)

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

#include "ExceptionCode.h"
#include "MOMContentList.h"

namespace WebCore {

class MOMSatellite;
class MOMContentItem;
class ScriptExecutionContext;

class MOMSatelliteManager : public RefCounted<MOMSatelliteManager> {
public:

    static PassRefPtr<MOMSatelliteManager> create(ScriptExecutionContext* context);

    MOMContentList* satellites() const;
    MOMContentList* enabledSatellites() const;

    PassRefPtr<MOMSatellite> createSatellite( const String & name, ExceptionCode& ec );
    void remove( MOMSatellite* satellite );

protected:
    MOMSatelliteManager(ScriptExecutionContext* context);

private:
    ScriptExecutionContext* m_context;
    mutable RefPtr<MOMContentList> m_satellites;
    mutable RefPtr<MOMContentList> m_enabledSatellites;
};

} // namespace WebCore

#endif // ENABLE(RMAI)

#endif // MOMSatelliteManager_h
