Section.fromJson constructor

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

Implementation

factory Section.fromJson(Map<String, dynamic> json) {
  final section = Section(json['name']);
  section.properties = Map<String, String>.from(json['properties']);
  section.children = (json['children'] as List)
      .map((e) => ConfigElement.fromJson(e))
      .toList();
  return section;
}