getImage method
Future<DynamiteResponse<Uint8List, void> >
getImage({
- required String key,
- ThemingGetImageUseSvg? useSvg,
Get an image.
Returns a Future containing a DynamiteResponse with the status code, deserialized body and headers.
Throws a DynamiteApiException if the API call does not return an expected status code.
Parameters:
useSvgReturn image as SVG. Defaults to1.keyKey of the image.
Status codes:
- 200: Image returned
- 404: Image not found
- 500
See:
- getImageRaw for an experimental operation that returns a
DynamiteRawResponsethat can be serialized.
Implementation
Future<_i1.DynamiteResponse<Uint8List, void>> getImage({
required String key,
ThemingGetImageUseSvg? useSvg,
}) async {
final rawResponse = getImageRaw(
key: key,
useSvg: useSvg,
);
return rawResponse.future;
}