fromJson static method

EmployeePin? fromJson(
  1. dynamic value
)

Returns a new EmployeePin instance and imports its values from value if it's a Map, null otherwise.

Implementation

// ignore: prefer_constructors_over_static_methods
static EmployeePin? fromJson(dynamic value) {
  if (value is Map) {
    final json = value.cast<String, dynamic>();
    return EmployeePin(
      employeeId: mapValueOfType<int>(json, r'employeeId'),
      pin: mapValueOfType<String>(json, r'pin'),
    );
  }
  return null;
}