Coverage Report

Created: 2018-09-25 14:53

/work/obj-fuzz/dist/include/mozilla/dom/HTMLElementBinding.h
Line
Count
Source (jump to first uncovered line)
1
/* THIS FILE IS AUTOGENERATED FROM HTMLElement.webidl BY Codegen.py - DO NOT EDIT */
2
3
#ifndef mozilla_dom_HTMLElementBinding_h
4
#define mozilla_dom_HTMLElementBinding_h
5
6
#include "GeckoProfiler.h"
7
#include "js/RootingAPI.h"
8
#include "jspubtd.h"
9
#include "mozilla/ErrorResult.h"
10
#include "mozilla/dom/BindingDeclarations.h"
11
#include "mozilla/dom/Nullable.h"
12
#include "mozilla/dom/PrototypeList.h"
13
14
class nsGenericHTMLElement;
15
struct nsGenericHTMLElementAtoms;
16
17
namespace mozilla {
18
namespace dom {
19
20
class HTMLUnknownElement;
21
struct HTMLUnknownElementAtoms;
22
struct NativePropertyHooks;
23
class ProtoAndIfaceCache;
24
25
} // namespace dom
26
} // namespace mozilla
27
28
namespace mozilla {
29
namespace dom {
30
31
namespace HTMLElement_Binding {
32
33
  typedef nsGenericHTMLElement NativeType;
34
35
  const JSClass*
36
  GetJSClass();
37
38
  bool
39
  Wrap(JSContext* aCx, nsGenericHTMLElement* aObject, nsWrapperCache* aCache, JS::Handle<JSObject*> aGivenProto, JS::MutableHandle<JSObject*> aReflector);
40
41
  template <class T>
42
  inline JSObject* Wrap(JSContext* aCx, T* aObject, JS::Handle<JSObject*> aGivenProto)
43
0
  {
44
0
    JS::Rooted<JSObject*> reflector(aCx);
45
0
    return Wrap(aCx, aObject, aObject, aGivenProto, &reflector) ? reflector.get() : nullptr;
46
0
  }
Unexecuted instantiation: JSObject* mozilla::dom::HTMLElement_Binding::Wrap<mozilla::dom::GeneratedImageContent>(JSContext*, mozilla::dom::GeneratedImageContent*, JS::Handle<JSObject*>)
Unexecuted instantiation: JSObject* mozilla::dom::HTMLElement_Binding::Wrap<mozilla::dom::HTMLElement>(JSContext*, mozilla::dom::HTMLElement*, JS::Handle<JSObject*>)
Unexecuted instantiation: JSObject* mozilla::dom::HTMLElement_Binding::Wrap<mozilla::dom::HTMLSummaryElement>(JSContext*, mozilla::dom::HTMLSummaryElement*, JS::Handle<JSObject*>)
47
48
  // We declare this as an array so that retrieving a pointer to this
49
  // binding's property hooks only requires compile/link-time resolvable
50
  // address arithmetic.  Declaring it as a pointer instead would require
51
  // doing a run-time load to fetch a pointer to this binding's property
52
  // hooks.  And then structures which embedded a pointer to this structure
53
  // would require a run-time load for proper initialization, which would
54
  // then induce static constructors.  Lots of static constructors.
55
  extern const NativePropertyHooks sNativePropertyHooks[];
56
57
  void
58
  CreateInterfaceObjects(JSContext* aCx, JS::Handle<JSObject*> aGlobal, ProtoAndIfaceCache& aProtoAndIfaceCache, bool aDefineOnGlobal);
59
60
  inline JS::Handle<JSObject*> GetProtoObjectHandle(JSContext* aCx)
61
0
  {
62
0
    /* Get the interface prototype object for this class.  This will create the
63
0
       object as needed. */
64
0
    return GetPerInterfaceObjectHandle(aCx, prototypes::id::HTMLElement,
65
0
                                       &CreateInterfaceObjects,
66
0
                                       /* aDefineOnGlobal = */ true);
67
0
68
0
  }
69
70
  JSObject*
71
  GetProtoObject(JSContext* aCx);
72
73
  inline JS::Handle<JSObject*> GetConstructorObjectHandle(JSContext* aCx, bool aDefineOnGlobal = true)
74
0
  {
75
0
    /* Get the interface object for this class.  This will create the object as
76
0
       needed. */
77
0
78
0
    return GetPerInterfaceObjectHandle(aCx, constructors::id::HTMLElement,
79
0
                                       &CreateInterfaceObjects,
80
0
                                       aDefineOnGlobal);
81
0
  }
82
83
  JSObject*
84
  GetConstructorObject(JSContext* aCx);
85
86
} // namespace HTMLElement_Binding
87
88
89
90
namespace HTMLUnknownElement_Binding {
91
92
  typedef mozilla::dom::HTMLUnknownElement NativeType;
93
94
  const JSClass*
95
  GetJSClass();
96
97
  bool
98
  Wrap(JSContext* aCx, mozilla::dom::HTMLUnknownElement* aObject, nsWrapperCache* aCache, JS::Handle<JSObject*> aGivenProto, JS::MutableHandle<JSObject*> aReflector);
99
100
  template <class T>
101
  inline JSObject* Wrap(JSContext* aCx, T* aObject, JS::Handle<JSObject*> aGivenProto)
102
0
  {
103
0
    JS::Rooted<JSObject*> reflector(aCx);
104
0
    return Wrap(aCx, aObject, aObject, aGivenProto, &reflector) ? reflector.get() : nullptr;
105
0
  }
106
107
  // We declare this as an array so that retrieving a pointer to this
108
  // binding's property hooks only requires compile/link-time resolvable
109
  // address arithmetic.  Declaring it as a pointer instead would require
110
  // doing a run-time load to fetch a pointer to this binding's property
111
  // hooks.  And then structures which embedded a pointer to this structure
112
  // would require a run-time load for proper initialization, which would
113
  // then induce static constructors.  Lots of static constructors.
114
  extern const NativePropertyHooks sNativePropertyHooks[];
115
116
  void
117
  CreateInterfaceObjects(JSContext* aCx, JS::Handle<JSObject*> aGlobal, ProtoAndIfaceCache& aProtoAndIfaceCache, bool aDefineOnGlobal);
118
119
  inline JS::Handle<JSObject*> GetProtoObjectHandle(JSContext* aCx)
120
0
  {
121
0
    /* Get the interface prototype object for this class.  This will create the
122
0
       object as needed. */
123
0
    return GetPerInterfaceObjectHandle(aCx, prototypes::id::HTMLUnknownElement,
124
0
                                       &CreateInterfaceObjects,
125
0
                                       /* aDefineOnGlobal = */ true);
126
0
127
0
  }
128
129
  inline JS::Handle<JSObject*> GetConstructorObjectHandle(JSContext* aCx, bool aDefineOnGlobal = true)
130
0
  {
131
0
    /* Get the interface object for this class.  This will create the object as
132
0
       needed. */
133
0
134
0
    return GetPerInterfaceObjectHandle(aCx, constructors::id::HTMLUnknownElement,
135
0
                                       &CreateInterfaceObjects,
136
0
                                       aDefineOnGlobal);
137
0
  }
138
139
  JSObject*
140
  GetConstructorObject(JSContext* aCx);
141
142
} // namespace HTMLUnknownElement_Binding
143
144
145
146
} // namespace dom
147
} // namespace mozilla
148
149
#endif // mozilla_dom_HTMLElementBinding_h