Package arez
Class Component
java.lang.Object
arez.Component
- All Implemented Interfaces:
Disposable
@OmitType(unless="arez.enable_native_components")
public final class Component
extends Object
implements Disposable
The component is an abstraction representation of a reactive component within Arez.
Each component is made up of one or more of the core Arez reactive elements:
ObservableValue
s,
Observer
s or ComputableValue
s.-
Method Summary
Modifier and TypeMethodDescriptionvoid
complete()
The toolkit user should call this method when the component is complete.void
dispose()
Dispose the element.getId()
Return the unique id of the component.getName()
Return the unique name of the component.getType()
Return the component type.boolean
Return true if the creation of this component is complete.boolean
Return true if dispose() has been called on object.toString()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface arez.Disposable
isNotDisposed
-
Method Details
-
getType
Return the component type. This is an opaque string specified by the user.- Returns:
- the component type.
-
getId
Return the unique id of the component. This will return null for singletons.- Returns:
- the unique id of the component.
-
getName
Return the unique name of the component.- Returns:
- the name of the component.
-
dispose
Description copied from interface:Disposable
Dispose the element. SeeDisposable
for a description of the implications.- Specified by:
dispose
in interfaceDisposable
-
isDisposed
Description copied from interface:Disposable
Return true if dispose() has been called on object.- Specified by:
isDisposed
in interfaceDisposable
- Returns:
- true if dispose has been called.
-
toString
-
isComplete
Return true if the creation of this component is complete.- Returns:
- true if the creation of this component is complete, false otherwise.
-
complete
The toolkit user should call this method when the component is complete. After this method has been invoked the user should not attempt to define any moreObservableValue
s,Observer
s orComputableValue
s on the component.
-