RequestOptions class
Request options for HTTP calls
Constructors
-
RequestOptions({required String url, String method = 'GET', Map<
String, String> ? headers, dynamic body, dynamic json, ResponseType responseType = ResponseType.json, Duration timeout = const Duration(seconds: 20), bool allowNoResponse = false}) -
const
Properties
- allowNoResponse → bool
-
final
- body → dynamic
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
headers
→ Map<
String, String> ? -
final
- json → dynamic
-
final
- method → String
-
final
- responseType → ResponseType
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- timeout → Duration
-
final
- url → String
-
final
Methods
-
copyWith(
{String? url, String? method, Map< String, String> ? headers, dynamic body, dynamic json, ResponseType? responseType, Duration? timeout, bool? allowNoResponse}) → RequestOptions -
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