ApiEndpointBase<T extends Object> class
abstract
Implementation base class for ApiEndpoint with ApiEndpointMixin.
- Mixed-in types
Constructors
- ApiEndpointBase()
-
Const default generative constructor for base classes.
const
Properties
-
deserializer
→ JsonDeserializer<
T> -
Deserializes JSON to an object of type
T
.no setterinherited - hashCode → int
-
The hash code for this object.
no setterinherited
-
headers
→ Map<
String, String> ? -
Returns the headers for the API endpoint request.
no setterinherited
- host → String
-
The host part of the API endpoint request.
no setterinherited
- name → String
-
Returns the name of the endpoint
no setterinherited
- path → String
-
The path element for the API endpoint uri.
no setterinherited
- protocol → HttpProtocol
-
The protocol of the API endpoint.
no setterinherited
-
queryParameters
→ Map<
String, String> ? -
The query parameters for the endpoint.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
serializer
→ JsonSerializer<
T> -
Serializes an object of type
T
to JSON.no setterinherited
Methods
-
get(
) → Future< T?> -
Asynchronously returns an object of type
T
from the API endpoint.inherited -
getJson(
) → Future< Map< String, dynamic> ?> -
Asynchronously gets a JSON object from the API endpoint using GET.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
post(
T? obj) → Future< T?> -
Asynchronously posts an
obj
of typeT
to the API endpoint using POST.inherited -
postJson(
JSON? json) → Future< Map< String, dynamic> ?> -
Asynchronously posts a
json
document to the API endpoint using POST.inherited -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited