APIBase class
APIBase class contains attributes, properties and methods for base implementation of the http requests like GET, POST.
Constructors
- APIBase()
Properties
Methods
-
get(
String apiKey, BuildContext context, {String? apiUrl, dynamic bodyData, Options? options}) → Future< BaseResponseModel> -
get method will be used to call
GETmethod in all the methods which is making use ofGETmethods.apiUrlwill be used to specify the particular url that will be used for the API call.optionswill be theGETrequestOptionsgiven by theDiopackage. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
post(
String apiKey, BuildContext context, {String? apiUrl, dynamic bodyData, Options? options}) → Future< BaseResponseModel> -
post method will be used to call
POSTmethod in all the methods which is making use ofPOSTmethods.apiUrlwill be used to specify the particular url that will be used for the API call.bodyDatawill be used to set the body data for thePOSTmethod if any.optionswill be thePOSTrequestOptionsgiven by theDiopackage. -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited