/* Options: Date: 2024-05-14 20:28:50 Version: 8.23 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://test.servicestack.net //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: HelloWithGenericInheritance2.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart,dart:typed_data,dart:collection */ import 'package:servicestack/servicestack.dart'; import 'dart:typed_data'; import 'dart:collection'; abstract class HelloBase { List? items; List? counts; HelloBase({this.items,this.counts}); HelloBase.fromJson(Map json) { fromMap(json); } fromMap(Map json) { items = JsonConverters.fromJson(json['items'],'List<${runtimeGenericTypeDefs(this,[0]).join(",")}>',context!); counts = JsonConverters.fromJson(json['counts'],'List',context!); return this; } Map toJson() => { 'items': JsonConverters.toJson(items,'List',context!), 'counts': JsonConverters.toJson(counts,'List',context!) }; getTypeName() => "HelloBase<$T>"; TypeContext? context = _ctx; } // @Route("/hello") // @Route("/hello/{Name}") class Hello implements IReturn, IConvertible, IPost { // @required() String? name; String? title; Hello({this.name,this.title}); Hello.fromJson(Map json) { fromMap(json); } fromMap(Map json) { name = json['name']; title = json['title']; return this; } Map toJson() => { 'name': name, 'title': title }; createResponse() => HelloResponse(); getResponseTypeName() => "HelloResponse"; getTypeName() => "Hello"; TypeContext? context = _ctx; } class HelloWithGenericInheritance2 extends HelloBase implements IConvertible, IPost { String? result; HelloWithGenericInheritance2({this.result}); HelloWithGenericInheritance2.fromJson(Map json) { fromMap(json); } fromMap(Map json) { super.fromMap(json); result = json['result']; return this; } Map toJson() => super.toJson()..addAll({ 'result': result }); getTypeName() => "HelloWithGenericInheritance2"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'test.servicestack.net', types: { 'HelloBase': TypeInfo(TypeOf.AbstractClass), 'Hello': TypeInfo(TypeOf.Class, create:() => Hello()), 'HelloWithGenericInheritance2': TypeInfo(TypeOf.Class, create:() => HelloWithGenericInheritance2()), });