BuildContext相比于Element,少了这些方法

BuildContext Element
debugDoingBuild → bool debugIsDefunct → bool
owner → BuildOwner? depth → int
size → Size? dirty → bool
widget → Widget hashCode → int
owner → BuildOwner?
renderObject → RenderObject?
size → Size?
slot → Object?
widget → Widget
dependOnInheritedElement(InheritedElement ancestor, {Object aspect}) → InheritedWidget activate() → void
dependOnInheritedWidgetOfExactType({Object? aspect}) → T? attachRenderObject(Object? newSlot) → void
describeElement(String name, {DiagnosticsTreeStyle style = DiagnosticsTreeStyle.errorProperty}) → DiagnosticsNode deactivate() → void
describeMissingAncestor({required Type expectedAncestorType}) → List deactivateChild(Element child) → void
describeOwnershipChain(String name) → DiagnosticsNode debugDeactivated() → void
describeWidget(String name, {DiagnosticsTreeStyle style = DiagnosticsTreeStyle.errorProperty}) → DiagnosticsNode debugDescribeChildren() → List
findAncestorRenderObjectOfType() → T? debugFillProperties(DiagnosticPropertiesBuilder properties) → void
findAncestorStateOfType>() → T? debugGetCreatorChain(int limit) → String
findAncestorWidgetOfExactType() → T? debugGetDiagnosticChain() → List
findRenderObject() → RenderObject? debugVisitOnstageChildren(ElementVisitor visitor) → void
findRootAncestorStateOfType>() → T? dependOnInheritedElement(InheritedElement ancestor, {Object? aspect}) → InheritedWidget
getElementForInheritedWidgetOfExactType() → InheritedElement? dependOnInheritedWidgetOfExactType({Object? aspect}) → T?
visitAncestorElements(bool visitor(Element element)) → void describeElement(String name, {DiagnosticsTreeStyle style = DiagnosticsTreeStyle.errorProperty}) → DiagnosticsNode
visitChildElements(ElementVisitor visitor) → void describeMissingAncestor({required Type expectedAncestorType}) → List
describeOwnershipChain(String name) → DiagnosticsNode
describeWidget(String name, {DiagnosticsTreeStyle style = DiagnosticsTreeStyle.errorProperty}) → DiagnosticsNode
detachRenderObject() → void
didChangeDependencies() → void
findAncestorRenderObjectOfType() → T?
findAncestorStateOfType>() → T?
findAncestorWidgetOfExactType() → T?
findRenderObject() → RenderObject?
findRootAncestorStateOfType>() → T?
forgetChild(Element child) → void
getElementForInheritedWidgetOfExactType() → InheritedElement?
inflateWidget(Widget newWidget, Object? newSlot) → Element
markNeedsBuild() → void
mount(Element? parent, Object? newSlot) → void
performRebuild() → void
reassemble() → void
rebuild() → void
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode
toStringShort() → String
unmount() → void
update(covariant Widget newWidget) → void
updateChild(Element? child, Widget? newWidget, Object? newSlot) → Element?
updateSlotForChild(Element child, Object? newSlot) → void
visitAncestorElements(bool visitor(Element element)) → void
visitChildElements(ElementVisitor visitor) → void
visitChildren(ElementVisitor visitor) → void
operator ==(Object other) → bool
describeElements(String name, Iterable elements) → DiagnosticsNode

你可能感兴趣的:(BuildContext相比于Element,少了这些方法)