get method
Future<CoapResponse>
get(
- Uri uri, {
- CoapMediaType? accept,
- bool confirmable = true,
- List<
Option< ? options,Object?> > - bool earlyBlock2Negotiation = false,
- int maxRetransmit = 0,
- CoapMulticastResponseHandler? onMulticastResponse,
Sends a GET request.
Implementation
Future<CoapResponse> get(
final Uri uri, {
final CoapMediaType? accept,
final bool confirmable = true,
final List<Option<Object?>>? options,
final bool earlyBlock2Negotiation = false,
final int maxRetransmit = 0,
final CoapMulticastResponseHandler? onMulticastResponse,
}) {
final request =
CoapRequest.get(uri, confirmable: confirmable, accept: accept);
_build(
request,
options,
earlyBlock2Negotiation,
maxRetransmit,
);
return send(request, onMulticastResponse: onMulticastResponse);
}