/* Options: Date: 2024-12-23 11:55:49 Version: 8.0 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://consumer-api.brovs.com //GlobalNamespace: ConsumerApi //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: ProfileUpdatePersonalInformationRequest.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ library ConsumerApi; import 'package:servicestack/servicestack.dart'; class DateOfBirth implements IConvertible { int? year; int? month; int? dayOfMonth; DateOfBirth({this.year,this.month,this.dayOfMonth}); DateOfBirth.fromJson(Map json) { fromMap(json); } fromMap(Map json) { year = json['year']; month = json['month']; dayOfMonth = json['dayOfMonth']; return this; } Map toJson() => { 'year': year, 'month': month, 'dayOfMonth': dayOfMonth }; getTypeName() => "DateOfBirth"; TypeContext? context = _ctx; } enum Sex { Male, Female, } enum DistanceUnit { Kilometer, Mile, } class ProfileUpdatePersonalInformationResponse implements IConvertible { String? firstName; String? lastName; DateOfBirth? dateOfBirth; Sex? sex; DistanceUnit? showDistancesIn; ProfileUpdatePersonalInformationResponse({this.firstName,this.lastName,this.dateOfBirth,this.sex,this.showDistancesIn}); ProfileUpdatePersonalInformationResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { firstName = json['firstName']; lastName = json['lastName']; dateOfBirth = JsonConverters.fromJson(json['dateOfBirth'],'DateOfBirth',context!); sex = JsonConverters.fromJson(json['sex'],'Sex',context!); showDistancesIn = JsonConverters.fromJson(json['showDistancesIn'],'DistanceUnit',context!); return this; } Map toJson() => { 'firstName': firstName, 'lastName': lastName, 'dateOfBirth': JsonConverters.toJson(dateOfBirth,'DateOfBirth',context!), 'sex': JsonConverters.toJson(sex,'Sex',context!), 'showDistancesIn': JsonConverters.toJson(showDistancesIn,'DistanceUnit',context!) }; getTypeName() => "ProfileUpdatePersonalInformationResponse"; TypeContext? context = _ctx; } // @Route("/profile/personal-information", "PUT") class ProfileUpdatePersonalInformationRequest implements IReturn, IPut, IConvertible { String? firstName; String? lastName; DateOfBirth? dateOfBirth; Sex? sex; DistanceUnit? showDistancesIn; ProfileUpdatePersonalInformationRequest({this.firstName,this.lastName,this.dateOfBirth,this.sex,this.showDistancesIn}); ProfileUpdatePersonalInformationRequest.fromJson(Map json) { fromMap(json); } fromMap(Map json) { firstName = json['firstName']; lastName = json['lastName']; dateOfBirth = JsonConverters.fromJson(json['dateOfBirth'],'DateOfBirth',context!); sex = JsonConverters.fromJson(json['sex'],'Sex',context!); showDistancesIn = JsonConverters.fromJson(json['showDistancesIn'],'DistanceUnit',context!); return this; } Map toJson() => { 'firstName': firstName, 'lastName': lastName, 'dateOfBirth': JsonConverters.toJson(dateOfBirth,'DateOfBirth',context!), 'sex': JsonConverters.toJson(sex,'Sex',context!), 'showDistancesIn': JsonConverters.toJson(showDistancesIn,'DistanceUnit',context!) }; createResponse() => ProfileUpdatePersonalInformationResponse(); getResponseTypeName() => "ProfileUpdatePersonalInformationResponse"; getTypeName() => "ProfileUpdatePersonalInformationRequest"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'ConsumerApi', types: { 'DateOfBirth': TypeInfo(TypeOf.Class, create:() => DateOfBirth()), 'Sex': TypeInfo(TypeOf.Enum, enumValues:Sex.values), 'DistanceUnit': TypeInfo(TypeOf.Enum, enumValues:DistanceUnit.values), 'ProfileUpdatePersonalInformationResponse': TypeInfo(TypeOf.Class, create:() => ProfileUpdatePersonalInformationResponse()), 'ProfileUpdatePersonalInformationRequest': TypeInfo(TypeOf.Class, create:() => ProfileUpdatePersonalInformationRequest()), });