deserialize<BodyType, InnerType> method

BodyType? deserialize<BodyType, InnerType>(
  1. dynamic entity
)

Implementation

BodyType? deserialize<BodyType, InnerType>(entity) {
  if (entity is BodyType) return entity;
  if (entity is Iterable) {
    return _deserializeListOf<InnerType>(entity) as BodyType;
  }

  return _deserialize<BodyType>(entity);
}