toMap method
- EnumMethod? enumMethod,
Converts instance to a map.
Implementation
Map<String, dynamic> toMap({EnumMethod? enumMethod}) {
return {
"frameId": frameId,
"isMainFrame": isMainFrame,
"kind": switch (enumMethod ?? EnumMethod.nativeValue) {
EnumMethod.nativeValue => kind?.toNativeValue(),
EnumMethod.value => kind?.toValue(),
EnumMethod.name => kind?.name(),
},
"name": name,
"request": request?.toMap(enumMethod: enumMethod),
"securityOrigin": securityOrigin?.toMap(enumMethod: enumMethod),
};
}