1 module libwasm.bindings.MutationEvent; 2 3 import libwasm.types; 4 5 import memutils.ct: tuple; 6 import libwasm.bindings.Event; 7 import libwasm.bindings.Node; 8 9 @safe: 10 nothrow: 11 12 struct MutationEvent { 13 nothrow: 14 libwasm.bindings.Event.Event _parent; 15 alias _parent this; 16 this(Handle h) { 17 _parent = .Event(h); 18 } 19 enum ushort MODIFICATION = 1; 20 enum ushort ADDITION = 2; 21 enum ushort REMOVAL = 3; 22 enum ushort SMIL = 4; 23 auto relatedNode()() { 24 return recastOpt!(Node)(Object_Getter__OptionalHandle(this._parent, "relatedNode")); 25 } 26 string prevValue()() { 27 return Object_Getter__string(this._parent, "prevValue"); 28 } 29 string newValue()() { 30 return Object_Getter__string(this._parent, "newValue"); 31 } 32 string attrName()() { 33 return Object_Getter__string(this._parent, "attrName"); 34 } 35 ushort attrChange()() { 36 return Object_Getter__ushort(this._parent, "attrChange"); 37 } 38 void initMutationEvent(T3)(string type, bool canBubble /* = false */, bool cancelable /* = false */, scope auto ref Optional!(T3) relatedNode /* = no!(Node) */, string prevValue /* = "" */, string newValue /* = "" */, string attrName /* = "" */, ushort attrChange /* = 0 */) if (isTOrPointer!(T3, Node)) { 39 Serialize_Object_VarArgCall!void(this._parent, "initMutationEvent", "string;bool;bool;Optional!Handle;string;string;string;ushort", tuple(type, canBubble, cancelable, !relatedNode.empty, cast(Handle)relatedNode.front._parent, prevValue, newValue, attrName, attrChange)); 40 } 41 void initMutationEvent(T3)(string type, bool canBubble /* = false */, bool cancelable /* = false */, scope auto ref Optional!(T3) relatedNode /* = no!(Node) */, string prevValue /* = "" */, string newValue /* = "" */, string attrName /* = "" */) if (isTOrPointer!(T3, Node)) { 42 Serialize_Object_VarArgCall!void(this._parent, "initMutationEvent", "string;bool;bool;Optional!Handle;string;string;string", tuple(type, canBubble, cancelable, !relatedNode.empty, cast(Handle)relatedNode.front._parent, prevValue, newValue, attrName)); 43 } 44 void initMutationEvent(T3)(string type, bool canBubble /* = false */, bool cancelable /* = false */, scope auto ref Optional!(T3) relatedNode /* = no!(Node) */, string prevValue /* = "" */, string newValue /* = "" */) if (isTOrPointer!(T3, Node)) { 45 Serialize_Object_VarArgCall!void(this._parent, "initMutationEvent", "string;bool;bool;Optional!Handle;string;string", tuple(type, canBubble, cancelable, !relatedNode.empty, cast(Handle)relatedNode.front._parent, prevValue, newValue)); 46 } 47 void initMutationEvent(T3)(string type, bool canBubble /* = false */, bool cancelable /* = false */, scope auto ref Optional!(T3) relatedNode /* = no!(Node) */, string prevValue /* = "" */) if (isTOrPointer!(T3, Node)) { 48 Serialize_Object_VarArgCall!void(this._parent, "initMutationEvent", "string;bool;bool;Optional!Handle;string", tuple(type, canBubble, cancelable, !relatedNode.empty, cast(Handle)relatedNode.front._parent, prevValue)); 49 } 50 void initMutationEvent(T3)(string type, bool canBubble /* = false */, bool cancelable /* = false */, scope auto ref Optional!(T3) relatedNode /* = no!(Node) */) if (isTOrPointer!(T3, Node)) { 51 Serialize_Object_VarArgCall!void(this._parent, "initMutationEvent", "string;bool;bool;Optional!Handle", tuple(type, canBubble, cancelable, !relatedNode.empty, cast(Handle)relatedNode.front._parent)); 52 } 53 void initMutationEvent()(string type, bool canBubble /* = false */, bool cancelable /* = false */) { 54 Serialize_Object_VarArgCall!void(this._parent, "initMutationEvent", "string;bool;bool", tuple(type, canBubble, cancelable)); 55 } 56 void initMutationEvent()(string type, bool canBubble /* = false */) { 57 Serialize_Object_VarArgCall!void(this._parent, "initMutationEvent", "string;bool", tuple(type, canBubble)); 58 } 59 void initMutationEvent()(string type) { 60 Object_Call_string__void(this._parent, "initMutationEvent", type); 61 } 62 } 63 64