HivePluginActionPatterns extension

Adds pattern-matching-related methods to HivePluginAction.

on

Methods

map<TResult extends Object?>({required TResult getKeys(HiveGetKeys value), required TResult getBoxList(HiveGetBoxs value), required TResult getValue(HiveGetValue value)}) → TResult

Available on HivePluginAction, provided by the HivePluginActionPatterns extension

A switch-like method, using callbacks.
mapOrNull<TResult extends Object?>({TResult? getKeys(HiveGetKeys value)?, TResult? getBoxList(HiveGetBoxs value)?, TResult? getValue(HiveGetValue value)?}) → TResult?

Available on HivePluginAction, provided by the HivePluginActionPatterns extension

A variant of map that fallback to returning null.
maybeMap<TResult extends Object?>({TResult getKeys(HiveGetKeys value)?, TResult getBoxList(HiveGetBoxs value)?, TResult getValue(HiveGetValue value)?, required TResult orElse()}) → TResult

Available on HivePluginAction, provided by the HivePluginActionPatterns extension

A variant of map that fallback to returning orElse.
maybeWhen<TResult extends Object?>({TResult getKeys(String projectName, String boxName)?, TResult getBoxList(String projectName)?, TResult getValue(String projectName, String key, String boxName)?, required TResult orElse()}) → TResult

Available on HivePluginAction, provided by the HivePluginActionPatterns extension

A variant of when that fallback to an orElse callback.
when<TResult extends Object?>({required TResult getKeys(String projectName, String boxName), required TResult getBoxList(String projectName), required TResult getValue(String projectName, String key, String boxName)}) → TResult

Available on HivePluginAction, provided by the HivePluginActionPatterns extension

A switch-like method, using callbacks.
whenOrNull<TResult extends Object?>({TResult? getKeys(String projectName, String boxName)?, TResult? getBoxList(String projectName)?, TResult? getValue(String projectName, String key, String boxName)?}) → TResult?

Available on HivePluginAction, provided by the HivePluginActionPatterns extension

A variant of when that fallback to returning null