StorageAPI class

Constructors

StorageAPI({required String apiUrl, Map<String, String> getHeaders(String url)?, bool log = false})
const

Properties

apiUrl String
final
getHeaders → (Map<String, String> Function(String url)?)
final
hashCode int
The hash code for this object.
no setterinherited
log bool
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

delete<T>(String target, {Map<String, dynamic>? data, List<MultipartFile> files = const [], dynamic onFilesUpload(int bytes, int totalBytes)?, bool? log, Map<String, String> headers = const {}, bool appendHeader = true, String errorsField = 'errors', Encoding? encoding}) Future<APIResponse<T>>
get<T>(String target, {Map<String, dynamic>? data, List<MultipartFile> files = const [], dynamic onFilesUpload(int bytes, int totalBytes)?, bool? log, Map<String, String> headers = const {}, bool appendHeader = true, String errorsField = 'errors', Encoding? encoding}) Future<APIResponse<T>>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
patch<T>(String target, {Map<String, dynamic>? data, List<MultipartFile> files = const [], dynamic onFilesUpload(int bytes, int totalBytes)?, bool? log, Map<String, String> headers = const {}, bool appendHeader = true, String errorsField = 'errors', Encoding? encoding}) Future<APIResponse<T>>
post<T>(String target, {Map<String, dynamic>? data, List<MultipartFile> files = const [], dynamic onFilesUpload(int bytes, int totalBytes)?, bool? log, Map<String, String> headers = const {}, bool appendHeader = true, String errorsField = 'errors', Encoding? encoding}) Future<APIResponse<T>>
put<T>(String target, {Map<String, dynamic>? data, List<MultipartFile> files = const [], dynamic onFilesUpload(int bytes, int totalBytes)?, bool? log, Map<String, String> headers = const {}, bool appendHeader = true, String errorsField = 'errors', Encoding? encoding}) Future<APIResponse<T>>
request<T>(String target, RequestType type, {Map<String, dynamic>? data, List<MultipartFile> files = const [], dynamic onFilesUpload(int bytes, int totalBytes)?, bool? log, Map<String, String> headers = const {}, bool appendHeader = true, String errorsField = 'errors', Map<String, String> decodeErrors(Map errors)?, Encoding? encoding}) Future<APIResponse<T>>
toString() String
A string representation of this object.
inherited

Operators

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