translate method
dynamic
translate(
- dynamic value
Implementation
dynamic translate(dynamic value)
{
try
{
var v = value;
// not found
if (v == null) return null;
// found value
if (v is String) return value;
// parse
if (v is List)
{
if ((offset != null) && (offset! >= 0) && (v.length > offset!)) v = v[offset!];
if (dotnotation != null) v = Data.readValue(v,dotnotation?.signature);
}
// nothing
return v;
}
catch(e)
{
return null;
}
}