ResponseModel<T> class

Response wrapper model for standardized API responses Inspired by clean architecture patterns for consistent response handling

Constructors

ResponseModel({T? data, String? message, bool success = true, int? statusCode, Map<String, dynamic>? meta})
ResponseModel.fromJson(Map<String, dynamic> json, T decoder(dynamic)?)
factory
ResponseModel.fromResponse(Response response, T decoder(dynamic)?)
factory

Properties

data → T?
final
hashCode → int
The hash code for this object.
no setterinherited
message → String?
final
meta → Map<String, dynamic>?
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
statusCode → int?
final
success → bool
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited