cached_media_init library
Properties
-
allCachedMediaInfo
→ List<
CachedMediaInfo> -
final
- cacheMaxSizeDefault ↔ double
-
getter/setter pair
- currentCacheSize ↔ double
-
getter/setter pair
- getShowLogs → bool
-
no setter
- getTempDir → dynamic
-
no setter
- isInitialized ↔ bool
-
getter/setter pair
- tempDir ↔ dynamic
-
getter/setter pair
Functions
-
cleanCache(
{required GetStorage getStorage}) → Future< void> -
initializeCachedMedia(
{double cacheMaxSize = 100, bool showLogs = false, bool clearCache = false, required GetStorage getStorage}) → Future< void> -
The function initializeCachedMedia() must be placed after WidgetsFlutterBinding.ensureInitialized()
You can define the size in megabytes(e.g. 100 MB) for
cacheMaxSize. It will help maintain the performance of your app. SetshowLogstotrueto show logs about the cache behavior & sizes. -
initStreamListener(
{bool showLogs = false, required GetStorage getStorage}) → Future< void>