EmptyableContentBuilder<T> constructor
EmptyableContentBuilder<T> ({
- Key? key,
- required T? content,
- EmptyChecker<
T> ? emptyChecker, - WidgetBuilder? emptyBuilder,
- required ValueResultBuilder<
T> builder,
Create the widget
emptyChecker
- Function used to determine whether content
is blank or not
If not given, defaultEmptyChecker is used
emptyBuilder
- Builder being used when content
is blank
If not given, defaultEmptyBuilder
is used.
builder
- Builder being used when content
is not blank.
The content
passed to builder
will never been null
.
Implementation
EmptyableContentBuilder({
Key? key,
required this.content,
EmptyChecker<T>? emptyChecker,
this.emptyBuilder,
required this.builder,
}) : this.emptyChecker = emptyChecker ?? defaultEmptyChecker,
super(key: key);