|
1 /* -*- Mode: IDL; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ |
|
2 /* This Source Code Form is subject to the terms of the Mozilla Public |
|
3 * License, v. 2.0. If a copy of the MPL was not distributed with this |
|
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
|
5 |
|
6 #include "nsISupports.idl" |
|
7 |
|
8 [ptr] native const_nsID_ptr(const nsID); |
|
9 |
|
10 [builtinclass, scriptable, uuid(62883d14-4146-4039-94f5-a5e1e1a51a15)] |
|
11 interface nsIJSID : nsISupports |
|
12 { |
|
13 readonly attribute string name; |
|
14 readonly attribute string number; |
|
15 readonly attribute boolean valid; |
|
16 |
|
17 boolean equals(in nsIJSID other); |
|
18 string toString(); |
|
19 |
|
20 [noscript] void initialize(in string idString); |
|
21 |
|
22 // returns a pointer to the internal nsID. this pointer is only valid |
|
23 // while the nsIJSID object remains alive! |
|
24 [notxpcom] const_nsID_ptr getID(); |
|
25 }; |
|
26 |
|
27 [builtinclass, scriptable, uuid(e76ec564-a080-4705-8609-384c755ec91e)] |
|
28 interface nsIJSIID : nsIJSID |
|
29 { |
|
30 }; |
|
31 |
|
32 [builtinclass, scriptable, uuid(bf5eb086-9eaa-4694-aec3-fe4aac6119bd)] |
|
33 interface nsIJSCID : nsIJSID |
|
34 { |
|
35 [implicit_jscontext,optional_argc] jsval createInstance([optional] in jsval iid); |
|
36 [implicit_jscontext,optional_argc] jsval getService([optional] in jsval iid); |
|
37 }; |
|
38 |
|
39 /* this goes into the C++ header verbatim. */ |
|
40 %{ C++ |
|
41 /********************************************************/ |
|
42 // {F24A14F0-4FA1-11d3-9894-006008962422} |
|
43 #define NS_JS_ID_CID \ |
|
44 { 0xf24a14f0, 0x4fa1, 0x11d3, \ |
|
45 { 0x98, 0x94, 0x0, 0x60, 0x8, 0x96, 0x24, 0x22 } } |
|
46 %} |
|
47 |