1 module libwasm.bindings.SecurityPolicyViolationEvent;
2 
3 import libwasm.types;
4 
5 import memutils.ct: tuple;
6 import libwasm.bindings.Event;
7 
8 @safe:
9 nothrow:
10 
11 struct SecurityPolicyViolationEvent {
12   nothrow:
13   libwasm.bindings.Event.Event _parent;
14   alias _parent this;
15   this(Handle h) {
16     _parent = .Event(h);
17   }
18   string documentURI()() {
19     return Object_Getter__string(this._parent, "documentURI");
20   }
21   string referrer()() {
22     return Object_Getter__string(this._parent, "referrer");
23   }
24   string blockedURI()() {
25     return Object_Getter__string(this._parent, "blockedURI");
26   }
27   string violatedDirective()() {
28     return Object_Getter__string(this._parent, "violatedDirective");
29   }
30   string effectiveDirective()() {
31     return Object_Getter__string(this._parent, "effectiveDirective");
32   }
33   string originalPolicy()() {
34     return Object_Getter__string(this._parent, "originalPolicy");
35   }
36   string sourceFile()() {
37     return Object_Getter__string(this._parent, "sourceFile");
38   }
39   string sample()() {
40     return Object_Getter__string(this._parent, "sample");
41   }
42   SecurityPolicyViolationEventDisposition disposition()() {
43     return Object_Getter__int(this._parent, "disposition");
44   }
45   ushort statusCode()() {
46     return Object_Getter__ushort(this._parent, "statusCode");
47   }
48   int lineNumber()() {
49     return Object_Getter__int(this._parent, "lineNumber");
50   }
51   int columnNumber()() {
52     return Object_Getter__int(this._parent, "columnNumber");
53   }
54 }
55 enum SecurityPolicyViolationEventDisposition {
56   enforce,
57   report
58 }
59 struct SecurityPolicyViolationEventInit {
60   nothrow:
61   libwasm.bindings.Event.EventInit _parent;
62   alias _parent this;
63   this(Handle h) {
64     _parent = .EventInit(h);
65   }
66   static auto create() {
67     return SecurityPolicyViolationEventInit(libwasm_add__object());
68   }
69   void documentURI()(string documentURI) {
70     Object_Call_string__void(this._parent, "documentURI", documentURI);
71   }
72   string documentURI()() {
73     return Object_Getter__string(this._parent, "documentURI");
74   }
75   void referrer()(string referrer) {
76     Object_Call_string__void(this._parent, "referrer", referrer);
77   }
78   string referrer()() {
79     return Object_Getter__string(this._parent, "referrer");
80   }
81   void blockedURI()(string blockedURI) {
82     Object_Call_string__void(this._parent, "blockedURI", blockedURI);
83   }
84   string blockedURI()() {
85     return Object_Getter__string(this._parent, "blockedURI");
86   }
87   void violatedDirective()(string violatedDirective) {
88     Object_Call_string__void(this._parent, "violatedDirective", violatedDirective);
89   }
90   string violatedDirective()() {
91     return Object_Getter__string(this._parent, "violatedDirective");
92   }
93   void effectiveDirective()(string effectiveDirective) {
94     Object_Call_string__void(this._parent, "effectiveDirective", effectiveDirective);
95   }
96   string effectiveDirective()() {
97     return Object_Getter__string(this._parent, "effectiveDirective");
98   }
99   void originalPolicy()(string originalPolicy) {
100     Object_Call_string__void(this._parent, "originalPolicy", originalPolicy);
101   }
102   string originalPolicy()() {
103     return Object_Getter__string(this._parent, "originalPolicy");
104   }
105   void sourceFile()(string sourceFile) {
106     Object_Call_string__void(this._parent, "sourceFile", sourceFile);
107   }
108   string sourceFile()() {
109     return Object_Getter__string(this._parent, "sourceFile");
110   }
111   void sample()(string sample) {
112     Object_Call_string__void(this._parent, "sample", sample);
113   }
114   string sample()() {
115     return Object_Getter__string(this._parent, "sample");
116   }
117   void disposition()(SecurityPolicyViolationEventDisposition disposition) {
118     Object_Call_int__void(this._parent, "disposition", disposition);
119   }
120   SecurityPolicyViolationEventDisposition disposition()() {
121     return Object_Getter__int(this._parent, "disposition");
122   }
123   void statusCode()(ushort statusCode) {
124     Serialize_Object_VarArgCall!void(this._parent, "statusCode", "ushort", tuple(statusCode));
125   }
126   ushort statusCode()() {
127     return Object_Getter__ushort(this._parent, "statusCode");
128   }
129   void lineNumber()(int lineNumber) {
130     Object_Call_int__void(this._parent, "lineNumber", lineNumber);
131   }
132   int lineNumber()() {
133     return Object_Getter__int(this._parent, "lineNumber");
134   }
135   void columnNumber()(int columnNumber) {
136     Object_Call_int__void(this._parent, "columnNumber", columnNumber);
137   }
138   int columnNumber()() {
139     return Object_Getter__int(this._parent, "columnNumber");
140   }
141 }
142 
143