Value class
Value
Rebuild the widget when the node is changed.
path
is the path of the node. If the node does not exist, pass null to builder().
path
는 노드의 경로이다. 만약 해당 노드가 존재하지 않으면 null 을 builder() 로 전달한다.
ref is the reference of the node. If the node does not exist, pass null to builder().
builder is the widget builder.
initialData is the initial data to show when waiting for the data. This is useful to prevent the screen flickering.
onLoading is the widget to show when waiting for the data.
Example: below will get the snapshot of /path/to/node
Value(path: 'path/to/node', builder: (value) {
return Text(value);
});
- Inheritance
Constructors
Properties
- builder → Widget Function(dynamic value)
-
dynamic
is the value of the node. String is the path of the node.final - hashCode → int
-
The hash code for this object.
no setterinherited
- initialData → dynamic
-
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- onLoading → Widget?
-
final
- ref → DatabaseReference?
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
build(
BuildContext context) → Widget -
Describes the part of the user interface represented by this widget.
override
-
createElement(
) → StatelessElement -
Creates a StatelessElement to manage this widget's location in the tree.
inherited
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of
DiagnosticsNode
objects describing this node's children.inherited -
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited