fast_cached_network_image
library
Classes
-
FastCachedImage
-
FastCachedImage creates a widget to display network images. This widget downloads the network image
when this widget is build for the first time. Later whenever this widget is called the image will be displayed from
the downloaded database instead of the network. This can avoid unnecessary downloads and load images much faster.
Provide the url for the image to display.
errorBuilder must return a widget. This widget will be displayed if there is any error in downloading or displaying
the downloaded image
loadingBuilder must return a widget. This widget is shown when the image is being downloaded and processed
fadeInDuration can be adjusted to change the duration of the fade transition between the loadingBuilder
and the actual image. Default value is 500 ms.
disableErrorLogs can be set to true if you want to ignore error logs from the widget
-
FastCachedImageConfig
-
FastCachedImageConfig is the class to set the configurations.
init function initializes the cache management system.
The path param must be a valid location such as temporary directory in android.
clearCacheAfter
property is used to set a duration after which the cache will be cleared.
Default value of clearCacheAfter
is 7 days which means if clearCacheAfter
is set to null,
an image cached today will be cleared when you open the app after 7 days from now.