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

#ifndef __gen_calITransactionManager_h__
#define __gen_calITransactionManager_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 nsITransactionManager; /* forward declaration */

class calICalendar; /* forward declaration */

class calIItemBase; /* forward declaration */

class calIOperationListener; /* forward declaration */


/* starting interface:    calITransactionManager */
#define CALITRANSACTIONMANAGER_IID_STR "40a1ccf4-5f54-4815-b842-abf06f84dbfd"

#define CALITRANSACTIONMANAGER_IID \
  {0x40a1ccf4, 0x5f54, 0x4815, \
    { 0xb8, 0x42, 0xab, 0xf0, 0x6f, 0x84, 0xdb, 0xfd }}

class NS_NO_VTABLE calITransactionManager : public nsISupports {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(CALITRANSACTIONMANAGER_IID)

  /* void createAndCommitTxn (in AUTF8String aAction, in calIItemBase aItem, in calICalendar aCalendar, in calIItemBase aOldItem, in calIOperationListener aListener); */
  NS_IMETHOD CreateAndCommitTxn(const nsACString & aAction, calIItemBase *aItem, calICalendar *aCalendar, calIItemBase *aOldItem, calIOperationListener *aListener) = 0;

  /* void beginBatch (); */
  NS_IMETHOD BeginBatch(void) = 0;

  /* void endBatch (); */
  NS_IMETHOD EndBatch(void) = 0;

  /* void undo (); */
  NS_IMETHOD Undo(void) = 0;

  /* boolean canUndo (); */
  NS_IMETHOD CanUndo(bool *_retval) = 0;

  /* void redo (); */
  NS_IMETHOD Redo(void) = 0;

  /* boolean canRedo (); */
  NS_IMETHOD CanRedo(bool *_retval) = 0;

  /* readonly attribute nsITransactionManager transactionManager; */
  NS_IMETHOD GetTransactionManager(nsITransactionManager * *aTransactionManager) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(calITransactionManager, CALITRANSACTIONMANAGER_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_CALITRANSACTIONMANAGER \
  NS_IMETHOD CreateAndCommitTxn(const nsACString & aAction, calIItemBase *aItem, calICalendar *aCalendar, calIItemBase *aOldItem, calIOperationListener *aListener) override; \
  NS_IMETHOD BeginBatch(void) override; \
  NS_IMETHOD EndBatch(void) override; \
  NS_IMETHOD Undo(void) override; \
  NS_IMETHOD CanUndo(bool *_retval) override; \
  NS_IMETHOD Redo(void) override; \
  NS_IMETHOD CanRedo(bool *_retval) override; \
  NS_IMETHOD GetTransactionManager(nsITransactionManager * *aTransactionManager) override; 

/* Use this macro when declaring the members of this interface when the
   class doesn't implement the interface. This is useful for forwarding. */
#define NS_DECL_NON_VIRTUAL_CALITRANSACTIONMANAGER \
  NS_METHOD CreateAndCommitTxn(const nsACString & aAction, calIItemBase *aItem, calICalendar *aCalendar, calIItemBase *aOldItem, calIOperationListener *aListener); \
  NS_METHOD BeginBatch(void); \
  NS_METHOD EndBatch(void); \
  NS_METHOD Undo(void); \
  NS_METHOD CanUndo(bool *_retval); \
  NS_METHOD Redo(void); \
  NS_METHOD CanRedo(bool *_retval); \
  NS_METHOD GetTransactionManager(nsITransactionManager * *aTransactionManager); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_CALITRANSACTIONMANAGER(_to) \
  NS_IMETHOD CreateAndCommitTxn(const nsACString & aAction, calIItemBase *aItem, calICalendar *aCalendar, calIItemBase *aOldItem, calIOperationListener *aListener) override { return _to CreateAndCommitTxn(aAction, aItem, aCalendar, aOldItem, aListener); } \
  NS_IMETHOD BeginBatch(void) override { return _to BeginBatch(); } \
  NS_IMETHOD EndBatch(void) override { return _to EndBatch(); } \
  NS_IMETHOD Undo(void) override { return _to Undo(); } \
  NS_IMETHOD CanUndo(bool *_retval) override { return _to CanUndo(_retval); } \
  NS_IMETHOD Redo(void) override { return _to Redo(); } \
  NS_IMETHOD CanRedo(bool *_retval) override { return _to CanRedo(_retval); } \
  NS_IMETHOD GetTransactionManager(nsITransactionManager * *aTransactionManager) override { return _to GetTransactionManager(aTransactionManager); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_CALITRANSACTIONMANAGER(_to) \
  NS_IMETHOD CreateAndCommitTxn(const nsACString & aAction, calIItemBase *aItem, calICalendar *aCalendar, calIItemBase *aOldItem, calIOperationListener *aListener) override { return !_to ? NS_ERROR_NULL_POINTER : _to->CreateAndCommitTxn(aAction, aItem, aCalendar, aOldItem, aListener); } \
  NS_IMETHOD BeginBatch(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->BeginBatch(); } \
  NS_IMETHOD EndBatch(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->EndBatch(); } \
  NS_IMETHOD Undo(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Undo(); } \
  NS_IMETHOD CanUndo(bool *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->CanUndo(_retval); } \
  NS_IMETHOD Redo(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Redo(); } \
  NS_IMETHOD CanRedo(bool *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->CanRedo(_retval); } \
  NS_IMETHOD GetTransactionManager(nsITransactionManager * *aTransactionManager) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetTransactionManager(aTransactionManager); } 

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

/* Header file */
class _MYCLASS_ : public calITransactionManager
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_CALITRANSACTIONMANAGER

  _MYCLASS_();

private:
  ~_MYCLASS_();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS(_MYCLASS_, calITransactionManager)

_MYCLASS_::_MYCLASS_()
{
  /* member initializers and constructor code */
}

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

/* void createAndCommitTxn (in AUTF8String aAction, in calIItemBase aItem, in calICalendar aCalendar, in calIItemBase aOldItem, in calIOperationListener aListener); */
NS_IMETHODIMP _MYCLASS_::CreateAndCommitTxn(const nsACString & aAction, calIItemBase *aItem, calICalendar *aCalendar, calIItemBase *aOldItem, calIOperationListener *aListener)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void beginBatch (); */
NS_IMETHODIMP _MYCLASS_::BeginBatch()
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void endBatch (); */
NS_IMETHODIMP _MYCLASS_::EndBatch()
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void undo (); */
NS_IMETHODIMP _MYCLASS_::Undo()
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* boolean canUndo (); */
NS_IMETHODIMP _MYCLASS_::CanUndo(bool *_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void redo (); */
NS_IMETHODIMP _MYCLASS_::Redo()
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* boolean canRedo (); */
NS_IMETHODIMP _MYCLASS_::CanRedo(bool *_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute nsITransactionManager transactionManager; */
NS_IMETHODIMP _MYCLASS_::GetTransactionManager(nsITransactionManager * *aTransactionManager)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

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


#endif /* __gen_calITransactionManager_h__ */
