/* Network-Integrated Multimedia Middleware (NMM)
 * http://www.motama.com/nmm.html
 *
 * Copyright (C) 2006-2007
 * Motama GmbH, Saarbruecken, Germany
 * http://www.motama.com
 *
 * This file is part of NMM. 
 * 
 * NMM is free software; you can redistribute it and/or modify it    
 * under the terms of the GNU General Public License as published by 
 * the Free Software Foundation; only version 2 of the License.      
 * 
 * NMM is distributed in the hope that it will be useful, but WITHOUT 
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 
 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public 
 * License for more details.  
 * 
 * You should have received a copy of the GNU General Public License 
 * along with NMM; if not, write to the Free Software Foundation,    
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 *
 */

#ifndef NMM_IEPG_HPP
#define NMM_IEPG_HPP

#include "nmm/nmm_prefix.hpp"

#include "nmm/comm/Interface.hpp"
#include "nmm/comm/messaging/Event.hpp"
#include "nmm/comm/messaging/IllegalStateException.hpp"
#include <memory>

#include "nmm/multimedia/INode.hpp"

#include "visibility.hpp"

namespace NMM
{
  /**
   * Interface for an Electronic Programming Guide
   * to provide additional information to the program shown
   */

  class DLLEXPORT IEPG : virtual public NMM::Interface { 
  public:
    IEPG() : NMM::Interface(IEPG::IEPG_type, "NMM") { };

    IEPG(NMM::NMMObject& parent) : NMM::Interface (parent, IEPG::IEPG_type, "NMM") { };

    virtual ~IEPG() {};

    static const char* IEPG_type;

    virtual  string getInterfaceType() const { return IEPG_type; }

    NMM::Interface* copy() const { return new IEPG(*this); }
    static void used(); 
    static const char* getCurrentShow_event;
    static const char* getFollowingShow_event;
    static const char* getDetailedDescription_event;
    static const char* setEPGDirectory_event;
    static const char* getActivity_event;
    static const char* scan_event;
    /**
     * returns a string wich contains the starttime, 
     * endtime and title of the current show
     * Format: hh:mm - hh:mm : title
     */

    virtual string getCurrentShow() /* limited(INode::INITIALIZED) */ /* limited(INode::ACTIVATED) */ /* limited(INode::STARTED) */ /* limited(INode::OUTPUT_INITIALIZED) */
      throw(const NMM::SerializedException&, const NMM::IllegalStateException&);
    /**
     * returns a string wich contains the starttime, 
     * endtime and title of the following show
     * Format: hh:mm - hh:mm : title
     */

    virtual string getFollowingShow() /* limited(INode::INITIALIZED) */ /* limited(INode::ACTIVATED) */ /* limited(INode::STARTED) */ /* limited(INode::OUTPUT_INITIALIZED) */
      throw(const NMM::SerializedException&, const NMM::IllegalStateException&);
    /**
     * returns a string containing a detailed description
     * of the curretn show
     */

    virtual string getDetailedDescription() /* limited(INode::INITIALIZED) */ /* limited(INode::ACTIVATED) */ /* limited(INode::STARTED) */ /* limited(INode::OUTPUT_INITIALIZED) */
      throw(const NMM::SerializedException&, const NMM::IllegalStateException&);
    /**
     * sets the Directory, where the XML-file with EPG-information is stored
     */

    virtual void setEPGDirectory(const string& dir)
      throw(const NMM::SerializedException&);
    /**
     * restores the channel before starting the scanning-function
     */

    virtual void getActivity() /* limited(INode::INITIALIZED) */ /* limited(INode::ACTIVATED) */ /* limited(INode::STARTED) */ /* limited(INode::OUTPUT_INITIALIZED) */
      throw(const NMM::SerializedException&, const NMM::IllegalStateException&);
    /**
     * starts the scanning-function of VDR to collect EPG-data
     */

    virtual void scan() /* limited(INode::INITIALIZED) */ /* limited(INode::ACTIVATED) */ /* limited(INode::STARTED) */ /* limited(INode::OUTPUT_INITIALIZED) */
      throw(const NMM::SerializedException&, const NMM::IllegalStateException&);


  };

  typedef auto_ptr<IEPG> IEPG_var;




}

#include "nmm/nmm_suffix.hpp"

#endif
