Trait.fromJson constructor

Trait.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory Trait.fromJson(Map<String, dynamic> json) {
  return Trait(
    name: (json['Name'] as String?)?.toAttributeName(),
    score: json['Score'] as double?,
  );
}