RenderPadding constructor Null safety

RenderPadding(
  1. {required EdgeInsetsGeometry padding,
  2. TextDirection? textDirection,
  3. RenderBox? child}
)

Creates a render object that insets its child.

The padding argument must not be null and must have non-negative insets.

Implementation

RenderPadding({
  required EdgeInsetsGeometry padding,
  TextDirection? textDirection,
  RenderBox? child,
}) : assert(padding != null),
     assert(padding.isNonNegative),
     _textDirection = textDirection,
     _padding = padding,
     super(child);