getAsNullableDuration method

Duration? getAsNullableDuration(
  1. String key
)

Converts map element into a Duration or returns null if conversion is not possible.

  • key a key of element to get. Returns Duration value of the element or null if conversion is not supported.

See DurationConverter.toNullableDuration

Implementation

Duration? getAsNullableDuration(String key) {
  var value = get(key);
  return DurationConverter.toNullableDuration(value);
}