ObsBuilder class

Inheritance
Available extensions

Constructors

ObsBuilder({Key? key, bool? ignoreObs, List<Listenable>? listenables, required WidgetBuilder builder})
响应式变量构建器,当任何一个响应式变量发生变化时,都会自动重建小部件
const

Properties

builder WidgetBuilder
构建小部件函数,它会自动收集内部的响应式变量
final
hashCode int
The hash code for this object.
no setterinherited
ignoreObs bool?
忽略 builder 内部的 Obs,若为 true,将不会自动收集依赖
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
listenables List<Listenable>?
手动绑定监听的响应式变量,此数组用于监听实现 Listenable 接口的对象, 如果指定 Obs 变量,请设置 ignoreObs 避免重复绑定监听函数。
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

createElement() Element
Inflates this configuration to a concrete instance.
override
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
noScrollbarBehavior(BuildContext context, {Key? key, bool? overscroll, bool enabled = true}) Widget

Available on Widget, provided by the FlutterWidgetExt extension

不使用祖先提供的默认滚动条,当使用自定义滚动条时请添加此扩展方法,防止与祖先提供的默认滚动条重叠
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, int wrapWidth = 65}) 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