import 'package:json_annotation/json_annotation.dart'; import '../../../apiResponse.dart'; part 'getPollStateResponse.g.dart'; @JsonSerializable(explicitToJson: true) class GetPollStateResponse extends ApiResponse { GetPollStateResponseObject data; GetPollStateResponse(this.data); factory GetPollStateResponse.fromJson(Map json) => _$GetPollStateResponseFromJson(json); Map toJson() => _$GetPollStateResponseToJson(this); } @JsonSerializable(explicitToJson: true) class GetPollStateResponseObject { int id; String question; List options; dynamic votes; String actorType; String actorId; String actorDisplayName; int status; int resultMode; int maxVotes; List votedSelf; int? numVoters; List? details; GetPollStateResponseObject( this.id, this.question, this.options, this.votes, this.actorType, this.actorId, this.actorDisplayName, this.status, this.resultMode, this.maxVotes, this.votedSelf, this.numVoters, this.details); factory GetPollStateResponseObject.fromJson(Map json) => _$GetPollStateResponseObjectFromJson(json); Map toJson() => _$GetPollStateResponseObjectToJson(this); }