FhirUrl.fromYaml constructor

FhirUrl.fromYaml(
  1. dynamic yaml
)

Implementation

factory FhirUrl.fromYaml(dynamic yaml) => yaml is String
    ? FhirUrl.fromJson(jsonDecode(jsonEncode(loadYaml(yaml))))
    : yaml is YamlMap
        ? FhirUrl.fromJson(jsonDecode(jsonEncode(yaml)))
        : throw YamlFormatException<FhirUrl>(
            'FormatException: "$json" is not a valid Yaml string or YamlMap.');