/work/obj-fuzz/dist/include/mozilla/dom/SVGGraphicsElementBinding.h
Line | Count | Source (jump to first uncovered line) |
1 | | /* THIS FILE IS AUTOGENERATED FROM SVGGraphicsElement.webidl BY Codegen.py - DO NOT EDIT */ |
2 | | |
3 | | #ifndef mozilla_dom_SVGGraphicsElementBinding_h |
4 | | #define mozilla_dom_SVGGraphicsElementBinding_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 | | namespace mozilla { |
15 | | namespace dom { |
16 | | |
17 | | struct NativePropertyHooks; |
18 | | class ProtoAndIfaceCache; |
19 | | struct SVGBoundingBoxOptionsAtoms; |
20 | | class SVGGraphicsElement; |
21 | | struct SVGGraphicsElementAtoms; |
22 | | |
23 | | } // namespace dom |
24 | | } // namespace mozilla |
25 | | |
26 | | namespace mozilla { |
27 | | namespace dom { |
28 | | |
29 | | struct SVGBoundingBoxOptions : public DictionaryBase |
30 | | { |
31 | | MOZ_INIT_OUTSIDE_CTOR bool mClipped; |
32 | | MOZ_INIT_OUTSIDE_CTOR bool mFill; |
33 | | MOZ_INIT_OUTSIDE_CTOR bool mMarkers; |
34 | | MOZ_INIT_OUTSIDE_CTOR bool mStroke; |
35 | | |
36 | | SVGBoundingBoxOptions(); |
37 | | |
38 | | explicit inline SVGBoundingBoxOptions(const FastDictionaryInitializer& ) |
39 | 0 | { |
40 | 0 | // Do nothing here; this is used by our "Fast" subclass |
41 | 0 | } |
42 | | |
43 | | explicit inline SVGBoundingBoxOptions(const SVGBoundingBoxOptions& aOther) |
44 | 0 | { |
45 | 0 | *this = aOther; |
46 | 0 | } |
47 | | |
48 | | bool |
49 | | Init(JSContext* cx, JS::Handle<JS::Value> val, const char* sourceDescription = "Value", bool passedToJSImpl = false); |
50 | | |
51 | | bool |
52 | | Init(const nsAString& aJSON); |
53 | | |
54 | | bool |
55 | | ToObjectInternal(JSContext* cx, JS::MutableHandle<JS::Value> rval) const; |
56 | | |
57 | | bool |
58 | | ToJSON(nsAString& aJSON) const; |
59 | | |
60 | | void |
61 | | TraceDictionary(JSTracer* trc); |
62 | | |
63 | | SVGBoundingBoxOptions& |
64 | | operator=(const SVGBoundingBoxOptions& aOther); |
65 | | |
66 | | private: |
67 | | static bool |
68 | | InitIds(JSContext* cx, SVGBoundingBoxOptionsAtoms* atomsCache); |
69 | | }; |
70 | | |
71 | | namespace binding_detail { |
72 | | struct FastSVGBoundingBoxOptions : public SVGBoundingBoxOptions |
73 | | { |
74 | | inline FastSVGBoundingBoxOptions() |
75 | | : SVGBoundingBoxOptions(FastDictionaryInitializer()) |
76 | 0 | { |
77 | 0 | // Doesn't matter what int we pass to the parent constructor |
78 | 0 | } |
79 | | }; |
80 | | } // namespace binding_detail |
81 | | |
82 | | |
83 | | namespace SVGGraphicsElement_Binding { |
84 | | |
85 | | typedef mozilla::dom::SVGGraphicsElement NativeType; |
86 | | |
87 | | // We declare this as an array so that retrieving a pointer to this |
88 | | // binding's property hooks only requires compile/link-time resolvable |
89 | | // address arithmetic. Declaring it as a pointer instead would require |
90 | | // doing a run-time load to fetch a pointer to this binding's property |
91 | | // hooks. And then structures which embedded a pointer to this structure |
92 | | // would require a run-time load for proper initialization, which would |
93 | | // then induce static constructors. Lots of static constructors. |
94 | | extern const NativePropertyHooks sNativePropertyHooks[]; |
95 | | |
96 | | void |
97 | | CreateInterfaceObjects(JSContext* aCx, JS::Handle<JSObject*> aGlobal, ProtoAndIfaceCache& aProtoAndIfaceCache, bool aDefineOnGlobal); |
98 | | |
99 | | inline JS::Handle<JSObject*> GetProtoObjectHandle(JSContext* aCx) |
100 | 0 | { |
101 | 0 | /* Get the interface prototype object for this class. This will create the |
102 | 0 | object as needed. */ |
103 | 0 | return GetPerInterfaceObjectHandle(aCx, prototypes::id::SVGGraphicsElement, |
104 | 0 | &CreateInterfaceObjects, |
105 | 0 | /* aDefineOnGlobal = */ true); |
106 | 0 |
|
107 | 0 | } |
108 | | |
109 | | JSObject* |
110 | | GetProtoObject(JSContext* aCx); |
111 | | |
112 | | inline JS::Handle<JSObject*> GetConstructorObjectHandle(JSContext* aCx, bool aDefineOnGlobal = true) |
113 | 0 | { |
114 | 0 | /* Get the interface object for this class. This will create the object as |
115 | 0 | needed. */ |
116 | 0 |
|
117 | 0 | return GetPerInterfaceObjectHandle(aCx, constructors::id::SVGGraphicsElement, |
118 | 0 | &CreateInterfaceObjects, |
119 | 0 | aDefineOnGlobal); |
120 | 0 | } |
121 | | |
122 | | JSObject* |
123 | | GetConstructorObject(JSContext* aCx); |
124 | | |
125 | | } // namespace SVGGraphicsElement_Binding |
126 | | |
127 | | |
128 | | |
129 | | } // namespace dom |
130 | | } // namespace mozilla |
131 | | |
132 | | #endif // mozilla_dom_SVGGraphicsElementBinding_h |