GenericApiService class abstract

A generic base class for creating API services with built-in error handling.

Constructors

GenericApiService()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

delete<T>(String path, {dynamic data, Map<String, dynamic>? queryParameters, Options? options, T fromJson(dynamic)?}) Future<ApiResponse<T>>
Performs a DELETE request.
get<T>(String path, {Map<String, dynamic>? queryParameters, Options? options, T fromJson(dynamic)?}) Future<ApiResponse<T>>
Performs a GET request.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
post<T>(String path, {dynamic data, Map<String, dynamic>? queryParameters, Options? options, T fromJson(dynamic)?}) Future<ApiResponse<T>>
Performs a POST request.
put<T>(String path, {dynamic data, Map<String, dynamic>? queryParameters, Options? options, T fromJson(dynamic)?}) Future<ApiResponse<T>>
Performs a PUT request.
toString() String
A string representation of this object.
inherited

Operators

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