/*
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM e:/builds/moz2_slave/mozilla-central-win32-xulrunner/build/dom/indexedDB/nsIIDBDatabase.idl
 */

#ifndef __gen_nsIIDBDatabase_h__
#define __gen_nsIIDBDatabase_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 nsIVariant; /* forward declaration */

class nsIIDBObjectStore; /* forward declaration */

class nsIIDBRequest; /* forward declaration */

class nsIIDBTransaction; /* forward declaration */

class nsIDOMDOMStringList; /* forward declaration */


/* starting interface:    nsIIDBDatabase */
#define NS_IIDBDATABASE_IID_STR "e258ad44-3306-427f-ac17-c528060c661a"

#define NS_IIDBDATABASE_IID \
  {0xe258ad44, 0x3306, 0x427f, \
    { 0xac, 0x17, 0xc5, 0x28, 0x06, 0x0c, 0x66, 0x1a }}

/**
 * IDBDatabase interface.  See
 * http://dvcs.w3.org/hg/IndexedDB/raw-file/tip/Overview.html#idl-def-IDBDatabase
 * for more information.
 */
class NS_NO_VTABLE NS_SCRIPTABLE nsIIDBDatabase : public nsISupports {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IIDBDATABASE_IID)

  /* readonly attribute DOMString name; */
  NS_SCRIPTABLE NS_IMETHOD GetName(nsAString & aName) = 0;

  /* readonly attribute DOMString description; */
  NS_SCRIPTABLE NS_IMETHOD GetDescription(nsAString & aDescription) = 0;

  /* readonly attribute DOMString version; */
  NS_SCRIPTABLE NS_IMETHOD GetVersion(nsAString & aVersion) = 0;

  /* readonly attribute nsIDOMDOMStringList objectStoreNames; */
  NS_SCRIPTABLE NS_IMETHOD GetObjectStoreNames(nsIDOMDOMStringList **aObjectStoreNames) = 0;

  /* nsIIDBRequest createObjectStore (in AString name, in AString keyPath, [optional] in boolean autoIncrement); */
  NS_SCRIPTABLE NS_IMETHOD CreateObjectStore(const nsAString & name, const nsAString & keyPath, PRBool autoIncrement, nsIIDBRequest **_retval NS_OUTPARAM) = 0;

  /* nsIIDBRequest removeObjectStore (in AString name); */
  NS_SCRIPTABLE NS_IMETHOD RemoveObjectStore(const nsAString & name, nsIIDBRequest **_retval NS_OUTPARAM) = 0;

  /* nsIIDBRequest setVersion (in AString version); */
  NS_SCRIPTABLE NS_IMETHOD SetVersion(const nsAString & version, nsIIDBRequest **_retval NS_OUTPARAM) = 0;

  /* [optional_argc] nsIIDBTransaction transaction (in nsIVariant storeNames, [optional] in unsigned short mode, [optional] in unsigned long timeout); */
  NS_SCRIPTABLE NS_IMETHOD Transaction(nsIVariant *storeNames, PRUint16 mode, PRUint32 timeout, PRUint8 _argc, nsIIDBTransaction **_retval NS_OUTPARAM) = 0;

  /* [optional_argc] nsIIDBObjectStore objectStore (in AString name, [optional] in unsigned short mode); */
  NS_SCRIPTABLE NS_IMETHOD ObjectStore(const nsAString & name, PRUint16 mode, PRUint8 _argc, nsIIDBObjectStore **_retval NS_OUTPARAM) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIIDBDatabase, NS_IIDBDATABASE_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIIDBDATABASE \
  NS_SCRIPTABLE NS_IMETHOD GetName(nsAString & aName); \
  NS_SCRIPTABLE NS_IMETHOD GetDescription(nsAString & aDescription); \
  NS_SCRIPTABLE NS_IMETHOD GetVersion(nsAString & aVersion); \
  NS_SCRIPTABLE NS_IMETHOD GetObjectStoreNames(nsIDOMDOMStringList **aObjectStoreNames); \
  NS_SCRIPTABLE NS_IMETHOD CreateObjectStore(const nsAString & name, const nsAString & keyPath, PRBool autoIncrement, nsIIDBRequest **_retval NS_OUTPARAM); \
  NS_SCRIPTABLE NS_IMETHOD RemoveObjectStore(const nsAString & name, nsIIDBRequest **_retval NS_OUTPARAM); \
  NS_SCRIPTABLE NS_IMETHOD SetVersion(const nsAString & version, nsIIDBRequest **_retval NS_OUTPARAM); \
  NS_SCRIPTABLE NS_IMETHOD Transaction(nsIVariant *storeNames, PRUint16 mode, PRUint32 timeout, PRUint8 _argc, nsIIDBTransaction **_retval NS_OUTPARAM); \
  NS_SCRIPTABLE NS_IMETHOD ObjectStore(const nsAString & name, PRUint16 mode, PRUint8 _argc, nsIIDBObjectStore **_retval NS_OUTPARAM); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIIDBDATABASE(_to) \
  NS_SCRIPTABLE NS_IMETHOD GetName(nsAString & aName) { return _to GetName(aName); } \
  NS_SCRIPTABLE NS_IMETHOD GetDescription(nsAString & aDescription) { return _to GetDescription(aDescription); } \
  NS_SCRIPTABLE NS_IMETHOD GetVersion(nsAString & aVersion) { return _to GetVersion(aVersion); } \
  NS_SCRIPTABLE NS_IMETHOD GetObjectStoreNames(nsIDOMDOMStringList **aObjectStoreNames) { return _to GetObjectStoreNames(aObjectStoreNames); } \
  NS_SCRIPTABLE NS_IMETHOD CreateObjectStore(const nsAString & name, const nsAString & keyPath, PRBool autoIncrement, nsIIDBRequest **_retval NS_OUTPARAM) { return _to CreateObjectStore(name, keyPath, autoIncrement, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD RemoveObjectStore(const nsAString & name, nsIIDBRequest **_retval NS_OUTPARAM) { return _to RemoveObjectStore(name, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD SetVersion(const nsAString & version, nsIIDBRequest **_retval NS_OUTPARAM) { return _to SetVersion(version, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD Transaction(nsIVariant *storeNames, PRUint16 mode, PRUint32 timeout, PRUint8 _argc, nsIIDBTransaction **_retval NS_OUTPARAM) { return _to Transaction(storeNames, mode, timeout, _argc, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD ObjectStore(const nsAString & name, PRUint16 mode, PRUint8 _argc, nsIIDBObjectStore **_retval NS_OUTPARAM) { return _to ObjectStore(name, mode, _argc, _retval); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIIDBDATABASE(_to) \
  NS_SCRIPTABLE NS_IMETHOD GetName(nsAString & aName) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetName(aName); } \
  NS_SCRIPTABLE NS_IMETHOD GetDescription(nsAString & aDescription) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDescription(aDescription); } \
  NS_SCRIPTABLE NS_IMETHOD GetVersion(nsAString & aVersion) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetVersion(aVersion); } \
  NS_SCRIPTABLE NS_IMETHOD GetObjectStoreNames(nsIDOMDOMStringList **aObjectStoreNames) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetObjectStoreNames(aObjectStoreNames); } \
  NS_SCRIPTABLE NS_IMETHOD CreateObjectStore(const nsAString & name, const nsAString & keyPath, PRBool autoIncrement, nsIIDBRequest **_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->CreateObjectStore(name, keyPath, autoIncrement, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD RemoveObjectStore(const nsAString & name, nsIIDBRequest **_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->RemoveObjectStore(name, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD SetVersion(const nsAString & version, nsIIDBRequest **_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetVersion(version, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD Transaction(nsIVariant *storeNames, PRUint16 mode, PRUint32 timeout, PRUint8 _argc, nsIIDBTransaction **_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->Transaction(storeNames, mode, timeout, _argc, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD ObjectStore(const nsAString & name, PRUint16 mode, PRUint8 _argc, nsIIDBObjectStore **_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->ObjectStore(name, mode, _argc, _retval); } 

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

/* Header file */
class nsIDBDatabase : public nsIIDBDatabase
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSIIDBDATABASE

  nsIDBDatabase();

private:
  ~nsIDBDatabase();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(nsIDBDatabase, nsIIDBDatabase)

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

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

/* readonly attribute DOMString name; */
NS_IMETHODIMP nsIDBDatabase::GetName(nsAString & aName)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute DOMString description; */
NS_IMETHODIMP nsIDBDatabase::GetDescription(nsAString & aDescription)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute DOMString version; */
NS_IMETHODIMP nsIDBDatabase::GetVersion(nsAString & aVersion)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute nsIDOMDOMStringList objectStoreNames; */
NS_IMETHODIMP nsIDBDatabase::GetObjectStoreNames(nsIDOMDOMStringList **aObjectStoreNames)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* nsIIDBRequest createObjectStore (in AString name, in AString keyPath, [optional] in boolean autoIncrement); */
NS_IMETHODIMP nsIDBDatabase::CreateObjectStore(const nsAString & name, const nsAString & keyPath, PRBool autoIncrement, nsIIDBRequest **_retval NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* nsIIDBRequest removeObjectStore (in AString name); */
NS_IMETHODIMP nsIDBDatabase::RemoveObjectStore(const nsAString & name, nsIIDBRequest **_retval NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* nsIIDBRequest setVersion (in AString version); */
NS_IMETHODIMP nsIDBDatabase::SetVersion(const nsAString & version, nsIIDBRequest **_retval NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [optional_argc] nsIIDBTransaction transaction (in nsIVariant storeNames, [optional] in unsigned short mode, [optional] in unsigned long timeout); */
NS_IMETHODIMP nsIDBDatabase::Transaction(nsIVariant *storeNames, PRUint16 mode, PRUint32 timeout, PRUint8 _argc, nsIIDBTransaction **_retval NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [optional_argc] nsIIDBObjectStore objectStore (in AString name, [optional] in unsigned short mode); */
NS_IMETHODIMP nsIDBDatabase::ObjectStore(const nsAString & name, PRUint16 mode, PRUint8 _argc, nsIIDBObjectStore **_retval NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

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


#endif /* __gen_nsIIDBDatabase_h__ */
