/* Options: Date: 2024-11-21 03:03:27 Version: 6.00 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://resourcelibrary.api.ashcompanies.com //GlobalNamespace: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: ResourceItemSearchRequest.* //ExcludeTypes: //DefaultImports: package:servicestack/servicestack.dart */ import 'package:servicestack/servicestack.dart'; class BasicResourceLibraryRequest implements IConvertible { int? resourceLibraryMemberId; BasicResourceLibraryRequest({this.resourceLibraryMemberId}); BasicResourceLibraryRequest.fromJson(Map json) { fromMap(json); } fromMap(Map json) { resourceLibraryMemberId = json['resourceLibraryMemberId']; return this; } Map toJson() => { 'resourceLibraryMemberId': resourceLibraryMemberId }; getTypeName() => "BasicResourceLibraryRequest"; TypeContext? context = _ctx; } class Tag implements IConvertible { String? id; String? title; Tag({this.id,this.title}); Tag.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; title = json['title']; return this; } Map toJson() => { 'id': id, 'title': title }; getTypeName() => "Tag"; TypeContext? context = _ctx; } class ResourceItemForSearch implements IConvertible { String? id; String? type; List? categories; List? categoryIndexes; String? title; String? description; String? descriptionSummary; String? content; List? tags; bool? isComplete; bool? isFavorite; bool? isImplicitlyComplete; String? transcript; String? thumbnail; String? difficulty; String? duration; String? mediaPath; ResourceItemForSearch({this.id,this.type,this.categories,this.categoryIndexes,this.title,this.description,this.descriptionSummary,this.content,this.tags,this.isComplete,this.isFavorite,this.isImplicitlyComplete,this.transcript,this.thumbnail,this.difficulty,this.duration,this.mediaPath}); ResourceItemForSearch.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; type = json['type']; categories = JsonConverters.fromJson(json['categories'],'List',context!); categoryIndexes = JsonConverters.fromJson(json['categoryIndexes'],'List',context!); title = json['title']; description = json['description']; descriptionSummary = json['descriptionSummary']; content = json['content']; tags = JsonConverters.fromJson(json['tags'],'List',context!); isComplete = json['isComplete']; isFavorite = json['isFavorite']; isImplicitlyComplete = json['isImplicitlyComplete']; transcript = json['transcript']; thumbnail = json['thumbnail']; difficulty = json['difficulty']; duration = json['duration']; mediaPath = json['mediaPath']; return this; } Map toJson() => { 'id': id, 'type': type, 'categories': JsonConverters.toJson(categories,'List',context!), 'categoryIndexes': JsonConverters.toJson(categoryIndexes,'List',context!), 'title': title, 'description': description, 'descriptionSummary': descriptionSummary, 'content': content, 'tags': JsonConverters.toJson(tags,'List',context!), 'isComplete': isComplete, 'isFavorite': isFavorite, 'isImplicitlyComplete': isImplicitlyComplete, 'transcript': transcript, 'thumbnail': thumbnail, 'difficulty': difficulty, 'duration': duration, 'mediaPath': mediaPath }; getTypeName() => "ResourceItemForSearch"; TypeContext? context = _ctx; } class SearchResult implements IConvertible { String? id; List? resourceItems; List? searchItems; List? tags; int? itemCount; SearchResult({this.id,this.resourceItems,this.searchItems,this.tags,this.itemCount}); SearchResult.fromJson(Map json) { fromMap(json); } fromMap(Map json) { id = json['id']; resourceItems = JsonConverters.fromJson(json['resourceItems'],'List',context!); searchItems = JsonConverters.fromJson(json['searchItems'],'List',context!); tags = JsonConverters.fromJson(json['tags'],'List',context!); itemCount = json['itemCount']; return this; } Map toJson() => { 'id': id, 'resourceItems': JsonConverters.toJson(resourceItems,'List',context!), 'searchItems': JsonConverters.toJson(searchItems,'List',context!), 'tags': JsonConverters.toJson(tags,'List',context!), 'itemCount': itemCount }; getTypeName() => "SearchResult"; TypeContext? context = _ctx; } class ResourceItemSearchResponse implements IConvertible { SearchResult? searchResults; ResourceItemSearchResponse({this.searchResults}); ResourceItemSearchResponse.fromJson(Map json) { fromMap(json); } fromMap(Map json) { searchResults = JsonConverters.fromJson(json['searchResults'],'SearchResult',context!); return this; } Map toJson() => { 'searchResults': JsonConverters.toJson(searchResults,'SearchResult',context!) }; getTypeName() => "ResourceItemSearchResponse"; TypeContext? context = _ctx; } // @Route("/searchResults", "GET") class ResourceItemSearchRequest extends BasicResourceLibraryRequest implements IReturn, IConvertible { String? request; List? tags; String? categoryId; int? offset; int? limit; bool? digitalFitness; ResourceItemSearchRequest({this.request,this.tags,this.categoryId,this.offset,this.limit,this.digitalFitness}); ResourceItemSearchRequest.fromJson(Map json) { fromMap(json); } fromMap(Map json) { super.fromMap(json); request = json['request']; tags = JsonConverters.fromJson(json['tags'],'List',context!); categoryId = json['categoryId']; offset = json['offset']; limit = json['limit']; digitalFitness = json['digitalFitness']; return this; } Map toJson() => super.toJson()..addAll({ 'request': request, 'tags': JsonConverters.toJson(tags,'List',context!), 'categoryId': categoryId, 'offset': offset, 'limit': limit, 'digitalFitness': digitalFitness }); createResponse() => ResourceItemSearchResponse(); getResponseTypeName() => "ResourceItemSearchResponse"; getTypeName() => "ResourceItemSearchRequest"; TypeContext? context = _ctx; } TypeContext _ctx = TypeContext(library: 'resourcelibrary.api.ashcompanies.com', types: { 'BasicResourceLibraryRequest': TypeInfo(TypeOf.Class, create:() => BasicResourceLibraryRequest()), 'Tag': TypeInfo(TypeOf.Class, create:() => Tag()), 'ResourceItemForSearch': TypeInfo(TypeOf.Class, create:() => ResourceItemForSearch()), 'SearchResult': TypeInfo(TypeOf.Class, create:() => SearchResult()), 'List': TypeInfo(TypeOf.Class, create:() => []), 'List': TypeInfo(TypeOf.Class, create:() => []), 'ResourceItemSearchResponse': TypeInfo(TypeOf.Class, create:() => ResourceItemSearchResponse()), 'ResourceItemSearchRequest': TypeInfo(TypeOf.Class, create:() => ResourceItemSearchRequest()), });