/*
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM nsIEditorController.idl
 */

#ifndef __gen_nsIEditorController_h__
#define __gen_nsIEditorController_h__


#ifndef __gen_nsISupports_h__
#include "nsISupports.h"
#endif

/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
class nsIEditor;
class nsCString;

/* starting interface:    nsIEditorController */
#define NS_IEDITORCONTROLLER_IID_STR "d937f1c2-6fab-11d4-b37d-004095e27a10"

#define NS_IEDITORCONTROLLER_IID \
  {0xd937f1c2, 0x6fab, 0x11d4, \
    { 0xb3, 0x7d, 0x00, 0x40, 0x95, 0xe2, 0x7a, 0x10 }}

class NS_NO_VTABLE nsIEditorController : public nsISupports {
 public: 

  NS_DEFINE_STATIC_IID_ACCESSOR(NS_IEDITORCONTROLLER_IID)

  /** init the controller
   *  param: commandRefCon = a cookie that is passed to commands
   */
  /* void Init (in nsISupports commandRefCon); */
  NS_IMETHOD Init(nsISupports *commandRefCon) = 0;

  /** Set the cookie that is passed to commands
   */
  /* void SetCommandRefCon (in nsISupports commandRefCon); */
  NS_IMETHOD SetCommandRefCon(nsISupports *commandRefCon) = 0;

  /** Execute the command identified by the ID string
   *  param: commandName  ID string of the command
   */
  /* void DoCommand (in DOMString commandName); */
  NS_IMETHOD DoCommand(const nsAString & commandName) = 0;

};

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIEDITORCONTROLLER \
  NS_IMETHOD Init(nsISupports *commandRefCon); \
  NS_IMETHOD SetCommandRefCon(nsISupports *commandRefCon); \
  NS_IMETHOD DoCommand(const nsAString & commandName); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIEDITORCONTROLLER(_to) \
  NS_IMETHOD Init(nsISupports *commandRefCon) { return _to Init(commandRefCon); } \
  NS_IMETHOD SetCommandRefCon(nsISupports *commandRefCon) { return _to SetCommandRefCon(commandRefCon); } \
  NS_IMETHOD DoCommand(const nsAString & commandName) { return _to DoCommand(commandName); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIEDITORCONTROLLER(_to) \
  NS_IMETHOD Init(nsISupports *commandRefCon) { return !_to ? NS_ERROR_NULL_POINTER : _to->Init(commandRefCon); } \
  NS_IMETHOD SetCommandRefCon(nsISupports *commandRefCon) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetCommandRefCon(commandRefCon); } \
  NS_IMETHOD DoCommand(const nsAString & commandName) { return !_to ? NS_ERROR_NULL_POINTER : _to->DoCommand(commandName); } 

#if 0
/* Use the code below as a template for the implementation class for this interface. */

/* Header file */
class nsEditorController : public nsIEditorController
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSIEDITORCONTROLLER

  nsEditorController();
  virtual ~nsEditorController();
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(nsEditorController, nsIEditorController)

nsEditorController::nsEditorController()
{
  NS_INIT_ISUPPORTS();
  /* member initializers and constructor code */
}

nsEditorController::~nsEditorController()
{
  /* destructor code */
}

/* void Init (in nsISupports commandRefCon); */
NS_IMETHODIMP nsEditorController::Init(nsISupports *commandRefCon)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void SetCommandRefCon (in nsISupports commandRefCon); */
NS_IMETHODIMP nsEditorController::SetCommandRefCon(nsISupports *commandRefCon)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void DoCommand (in DOMString commandName); */
NS_IMETHODIMP nsEditorController::DoCommand(const nsAString & commandName)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* End of implementation class template. */
#endif


#endif /* __gen_nsIEditorController_h__ */
