OptimizedCacheImageProvider constructor
const
OptimizedCacheImageProvider(
- String url, {
- int? maxHeight,
- int? maxWidth,
- String? cacheKey,
- double scale,
- @Deprecated('ErrorListener is deprecated, use listeners on the imagestream') ErrorListener? errorListener,
- Map<
String, String> ? headers, - BaseCacheManager? cacheManager,
- ImageRenderMethodForWeb? imageRenderMethodForWeb,
Creates an object that fetches the image at the given URL.
The arguments url
and scale
must not be null.
The imageRenderMethodForWeb
defines the behavior of the ImageProvider
when compiled for web. See the documentation of ImageRenderMethodForWeb
for the benefits of each method.
Implementation
const factory OptimizedCacheImageProvider(
String url, {
int? maxHeight,
int? maxWidth,
String? cacheKey,
double scale,
@Deprecated('ErrorListener is deprecated, use listeners on the imagestream')
ErrorListener? errorListener,
Map<String, String>? headers,
BaseCacheManager? cacheManager,
ImageRenderMethodForWeb? imageRenderMethodForWeb,
}) = image_provider.OptimizedCacheImageProvider;