/* Options: Date: 2025-12-06 05:25:20 Version: 8.70 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://api.sbbet.ath.cx //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: FindResponseMetrics.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ import 'package:servicestack/servicestack.dart'; class TimeResolution { static const TimeResolution Second = const TimeResolution._(1); static const TimeResolution Minute = const TimeResolution._(2); static const TimeResolution Hour = const TimeResolution._(5); static const TimeResolution Day = const TimeResolution._(10); final int _value; const TimeResolution._(this._value); int get value => _value; static List get values => const [Second,Minute,Hour,Day]; } class PaginatedQuery implements IConvertible { int? currentPage; int? pageSize; PaginatedQuery({this.currentPage,this.pageSize}); PaginatedQuery.fromJson(Map json) { fromMap(json); } fromMap(Map json) { currentPage = json['currentPage']; pageSize = json['pageSize']; return this; } Map toJson() => { 'currentPage': currentPage, 'pageSize': pageSize }; getTypeName() => "PaginatedQuery"; TypeContext? context = _ctx; } abstract class IPaginatedResult { int? currentPage; int? pageSize; int? totalItems; int? totalPages; } class PaginatedResult implements IPaginatedResult, IConvertible { List? data = []; int? currentPage; int? pageSize; int? totalItems; int? totalPages; PaginatedResult({this.data,this.currentPage,this.pageSize,this.totalItems,this.totalPages}); PaginatedResult.fromJson(Map json) { fromMap(json); } fromMap(Map json) { data = JsonConverters.fromJson(json['data'],'List<${runtimeGenericTypeDefs(this,[0]).join(",")}>',context!); currentPage = json['currentPage']; pageSize = json['pageSize']; totalItems = json['totalItems']; totalPages = json['totalPages']; return this; } Map toJson() => { 'data': JsonConverters.toJson(data,'List',context!), 'currentPage': currentPage, 'pageSize': pageSize, 'totalItems': totalItems, 'totalPages': totalPages }; getTypeName() => "PaginatedResult<$T>"; TypeContext? context = _ctx; } // @Route("/qry//metrics/e2e/slips/responses") class FindResponseMetrics extends PaginatedQuery implements IReturn>, IConvertible, IPost { TimeResolution? resolution; int? timepointFrom; int? timepointTo; FindResponseMetrics({this.resolution,this.timepointFrom,this.timepointTo}); FindResponseMetrics.fromJson(Map json) { fromMap(json); } fromMap(Map json) { super.fromMap(json); resolution = JsonConverters.fromJson(json['resolution'],'TimeResolution',context!); timepointFrom = json['timepointFrom']; timepointTo = json['timepointTo']; return this; } Map toJson() => super.toJson()..addAll({ 'resolution': JsonConverters.toJson(resolution,'TimeResolution',context!), 'timepointFrom': timepointFrom, 'timepointTo': timepointTo }); createResponse() => PaginatedResult(); getResponseTypeName() => "PaginatedResult"; getTypeName() => "FindResponseMetrics"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'api.sbbet.ath.cx', types: { 'TimeResolution': TypeInfo(TypeOf.Enum, enumValues:TimeResolution.values), 'PaginatedQuery': TypeInfo(TypeOf.Class, create:() => PaginatedQuery()), 'IPaginatedResult': TypeInfo(TypeOf.Interface), 'PaginatedResult': TypeInfo(TypeOf.GenericDef,create:() => PaginatedResult()), 'PaginatedResult': TypeInfo(TypeOf.Class, create:() => PaginatedResult()), 'ResponseMetrics': TypeInfo(TypeOf.Class, create:() => ResponseMetrics()), 'FindResponseMetrics': TypeInfo(TypeOf.Class, create:() => FindResponseMetrics()), });