quickGetObject<T extends NUIEnt> method
Implementation
T? quickGetObject<T extends NUIEnt>(String key, NUIEntMapper<T> entity){
try{
String? value = _pref!.getString(key);
if(isNullOrEmpty(value)){
return null;
}
return entity.toEntity(jsonDecode(value!));
}catch(e){
log("NUISharedPref -> Failed to decode object ${entity.entityName()}");
return null;
}
}