You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<divclass="member-signature"><spanclass="modifiers">static</span> <spanclass="return-type">boolean</span> <spanclass="element-name"><ahref="../../src-html/arez/component/ComponentObservable.html#line-31">observe</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</span></div>
149
-
<divclass="block">Invoke <ahref="#observe()"><code>observe()</code></a> on the supplied object if any.
150
-
If a null object is passed into this method then it will return true.
151
-
If an object that is not an instance of <ahref="ComponentObservable.html" title="interface in arez.component"><code>ComponentObservable</code></a> is passed into this method then it will return true.</div>
148
+
<divclass="member-signature"><spanclass="modifiers">static</span> <spanclass="return-type">boolean</span> <spanclass="element-name"><ahref="../../src-html/arez/component/ComponentObservable.html#line-29">observe</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</span></div>
149
+
<divclass="block">Invoke <ahref="#observe()"><code>observe()</code></a> on the supplied object if any.</div>
152
150
<dlclass="notes">
153
151
<dt>Parameters:</dt>
154
152
<dd><code>object</code> - the object to observe if any.</dd>
<divclass="member-signature"><spanclass="modifiers">static</span> <spanclass="return-type">boolean</span> <spanclass="element-name"><ahref="../../src-html/arez/component/ComponentObservable.html#line-42">notObserved</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</span></div>
161
+
<divclass="member-signature"><spanclass="modifiers">static</span> <spanclass="return-type">boolean</span> <spanclass="element-name"><ahref="../../src-html/arez/component/ComponentObservable.html#line-40">notObserved</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</span></div>
164
162
<divclass="block">Return true if <ahref="#observe(java.lang.Object)"><code>observe(Object)</code></a> returns false for the same parameter.</div>
<divclass="member-signature"><spanclass="annotations">@Nonnull </span><spanclass="modifiers">static</span> <spanclass="return-type"><ahref="ComponentObservable.html" title="interface in arez.component">ComponentObservable</a></span> <spanclass="element-name"><ahref="../../src-html/arez/component/ComponentObservable.html#line-54">asComponentObservable</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</span></div>
174
+
<divclass="member-signature"><spanclass="annotations">@Nonnull </span><spanclass="modifiers">static</span> <spanclass="return-type"><ahref="ComponentObservable.html" title="interface in arez.component">ComponentObservable</a></span> <spanclass="element-name"><ahref="../../src-html/arez/component/ComponentObservable.html#line-52">asComponentObservable</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</span></div>
177
175
<divclass="block">Cast specified object to an instance of ComponentObservable.
178
176
Invariant checks will verify that the cast is valid before proceeding.</div>
<divclass="member-signature"><spanclass="modifiers">default</span> <spanclass="return-type">void</span> <spanclass="element-name"><ahref="../../src-html/arez/component/DisposeNotifier.html#line-49">addOnDisposeListener</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> key,
166
+
@Nonnull <ahref="../SafeProcedure.html" title="interface in arez">SafeProcedure</a> action)</span></div>
167
+
<divclass="block">Add the listener to the notify list under key.
168
+
This method MUST NOT be invoked after the component has been disposed.
169
+
This method should not be invoked if another listener has been added with the same key without
170
+
being removed.
171
+
172
+
<p>If the key implements <ahref="../Disposable.html" title="interface in arez"><code>Disposable</code></a> and <ahref="../Disposable.html#isDisposed()"><code>Disposable.isDisposed()</code></a> returns <code>true</code>
173
+
when invoking the calback then the callback will be skipped. This rare situation only occurs when there is
174
+
circular dependency in the object model usually involving <ahref="../annotations/CascadeDispose.html" title="annotation interface in arez.annotations"><code>CascadeDispose</code></a>.</p></div>
175
+
<dlclass="notes">
176
+
<dt>Parameters:</dt>
177
+
<dd><code>key</code> - the key to uniquely identify listener.</dd>
178
+
<dd><code>action</code> - the listener callback.</dd>
<divclass="member-signature"><spanclass="return-type">void</span> <spanclass="element-name"><ahref="../../src-html/arez/component/DisposeNotifier.html#line-45">removeOnDisposeListener</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> key,
185
+
<divclass="member-signature"><spanclass="return-type">void</span> <spanclass="element-name"><ahref="../../src-html/arez/component/DisposeNotifier.html#line-63">removeOnDisposeListener</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> key,
155
186
boolean errorIfMissing)</span></div>
156
187
<divclass="block">Remove the listener with the specified key from the notify list.
157
188
This method should only be invoked when a listener has been added for specific key using
<divclass="member-signature"><spanclass="modifiers">default</span> <spanclass="return-type">void</span> <spanclass="element-name"><ahref="../../src-html/arez/component/DisposeNotifier.html#line-73">removeOnDisposeListener</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> key)</span></div>
202
+
<divclass="block">Remove the listener with the specified key from the notify list.
203
+
This method should only be invoked when a listener has been added for specific key using
204
+
<ahref="#addOnDisposeListener(java.lang.Object,arez.SafeProcedure,boolean)"><code>addOnDisposeListener(Object, SafeProcedure, boolean)</code></a> and has not been removed by another
205
+
call to this method.</div>
206
+
<dlclass="notes">
207
+
<dt>Parameters:</dt>
208
+
<dd><code>key</code> - the key under which the listener was previously added.</dd>
<divclass="member-signature"><spanclass="annotations">@Nonnull </span><spanclass="modifiers">static</span> <spanclass="return-type"><ahref="DisposeNotifier.html" title="interface in arez.component">DisposeNotifier</a></span> <spanclass="element-name"><ahref="../../src-html/arez/component/DisposeNotifier.html#line-54">asDisposeNotifier</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</span></div>
215
+
<divclass="member-signature"><spanclass="annotations">@Nonnull </span><spanclass="modifiers">static</span> <spanclass="return-type"><ahref="DisposeNotifier.html" title="interface in arez.component">DisposeNotifier</a></span> <spanclass="element-name"><ahref="../../src-html/arez/component/DisposeNotifier.html#line-85">asDisposeNotifier</a></span><wbr><spanclass="parameters">(@Nonnull <ahref="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class or interface in java.lang" class="external-link">Object</a> object)</span></div>
171
216
<divclass="block">Cast the specified object to an instance of DisposeNotifier.
172
217
Invariant checks will verify that the cast is valid before proceeding.</div>
<divclass="block">Add error handler to the list of error handlers called.</div>
148
148
</dd>
149
+
<dt><ahref="arez/component/DisposeNotifier.html#addOnDisposeListener(java.lang.Object,arez.SafeProcedure)" class="member-name-link">addOnDisposeListener(Object, SafeProcedure)</a> - Method in interface arez.component.<ahref="arez/component/DisposeNotifier.html" title="interface in arez.component">DisposeNotifier</a></dt>
150
+
<dd>
151
+
<divclass="block">Add the listener to the notify list under key.</div>
152
+
</dd>
149
153
<dt><ahref="arez/component/internal/ComponentKernel.html#addOnDisposeListener(java.lang.Object,arez.SafeProcedure)" class="member-name-link">addOnDisposeListener(Object, SafeProcedure)</a> - Method in class arez.component.internal.<ahref="arez/component/internal/ComponentKernel.html" title="class in arez.component.internal">ComponentKernel</a></dt>
<divclass="block">Remove error handler from list of existing error handlers.</div>
2595
2599
</dd>
2600
+
<dt><ahref="arez/component/DisposeNotifier.html#removeOnDisposeListener(java.lang.Object)" class="member-name-link">removeOnDisposeListener(Object)</a> - Method in interface arez.component.<ahref="arez/component/DisposeNotifier.html" title="interface in arez.component">DisposeNotifier</a></dt>
2601
+
<dd>
2602
+
<divclass="block">Remove the listener with the specified key from the notify list.</div>
2603
+
</dd>
2596
2604
<dt><ahref="arez/component/internal/ComponentKernel.html#removeOnDisposeListener(java.lang.Object)" class="member-name-link">removeOnDisposeListener(Object)</a> - Method in class arez.component.internal.<ahref="arez/component/internal/ComponentKernel.html" title="class in arez.component.internal">ComponentKernel</a></dt>
0 commit comments