call<T> method

T call<T>(
  1. T object, {
  2. Cell? cell,
  3. dynamic user,
})

Applies the mapping to an object, walking up the parent chain if needed

Implementation

T call<T>(T object, {Cell? cell, dynamic user}) {
  T obj = parent != null ? parent!(object) : object;
  final type = T != dynamic ? T : obj.runtimeType;
  return map.containsKey(type) ? map[type]!<T>(obj) : obj;
}