2001-09-25 22:43:09 +00:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2012-05-21 11:12:37 +00:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
1998-09-04 23:03:16 +00:00
|
|
|
|
|
|
|
#ifndef nsIDOMScriptObjectFactory_h__
|
|
|
|
#define nsIDOMScriptObjectFactory_h__
|
|
|
|
|
|
|
|
#include "nsISupports.h"
|
Landing the XPCDOM_20010329_BRANCH branch, changes mostly done by jband@netscape.com and jst@netscape.com, also some changes done by shaver@mozilla.org, peterv@netscape.com and markh@activestate.com. r= and sr= by vidur@netscape.com, jband@netscape.com, jst@netscpae.com, danm@netscape.com, hyatt@netscape.com, shaver@mozilla.org, dbradley@netscape.com, rpotts@netscape.com.
2001-05-08 17:42:36 +00:00
|
|
|
#include "nsIDOMClassInfo.h"
|
2013-09-23 17:25:00 +00:00
|
|
|
#include "nsString.h"
|
1998-09-04 23:03:16 +00:00
|
|
|
|
2012-04-14 13:03:16 +00:00
|
|
|
#define NS_IDOM_SCRIPT_OBJECT_FACTORY_IID \
|
|
|
|
{ 0x2a50e17c, 0x46ff, 0x4150, \
|
|
|
|
{ 0xbb, 0x46, 0xd8, 0x07, 0xb3, 0x36, 0xde, 0xab } }
|
1998-09-04 23:03:16 +00:00
|
|
|
|
|
|
|
class nsIScriptContext;
|
Landing the XPCDOM_20010329_BRANCH branch, changes mostly done by jband@netscape.com and jst@netscape.com, also some changes done by shaver@mozilla.org, peterv@netscape.com and markh@activestate.com. r= and sr= by vidur@netscape.com, jband@netscape.com, jst@netscpae.com, danm@netscape.com, hyatt@netscape.com, shaver@mozilla.org, dbradley@netscape.com, rpotts@netscape.com.
2001-05-08 17:42:36 +00:00
|
|
|
class nsIScriptGlobalObject;
|
|
|
|
class nsIDOMEventListener;
|
1998-09-04 23:03:16 +00:00
|
|
|
|
2009-09-28 21:00:35 +00:00
|
|
|
typedef nsXPCClassInfo* (*nsDOMClassInfoExternalConstructorFnc)
|
2009-02-17 14:08:08 +00:00
|
|
|
(const char* aName);
|
|
|
|
|
1998-09-04 23:03:16 +00:00
|
|
|
class nsIDOMScriptObjectFactory : public nsISupports {
|
|
|
|
public:
|
2005-11-11 14:36:26 +00:00
|
|
|
NS_DECLARE_STATIC_IID_ACCESSOR(NS_IDOM_SCRIPT_OBJECT_FACTORY_IID)
|
1998-09-04 23:03:16 +00:00
|
|
|
|
2007-03-20 15:56:43 +00:00
|
|
|
NS_IMETHOD_(nsISupports *) GetClassInfoInstance(nsDOMClassInfoID aID) = 0;
|
|
|
|
NS_IMETHOD_(nsISupports *) GetExternalClassInfoInstance(const nsAString& aName) = 0;
|
2002-03-04 02:25:08 +00:00
|
|
|
|
|
|
|
// Register the info for an external class. aName must be static
|
|
|
|
// data, it will not be deleted by the DOM code. aProtoChainInterface
|
|
|
|
// must be registered in the JAVASCRIPT_DOM_INTERFACE category, or
|
|
|
|
// prototypes for this class won't work (except if the interface
|
|
|
|
// name starts with nsIDOM).
|
|
|
|
NS_IMETHOD RegisterDOMClassInfo(const char *aName,
|
|
|
|
nsDOMClassInfoExternalConstructorFnc aConstructorFptr,
|
|
|
|
const nsIID *aProtoChainInterface,
|
|
|
|
const nsIID **aInterfaces,
|
2012-08-22 15:56:38 +00:00
|
|
|
uint32_t aScriptableFlags,
|
2011-09-29 06:19:26 +00:00
|
|
|
bool aHasClassInterface,
|
2002-03-04 02:25:08 +00:00
|
|
|
const nsCID *aConstructorCID) = 0;
|
1998-09-04 23:03:16 +00:00
|
|
|
};
|
|
|
|
|
2005-11-11 14:36:26 +00:00
|
|
|
NS_DEFINE_STATIC_IID_ACCESSOR(nsIDOMScriptObjectFactory,
|
|
|
|
NS_IDOM_SCRIPT_OBJECT_FACTORY_IID)
|
|
|
|
|
1998-09-04 23:03:16 +00:00
|
|
|
#endif /* nsIDOMScriptObjectFactory_h__ */
|