FluxUiComponent2<TProps extends FluxUiProps> class
abstract
Builds on top of UiComponent2, adding w_flux integration, much like the FluxComponent
in w_flux.
- Flux components are responsible for rendering application views and turning
user interactions and events into
Action
s. - Flux components can use data from one or many
Store
instances to define the resulting component.
Use with the over_react builder via the @Component2()
(annotations.Component2) annotation.
Related: FluxUiStatefulComponent2
- Inheritance
-
- Object
- Component2
- UiComponent2<
TProps> - FluxUiComponent2
- Implementers
Constructors
Properties
-
$defaultConsumedProps
→ Iterable<
ConsumedProps> -
The default consumed props, taken from the keys generated in the associated UiProps class.
no setterinherited
- $isClassGenerated → bool
-
Whether this class has been generated.
no setterinherited
-
childContextKeys
→ Iterable<
String> -
Do not use.
no setterinherited
-
consumedProps
→ Iterable<
ConsumedProps> ? -
The sets of props that should be considered "consumed" by this component, and thus
omitted when forwarding props and validated in propTypes.
no setterinherited
- context ↔ dynamic
-
The context value from the
contextType
assigned to this component. The value is passed down from the provider of the samecontextType
. You can referencecontext
in any of the lifecycle methods including the render function.getter/setter pairinherited -
contextKeys
→ Iterable<
String> -
Do not use.
no setterinherited
- contextType → Context?
-
The contextType property lets you consume the nearest current value of that context's Provider using context.
no setterinherited
- defaultProps → Map
-
Invoked once and cached when
registerComponent
is called. Values in the mapping will be set onprops
if that prop is not specified by the parent component.no setterinherited - displayName → String?
-
Allows the ReactJS
displayName
property to be set for debugging purposes.no setterinherited - hashCode → int
-
The hash code for this object.
no setterinherited
- initialState → Map
-
Invoked once before the
Component
is mounted. The return value will be used as the initial value ofstate
.no setterinherited - jsThis ↔ ReactComponent
-
The JavaScript
ReactComponent
instance of thisComponent
returned byrender
.getter/setter pairinherited - nextContext ↔ Map?
-
Do not use.
getter/setter pairinherited
- nextProps ↔ Map
-
Do not use.
getter/setter pairinherited
- nextState → Map
-
Do not use.
no setterinherited
- prevContext ↔ Map?
-
Do not use.
getter/setter pairinherited
- prevState ↔ Map
-
Do not use.
getter/setter pairinherited
- props ↔ TProps
-
A typed view into the component's current JS props object.
getter/setter pairinherited
- propsMeta → PropsMetaCollection
-
A collection of metadata for the prop fields in all prop mixins used by this component's
generated props class.
no setterinherited
-
propTypes
→ Map<
String, PropValidator< TProps> > -
Allows usage of
react.PropValidator
functions to check the validity of a prop within the props passed to it.no setterinherited - ref ↔ RefMethod
-
Do not use.
getter/setter pairinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
setStateCallbacks
→ List<
SetStateCallback> -
Do not use.
no setterinherited
- shouldBatchRedraw ↔ bool
-
getter/setter pairinherited
- state ↔ Map
-
ReactJS
Component
state.getter/setter pairinherited -
transactionalSetStateCallbacks
→ List<
StateUpdaterCallback> -
The List of transactional
setState
callbacks to be called before the component updates.no setterinherited - unwrappedProps ↔ Map
-
Deprecated; do not use. Will be removed alongside UiComponent.
getter/setter pairinherited
Methods
-
addSubscription(
StreamSubscription subscription) → void -
Register a
subscription
that should be canceled when the component unmounts.inherited -
addUnconsumedDomProps(
Map props) → void -
A prop modifier that passes a reference of a component's
props
to be updated with any unconsumedDomProps
.inherited -
addUnconsumedProps(
Map props) → void -
A prop modifier that passes a reference of a component's
props
to be updated with any unconsumed props.inherited -
awaitBeforeDispose<
T> (Future< T> future) → Future<T> -
Add
future
to a list of futures that will be awaited before the object is disposed.inherited -
componentDidCatch(
dynamic error, ReactErrorInfo info) → void -
ReactJS lifecycle method that is invoked after an
error
is thrown by a descendant.inherited -
componentDidMount(
) → void -
ReactJS lifecycle method that is invoked once, only on the client (not on the server), immediately after the
initial rendering occurs.
override
-
componentDidUpdate(
Map prevProps, Map prevState, [dynamic snapshot]) → void -
ReactJS lifecycle method that is invoked immediately after the
Component
's updates are flushed to the DOM.inherited -
componentWillMount(
) → void -
ReactJS lifecycle method that is invoked once immediately before the initial rendering occurs.
inherited
-
componentWillReceiveProps(
Map nextProps) → void -
ReactJS lifecycle method that is invoked when a
Component
is receiving new props (nextProps
).inherited -
componentWillReceivePropsWithContext(
Map newProps, dynamic nextContext) → void -
Do not use; this is part of the legacy context API.
inherited
-
componentWillUnmount(
) → void -
ReactJS lifecycle method that is invoked immediately before a
Component
is unmounted from the DOM.inherited -
componentWillUpdate(
Map nextProps, Map nextState) → void -
ReactJS lifecycle method that is invoked when a
Component
is receiving new props (nextProps
) and/or state (nextState
).inherited -
componentWillUpdateWithContext(
Map nextProps, Map nextState, dynamic nextContext) → void -
Do not use; this is part of the legacy context API.
inherited
-
copyProps(
{bool omitReservedReactProps = true, bool onlyCopyDomProps = false, Iterable? keysToOmit, Iterable< Iterable> ? keySetsToOmit}) → Map -
Returns a copy of this component's props with React props optionally omitted, and
with the specified
keysToOmit
andkeySetsToOmit
omitted.inherited -
copyUnconsumedDomProps(
) → Map -
Returns a copy of this component's props with keys found in consumedProps and non-DOM props omitted.
inherited
-
copyUnconsumedProps(
) → Map -
Returns a copy of this component's props with keys found in consumedProps omitted.
inherited
-
forceUpdate(
[SetStateCallback? callback]) → void -
Causes
render
to be called, skippingshouldComponentUpdate
.inherited -
forwardingClassNameBuilder(
) → ClassNameBuilder -
Returns a ClassNameBuilder with className and blacklist values added from CssClassPropsMixin.className and
CssClassPropsMixin.classNameBlacklist, if they are specified.
inherited
-
getChildContext(
) → Map< String, dynamic> -
Do not use; this is part of the legacy context API.
inherited
-
getDefaultProps(
) → Map -
Invoked once and cached when
registerComponent
is called. Values in the mapping will be set onprops
if that prop is not specified by the parent component.inherited -
getDerivedStateFromError(
dynamic error) → Map? -
ReactJS lifecycle method that is invoked after an
error
is thrown by a descendant.inherited -
getDerivedStateFromProps(
Map nextProps, Map prevState) → Map? -
ReactJS lifecycle method that is invoked before rendering when new props (
nextProps
) are received.inherited -
getInitialState(
) → Map -
Invoked once before the
Component
is mounted. The return value will be used as the initial value ofstate
.inherited -
getManagedDelayedFuture<
T> (Duration duration, T callback()) → Future< T> -
Creates a Future that will complete, with the value
returned by
callback
, after the given amount of time has elapsed.inherited -
getManagedDisposer(
Disposer disposer) → ManagedDisposer -
Automatically handle arbitrary disposals using a callback.
inherited
-
getManagedPeriodicTimer(
Duration duration, void callback(Timer timer)) → Timer -
Creates a periodic Timer that will be cancelled if active
upon disposal.
inherited
-
getManagedTimer(
Duration duration, void callback()) → Timer -
Creates a Timer instance that will be cancelled if active
upon disposal.
inherited
-
getPropKey(
void accessProp(TProps props)) → String? -
Returns the string key of the
factory
prop accessed inaccessProp
, including the namespace if one exists.inherited -
getSnapshotBeforeUpdate(
Map prevProps, Map prevState) → dynamic -
ReactJS lifecycle method that is invoked immediately after re-rendering
when new props and/or state values are committed.
inherited
-
getStoreHandlers(
) → Map< Store, StoreHandler> -
If you need more fine-grained control over store trigger handling,
override this method to return a Map of stores to handlers.
inherited
-
handleRedrawOn(
Store store) → void -
Redraws the component for a given
store
.inherited -
initComponentInternal(
Map props, void _jsRedraw(), [RefMethod? ref, dynamic _jsThis, Map? context]) → dynamic -
Do not use.
inherited
-
initStateInternal(
) → dynamic -
Do not use.
inherited
-
keyForProp(
void accessProp(TProps props)) → String -
Returns the string key of the
factory
prop accessed inaccessProp
, including the namespace if one exists.inherited -
listenToStoreForRedraw(
Store store) → void -
Used to register
handleRedrawOn
as a listener for the givenstore
.inherited -
listenToStream<
T> (Stream< T> stream, void onData(T event), {Function? onError, void onDone()?, bool? cancelOnError}) → StreamSubscription<T> -
Returns a StreamSubscription which handles events from the stream using
the provided
onData
,onError
andonDone
handlers.inherited -
manageAndReturnDisposable(
Disposable disposable) → Disposable -
inherited
-
manageAndReturnTypedDisposable<
T extends Disposable> (T disposable) → T -
Automatically dispose another object when this object is disposed.
inherited
-
manageCompleter<
T> (Completer< T> completer) → Completer<T> -
Ensure that a completer is completed when the object is disposed.
inherited
-
manageDisposable(
Disposable disposable) → void -
inherited
-
manageDisposer(
Disposer disposer) → void -
DEPRECATED. Use
getManagedDisposer
instead.inherited -
manageStreamController(
StreamController controller) → void -
Automatically cancel a stream controller when this object is disposed.
inherited
-
manageStreamSubscription(
StreamSubscription subscription) → void -
DEPRECATED. Use
listenToStream
instead.inherited -
newProps(
) → TProps -
Returns a typed props object backed by a Map.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
redraw(
[dynamic callback()?]) → void -
inherited
-
redrawOn(
) → List< Store> -
Define the list of
Store
instances that this component should listen to.inherited -
render(
) → dynamic -
Examines
props
andstate
and returns a ReactNode.inherited -
replaceState(
Map? newState, [SetStateCallback? callback]) → void -
Do not use.
inherited
-
setState(
covariant Map? newState, [SetStateCallback? callback]) → void -
Triggers a rerender with new state obtained by shallow-merging
newState
into the currentstate
.inherited -
setStateWithUpdater(
StateUpdaterCallback updater, [SetStateCallback? callback]) → void -
Triggers a rerender with new state obtained by shallow-merging
the return value of
updater
into the currentstate
.inherited -
shouldComponentUpdate(
Map nextProps, Map nextState) → bool -
ReactJS lifecycle method that is invoked before rendering when
nextProps
and/ornextState
are being received.inherited -
shouldComponentUpdateWithContext(
Map nextProps, Map nextState, dynamic nextContext) → bool -
Do not use; this is part of the legacy context API.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
transferComponentState(
) → void -
Do not use.
inherited
-
typedPropsFactory(
Map propsMap) → TProps -
Returns a typed props object backed by the specified
propsMap
.inherited -
typedPropsFactoryJs(
JsBackedMap propsMap) → TProps -
Returns a typed props object backed by the specified
propsMap
.inherited -
validateProps(
Map appliedProps) → void -
Throws a PropError if
appliedProps
are invalid.inherited -
validateRequiredProps(
Map appliedProps) → void -
Validates that props with the
@requiredProp
annotation are present. Deprecated. Will be removed in the4.0.0
release.inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited