FhirTime.fromYaml constructor

FhirTime.fromYaml(
  1. dynamic yaml
)

Implementation

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