Rule.fromJson constructor

Rule.fromJson(
  1. Map _json
)

Implementation

Rule.fromJson(core.Map _json)
    : this(
        destinations: _json.containsKey('destinations')
            ? (_json['destinations'] as core.List)
                .map<Destination>((value) => Destination.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        sources: _json.containsKey('sources')
            ? (_json['sources'] as core.List)
                .map<Source>((value) => Source.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
      );