/*
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM /builds/slave/mozilla-central-linux64-xulrunner/build/dom/indexedDB/nsIIDBDatabaseRequest.idl
 */

#ifndef __gen_nsIIDBDatabaseRequest_h__
#define __gen_nsIIDBDatabaseRequest_h__


#ifndef __gen_nsIIDBDatabase_h__
#include "nsIIDBDatabase.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 nsIIDBObjectStoreRequest; /* forward declaration */

class nsIIDBRequest; /* forward declaration */

class nsIIDBTransactionRequest; /* forward declaration */


/* starting interface:    nsIIDBDatabaseRequest */
#define NS_IIDBDATABASEREQUEST_IID_STR "8f475c0a-e332-41ba-ba27-156370a63486"

#define NS_IIDBDATABASEREQUEST_IID \
  {0x8f475c0a, 0xe332, 0x41ba, \
    { 0xba, 0x27, 0x15, 0x63, 0x70, 0xa6, 0x34, 0x86 }}

/**
 * IDBDatabaseRequest interface.  See
 * http://dev.w3.org/2006/webapi/WebSimpleDB/#idl-def-IDBDatabaseRequest for
 * more information.
 */
class NS_NO_VTABLE NS_SCRIPTABLE nsIIDBDatabaseRequest : public nsIIDBDatabase {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IIDBDATABASEREQUEST_IID)

  /* 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] nsIIDBTransactionRequest 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, nsIIDBTransactionRequest **_retval NS_OUTPARAM) = 0;

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

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIIDBDatabaseRequest, NS_IIDBDATABASEREQUEST_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIIDBDATABASEREQUEST \
  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, nsIIDBTransactionRequest **_retval NS_OUTPARAM); \
  NS_SCRIPTABLE NS_IMETHOD ObjectStore(const nsAString & name, PRUint16 mode, PRUint8 _argc, nsIIDBObjectStoreRequest **_retval NS_OUTPARAM); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIIDBDATABASEREQUEST(_to) \
  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, nsIIDBTransactionRequest **_retval NS_OUTPARAM) { return _to Transaction(storeNames, mode, timeout, _argc, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD ObjectStore(const nsAString & name, PRUint16 mode, PRUint8 _argc, nsIIDBObjectStoreRequest **_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_NSIIDBDATABASEREQUEST(_to) \
  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, nsIIDBTransactionRequest **_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, nsIIDBObjectStoreRequest **_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 nsIDBDatabaseRequest : public nsIIDBDatabaseRequest
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSIIDBDATABASEREQUEST

  nsIDBDatabaseRequest();

private:
  ~nsIDBDatabaseRequest();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(nsIDBDatabaseRequest, nsIIDBDatabaseRequest)

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

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

/* nsIIDBRequest createObjectStore (in AString name, in AString keyPath, [optional] in boolean autoIncrement); */
NS_IMETHODIMP nsIDBDatabaseRequest::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 nsIDBDatabaseRequest::RemoveObjectStore(const nsAString & name, nsIIDBRequest **_retval NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

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

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

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

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


#endif /* __gen_nsIIDBDatabaseRequest_h__ */
