allOrNull<T> static method

MaterialStateProperty<T>? allOrNull<T>(
  1. T? value
)

Returns null if value is null, otherwise MaterialStateProperty.all<T>(value).

A convenience method for subclasses.

Implementation

static MaterialStateProperty<T>? allOrNull<T>(T? value) =>
    value == null ? null : MaterialStateProperty.all<T>(value);