<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <!-- NewPage --> <html lang="en"> <head> <!-- Generated by javadoc (1.8.0_191) on Wed Oct 31 14:02:24 UTC 2018 --> <title>Observable (JavaFX 8)</title> <meta name="date" content="2018-10-31"> <link rel="stylesheet" type="text/css" href="../../stylesheet.css" title="Style"> <script type="text/javascript" src="../../script.js"></script> </head> <body> <script type="text/javascript"><!-- try { if (location.href.indexOf('is-external=true') == -1) { parent.document.title="Observable (JavaFX 8)"; } } catch(err) { } //--> var methods = {"i0":6,"i1":6}; var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"]}; var altColor = "altColor"; var rowColor = "rowColor"; var tableTab = "tableTab"; var activeTableTab = "activeTableTab"; </script> <noscript> <div>JavaScript is disabled on your browser.</div> </noscript> <!-- ========= START OF TOP NAVBAR ======= --> <div class="topNav"><a name="navbar.top"> <!-- --> </a> <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> <a name="navbar.top.firstrow"> <!-- --> </a> <ul class="navList" title="Navigation"> <li><a href="../../overview-summary.html">Overview</a></li> <li><a href="package-summary.html">Package</a></li> <li class="navBarCell1Rev">Class</li> <li><a href="class-use/Observable.html">Use</a></li> <li><a href="package-tree.html">Tree</a></li> <li><a href="../../deprecated-list.html">Deprecated</a></li> <li><a href="../../index-all.html">Index</a></li> <li><a href="../../help-doc.html">Help</a></li> </ul> <div class="aboutLanguage">JavaFX 8</div> </div> <div class="subNav"> <ul class="navList"> <li><a href="../../javafx/beans/NamedArg.html" title="annotation in javafx.beans"><span class="typeNameLink">Prev Class</span></a></li> <li><a href="../../javafx/beans/WeakInvalidationListener.html" title="class in javafx.beans"><span class="typeNameLink">Next Class</span></a></li> </ul> <ul class="navList"> <li><a href="../../index.html?javafx/beans/Observable.html" target="_top">Frames</a></li> <li><a href="Observable.html" target="_top">No Frames</a></li> </ul> <ul class="navList" id="allclasses_navbar_top"> <li><a href="../../allclasses-noframe.html">All Classes</a></li> </ul> <div> <script type="text/javascript"><!-- allClassesLink = document.getElementById("allclasses_navbar_top"); if(window==top) { allClassesLink.style.display = "block"; } else { allClassesLink.style.display = "none"; } //--> </script> </div> <div> <ul class="subNavList"> <li>Summary: </li> <li>Nested | </li> <li>Field | </li> <li>Constr | </li> <li><a href="#method.summary">Method</a></li> </ul> <ul class="subNavList"> <li>Detail: </li> <li>Field | </li> <li>Constr | </li> <li><a href="#method.detail">Method</a></li> </ul> </div> <a name="skip.navbar.top"> <!-- --> </a></div> <!-- ========= END OF TOP NAVBAR ========= --> <!-- ======== START OF CLASS DATA ======== --> <div class="header"> <div class="subTitle">javafx.beans</div> <h2 title="Interface Observable" class="title">Interface Observable</h2> </div> <div class="contentContainer"> <div class="description"> <ul class="blockList"> <li class="blockList"> <dl> <dt>All Known Subinterfaces:</dt> <dd><a href="../../javafx/beans/binding/Binding.html" title="interface in javafx.beans.binding">Binding</a><T>, <a href="../../javafx/beans/property/adapter/JavaBeanProperty.html" title="interface in javafx.beans.property.adapter">JavaBeanProperty</a><T>, <a href="../../javafx/beans/binding/NumberBinding.html" title="interface in javafx.beans.binding">NumberBinding</a>, <a href="../../javafx/beans/binding/NumberExpression.html" title="interface in javafx.beans.binding">NumberExpression</a>, <a href="../../javafx/collections/ObservableArray.html" title="interface in javafx.collections">ObservableArray</a><T>, <a href="../../javafx/beans/value/ObservableBooleanValue.html" title="interface in javafx.beans.value">ObservableBooleanValue</a>, <a href="../../javafx/beans/value/ObservableDoubleValue.html" title="interface in javafx.beans.value">ObservableDoubleValue</a>, <a href="../../javafx/scene/shape/ObservableFaceArray.html" title="interface in javafx.scene.shape">ObservableFaceArray</a>, <a href="../../javafx/collections/ObservableFloatArray.html" title="interface in javafx.collections">ObservableFloatArray</a>, <a href="../../javafx/beans/value/ObservableFloatValue.html" title="interface in javafx.beans.value">ObservableFloatValue</a>, <a href="../../javafx/collections/ObservableIntegerArray.html" title="interface in javafx.collections">ObservableIntegerArray</a>, <a href="../../javafx/beans/value/ObservableIntegerValue.html" title="interface in javafx.beans.value">ObservableIntegerValue</a>, <a href="../../javafx/collections/ObservableList.html" title="interface in javafx.collections">ObservableList</a><E>, <a href="../../javafx/beans/value/ObservableListValue.html" title="interface in javafx.beans.value">ObservableListValue</a><E>, <a href="../../javafx/beans/value/ObservableLongValue.html" title="interface in javafx.beans.value">ObservableLongValue</a>, <a href="../../javafx/collections/ObservableMap.html" title="interface in javafx.collections">ObservableMap</a><K,V>, <a href="../../javafx/beans/value/ObservableMapValue.html" title="interface in javafx.beans.value">ObservableMapValue</a><K,V>, <a href="../../javafx/beans/value/ObservableNumberValue.html" title="interface in javafx.beans.value">ObservableNumberValue</a>, <a href="../../javafx/beans/value/ObservableObjectValue.html" title="interface in javafx.beans.value">ObservableObjectValue</a><T>, <a href="../../javafx/collections/ObservableSet.html" title="interface in javafx.collections">ObservableSet</a><E>, <a href="../../javafx/beans/value/ObservableSetValue.html" title="interface in javafx.beans.value">ObservableSetValue</a><E>, <a href="../../javafx/beans/value/ObservableStringValue.html" title="interface in javafx.beans.value">ObservableStringValue</a>, <a href="../../javafx/beans/value/ObservableValue.html" title="interface in javafx.beans.value">ObservableValue</a><T>, <a href="../../javafx/beans/property/Property.html" title="interface in javafx.beans.property">Property</a><T>, <a href="../../javafx/beans/property/adapter/ReadOnlyJavaBeanProperty.html" title="interface in javafx.beans.property.adapter">ReadOnlyJavaBeanProperty</a><T>, <a href="../../javafx/beans/property/ReadOnlyProperty.html" title="interface in javafx.beans.property">ReadOnlyProperty</a><T>, <a href="../../javafx/scene/control/TextInputControl.Content.html" title="interface in javafx.scene.control">TextInputControl.Content</a>, <a href="../../javafx/beans/value/WritableListValue.html" title="interface in javafx.beans.value">WritableListValue</a><E>, <a href="../../javafx/beans/value/WritableMapValue.html" title="interface in javafx.beans.value">WritableMapValue</a><K,V>, <a href="../../javafx/beans/value/WritableSetValue.html" title="interface in javafx.beans.value">WritableSetValue</a><E></dd> </dl> <dl> <dt>All Known Implementing Classes:</dt> <dd><a href="../../javafx/beans/binding/BooleanBinding.html" title="class in javafx.beans.binding">BooleanBinding</a>, <a href="../../javafx/beans/binding/BooleanExpression.html" title="class in javafx.beans.binding">BooleanExpression</a>, <a href="../../javafx/beans/property/BooleanProperty.html" title="class in javafx.beans.property">BooleanProperty</a>, <a href="../../javafx/beans/property/BooleanPropertyBase.html" title="class in javafx.beans.property">BooleanPropertyBase</a>, <a href="../../javafx/beans/binding/DoubleBinding.html" title="class in javafx.beans.binding">DoubleBinding</a>, <a href="../../javafx/beans/binding/DoubleExpression.html" title="class in javafx.beans.binding">DoubleExpression</a>, <a href="../../javafx/beans/property/DoubleProperty.html" title="class in javafx.beans.property">DoubleProperty</a>, <a href="../../javafx/beans/property/DoublePropertyBase.html" title="class in javafx.beans.property">DoublePropertyBase</a>, <a href="../../javafx/collections/transformation/FilteredList.html" title="class in javafx.collections.transformation">FilteredList</a>, <a href="../../javafx/beans/binding/FloatBinding.html" title="class in javafx.beans.binding">FloatBinding</a>, <a href="../../javafx/beans/binding/FloatExpression.html" title="class in javafx.beans.binding">FloatExpression</a>, <a href="../../javafx/beans/property/FloatProperty.html" title="class in javafx.beans.property">FloatProperty</a>, <a href="../../javafx/beans/property/FloatPropertyBase.html" title="class in javafx.beans.property">FloatPropertyBase</a>, <a href="../../javafx/beans/binding/IntegerBinding.html" title="class in javafx.beans.binding">IntegerBinding</a>, <a href="../../javafx/beans/binding/IntegerExpression.html" title="class in javafx.beans.binding">IntegerExpression</a>, <a href="../../javafx/beans/property/IntegerProperty.html" title="class in javafx.beans.property">IntegerProperty</a>, <a href="../../javafx/beans/property/IntegerPropertyBase.html" title="class in javafx.beans.property">IntegerPropertyBase</a>, <a href="../../javafx/beans/property/adapter/JavaBeanBooleanProperty.html" title="class in javafx.beans.property.adapter">JavaBeanBooleanProperty</a>, <a href="../../javafx/beans/property/adapter/JavaBeanDoubleProperty.html" title="class in javafx.beans.property.adapter">JavaBeanDoubleProperty</a>, <a href="../../javafx/beans/property/adapter/JavaBeanFloatProperty.html" title="class in javafx.beans.property.adapter">JavaBeanFloatProperty</a>, <a href="../../javafx/beans/property/adapter/JavaBeanIntegerProperty.html" title="class in javafx.beans.property.adapter">JavaBeanIntegerProperty</a>, <a href="../../javafx/beans/property/adapter/JavaBeanLongProperty.html" title="class in javafx.beans.property.adapter">JavaBeanLongProperty</a>, <a href="../../javafx/beans/property/adapter/JavaBeanObjectProperty.html" title="class in javafx.beans.property.adapter">JavaBeanObjectProperty</a>, <a href="../../javafx/beans/property/adapter/JavaBeanStringProperty.html" title="class in javafx.beans.property.adapter">JavaBeanStringProperty</a>, <a href="../../javafx/beans/binding/ListBinding.html" title="class in javafx.beans.binding">ListBinding</a>, <a href="../../javafx/beans/binding/ListExpression.html" title="class in javafx.beans.binding">ListExpression</a>, <a href="../../javafx/beans/property/ListProperty.html" title="class in javafx.beans.property">ListProperty</a>, <a href="../../javafx/beans/property/ListPropertyBase.html" title="class in javafx.beans.property">ListPropertyBase</a>, <a href="../../javafx/beans/binding/LongBinding.html" title="class in javafx.beans.binding">LongBinding</a>, <a href="../../javafx/beans/binding/LongExpression.html" title="class in javafx.beans.binding">LongExpression</a>, <a href="../../javafx/beans/property/LongProperty.html" title="class in javafx.beans.property">LongProperty</a>, <a href="../../javafx/beans/property/LongPropertyBase.html" title="class in javafx.beans.property">LongPropertyBase</a>, <a href="../../javafx/beans/binding/MapBinding.html" title="class in javafx.beans.binding">MapBinding</a>, <a href="../../javafx/beans/binding/MapExpression.html" title="class in javafx.beans.binding">MapExpression</a>, <a href="../../javafx/beans/property/MapProperty.html" title="class in javafx.beans.property">MapProperty</a>, <a href="../../javafx/beans/property/MapPropertyBase.html" title="class in javafx.beans.property">MapPropertyBase</a>, <a href="../../javafx/collections/ModifiableObservableListBase.html" title="class in javafx.collections">ModifiableObservableListBase</a>, <a href="../../javafx/beans/binding/NumberExpressionBase.html" title="class in javafx.beans.binding">NumberExpressionBase</a>, <a href="../../javafx/beans/binding/ObjectBinding.html" title="class in javafx.beans.binding">ObjectBinding</a>, <a href="../../javafx/beans/binding/ObjectExpression.html" title="class in javafx.beans.binding">ObjectExpression</a>, <a href="../../javafx/beans/property/ObjectProperty.html" title="class in javafx.beans.property">ObjectProperty</a>, <a href="../../javafx/beans/property/ObjectPropertyBase.html" title="class in javafx.beans.property">ObjectPropertyBase</a>, <a href="../../javafx/collections/ObservableArrayBase.html" title="class in javafx.collections">ObservableArrayBase</a>, <a href="../../javafx/collections/ObservableListBase.html" title="class in javafx.collections">ObservableListBase</a>, <a href="../../javafx/beans/value/ObservableValueBase.html" title="class in javafx.beans.value">ObservableValueBase</a>, <a href="../../javafx/beans/property/ReadOnlyBooleanProperty.html" title="class in javafx.beans.property">ReadOnlyBooleanProperty</a>, <a href="../../javafx/beans/property/ReadOnlyBooleanPropertyBase.html" title="class in javafx.beans.property">ReadOnlyBooleanPropertyBase</a>, <a href="../../javafx/beans/property/ReadOnlyBooleanWrapper.html" title="class in javafx.beans.property">ReadOnlyBooleanWrapper</a>, <a href="../../javafx/beans/property/ReadOnlyDoubleProperty.html" title="class in javafx.beans.property">ReadOnlyDoubleProperty</a>, <a href="../../javafx/beans/property/ReadOnlyDoublePropertyBase.html" title="class in javafx.beans.property">ReadOnlyDoublePropertyBase</a>, <a href="../../javafx/beans/property/ReadOnlyDoubleWrapper.html" title="class in javafx.beans.property">ReadOnlyDoubleWrapper</a>, <a href="../../javafx/beans/property/ReadOnlyFloatProperty.html" title="class in javafx.beans.property">ReadOnlyFloatProperty</a>, <a href="../../javafx/beans/property/ReadOnlyFloatPropertyBase.html" title="class in javafx.beans.property">ReadOnlyFloatPropertyBase</a>, <a href="../../javafx/beans/property/ReadOnlyFloatWrapper.html" title="class in javafx.beans.property">ReadOnlyFloatWrapper</a>, <a href="../../javafx/beans/property/ReadOnlyIntegerProperty.html" title="class in javafx.beans.property">ReadOnlyIntegerProperty</a>, <a href="../../javafx/beans/property/ReadOnlyIntegerPropertyBase.html" title="class in javafx.beans.property">ReadOnlyIntegerPropertyBase</a>, <a href="../../javafx/beans/property/ReadOnlyIntegerWrapper.html" title="class in javafx.beans.property">ReadOnlyIntegerWrapper</a>, <a href="../../javafx/beans/property/adapter/ReadOnlyJavaBeanBooleanProperty.html" title="class in javafx.beans.property.adapter">ReadOnlyJavaBeanBooleanProperty</a>, <a href="../../javafx/beans/property/adapter/ReadOnlyJavaBeanDoubleProperty.html" title="class in javafx.beans.property.adapter">ReadOnlyJavaBeanDoubleProperty</a>, <a href="../../javafx/beans/property/adapter/ReadOnlyJavaBeanFloatProperty.html" title="class in javafx.beans.property.adapter">ReadOnlyJavaBeanFloatProperty</a>, <a href="../../javafx/beans/property/adapter/ReadOnlyJavaBeanIntegerProperty.html" title="class in javafx.beans.property.adapter">ReadOnlyJavaBeanIntegerProperty</a>, <a href="../../javafx/beans/property/adapter/ReadOnlyJavaBeanLongProperty.html" title="class in javafx.beans.property.adapter">ReadOnlyJavaBeanLongProperty</a>, <a href="../../javafx/beans/property/adapter/ReadOnlyJavaBeanObjectProperty.html" title="class in javafx.beans.property.adapter">ReadOnlyJavaBeanObjectProperty</a>, <a href="../../javafx/beans/property/adapter/ReadOnlyJavaBeanStringProperty.html" title="class in javafx.beans.property.adapter">ReadOnlyJavaBeanStringProperty</a>, <a href="../../javafx/beans/property/ReadOnlyListProperty.html" title="class in javafx.beans.property">ReadOnlyListProperty</a>, <a href="../../javafx/beans/property/ReadOnlyListPropertyBase.html" title="class in javafx.beans.property">ReadOnlyListPropertyBase</a>, <a href="../../javafx/beans/property/ReadOnlyListWrapper.html" title="class in javafx.beans.property">ReadOnlyListWrapper</a>, <a href="../../javafx/beans/property/ReadOnlyLongProperty.html" title="class in javafx.beans.property">ReadOnlyLongProperty</a>, <a href="../../javafx/beans/property/ReadOnlyLongPropertyBase.html" title="class in javafx.beans.property">ReadOnlyLongPropertyBase</a>, <a href="../../javafx/beans/property/ReadOnlyLongWrapper.html" title="class in javafx.beans.property">ReadOnlyLongWrapper</a>, <a href="../../javafx/beans/property/ReadOnlyMapProperty.html" title="class in javafx.beans.property">ReadOnlyMapProperty</a>, <a href="../../javafx/beans/property/ReadOnlyMapPropertyBase.html" title="class in javafx.beans.property">ReadOnlyMapPropertyBase</a>, <a href="../../javafx/beans/property/ReadOnlyMapWrapper.html" title="class in javafx.beans.property">ReadOnlyMapWrapper</a>, <a href="../../javafx/beans/property/ReadOnlyObjectProperty.html" title="class in javafx.beans.property">ReadOnlyObjectProperty</a>, <a href="../../javafx/beans/property/ReadOnlyObjectPropertyBase.html" title="class in javafx.beans.property">ReadOnlyObjectPropertyBase</a>, <a href="../../javafx/beans/property/ReadOnlyObjectWrapper.html" title="class in javafx.beans.property">ReadOnlyObjectWrapper</a>, <a href="../../javafx/beans/property/ReadOnlySetProperty.html" title="class in javafx.beans.property">ReadOnlySetProperty</a>, <a href="../../javafx/beans/property/ReadOnlySetPropertyBase.html" title="class in javafx.beans.property">ReadOnlySetPropertyBase</a>, <a href="../../javafx/beans/property/ReadOnlySetWrapper.html" title="class in javafx.beans.property">ReadOnlySetWrapper</a>, <a href="../../javafx/beans/property/ReadOnlyStringProperty.html" title="class in javafx.beans.property">ReadOnlyStringProperty</a>, <a href="../../javafx/beans/property/ReadOnlyStringPropertyBase.html" title="class in javafx.beans.property">ReadOnlyStringPropertyBase</a>, <a href="../../javafx/beans/property/ReadOnlyStringWrapper.html" title="class in javafx.beans.property">ReadOnlyStringWrapper</a>, <a href="../../javafx/beans/binding/SetBinding.html" title="class in javafx.beans.binding">SetBinding</a>, <a href="../../javafx/beans/binding/SetExpression.html" title="class in javafx.beans.binding">SetExpression</a>, <a href="../../javafx/beans/property/SetProperty.html" title="class in javafx.beans.property">SetProperty</a>, <a href="../../javafx/beans/property/SetPropertyBase.html" title="class in javafx.beans.property">SetPropertyBase</a>, <a href="../../javafx/beans/property/SimpleBooleanProperty.html" title="class in javafx.beans.property">SimpleBooleanProperty</a>, <a href="../../javafx/beans/property/SimpleDoubleProperty.html" title="class in javafx.beans.property">SimpleDoubleProperty</a>, <a href="../../javafx/beans/property/SimpleFloatProperty.html" title="class in javafx.beans.property">SimpleFloatProperty</a>, <a href="../../javafx/beans/property/SimpleIntegerProperty.html" title="class in javafx.beans.property">SimpleIntegerProperty</a>, <a href="../../javafx/beans/property/SimpleListProperty.html" title="class in javafx.beans.property">SimpleListProperty</a>, <a href="../../javafx/beans/property/SimpleLongProperty.html" title="class in javafx.beans.property">SimpleLongProperty</a>, <a href="../../javafx/beans/property/SimpleMapProperty.html" title="class in javafx.beans.property">SimpleMapProperty</a>, <a href="../../javafx/beans/property/SimpleObjectProperty.html" title="class in javafx.beans.property">SimpleObjectProperty</a>, <a href="../../javafx/beans/property/SimpleSetProperty.html" title="class in javafx.beans.property">SimpleSetProperty</a>, <a href="../../javafx/beans/property/SimpleStringProperty.html" title="class in javafx.beans.property">SimpleStringProperty</a>, <a href="../../javafx/css/SimpleStyleableBooleanProperty.html" title="class in javafx.css">SimpleStyleableBooleanProperty</a>, <a href="../../javafx/css/SimpleStyleableDoubleProperty.html" title="class in javafx.css">SimpleStyleableDoubleProperty</a>, <a href="../../javafx/css/SimpleStyleableFloatProperty.html" title="class in javafx.css">SimpleStyleableFloatProperty</a>, <a href="../../javafx/css/SimpleStyleableIntegerProperty.html" title="class in javafx.css">SimpleStyleableIntegerProperty</a>, <a href="../../javafx/css/SimpleStyleableLongProperty.html" title="class in javafx.css">SimpleStyleableLongProperty</a>, <a href="../../javafx/css/SimpleStyleableObjectProperty.html" title="class in javafx.css">SimpleStyleableObjectProperty</a>, <a href="../../javafx/css/SimpleStyleableStringProperty.html" title="class in javafx.css">SimpleStyleableStringProperty</a>, <a href="../../javafx/collections/transformation/SortedList.html" title="class in javafx.collections.transformation">SortedList</a>, <a href="../../javafx/beans/binding/StringBinding.html" title="class in javafx.beans.binding">StringBinding</a>, <a href="../../javafx/beans/binding/StringExpression.html" title="class in javafx.beans.binding">StringExpression</a>, <a href="../../javafx/beans/property/StringProperty.html" title="class in javafx.beans.property">StringProperty</a>, <a href="../../javafx/beans/property/StringPropertyBase.html" title="class in javafx.beans.property">StringPropertyBase</a>, <a href="../../javafx/css/StyleableBooleanProperty.html" title="class in javafx.css">StyleableBooleanProperty</a>, <a href="../../javafx/css/StyleableDoubleProperty.html" title="class in javafx.css">StyleableDoubleProperty</a>, <a href="../../javafx/css/StyleableFloatProperty.html" title="class in javafx.css">StyleableFloatProperty</a>, <a href="../../javafx/css/StyleableIntegerProperty.html" title="class in javafx.css">StyleableIntegerProperty</a>, <a href="../../javafx/css/StyleableLongProperty.html" title="class in javafx.css">StyleableLongProperty</a>, <a href="../../javafx/css/StyleableObjectProperty.html" title="class in javafx.css">StyleableObjectProperty</a>, <a href="../../javafx/css/StyleableStringProperty.html" title="class in javafx.css">StyleableStringProperty</a>, <a href="../../javafx/collections/transformation/TransformationList.html" title="class in javafx.collections.transformation">TransformationList</a></dd> </dl> <hr> <br> <pre>public interface <span class="typeNameLabel">Observable</span></pre> <div class="block">An <code>Observable</code> is an entity that wraps content and allows to observe the content for invalidations. <p> An implementation of <code>Observable</code> may support lazy evaluation, which means that the content is not immediately recomputed after changes, but lazily the next time it is requested. All bindings and properties in this library support lazy evaluation. <p> Implementations of this class should strive to generate as few events as possible to avoid wasting too much time in event handlers. Implementations in this library mark themselves as invalid when the first invalidation event occurs. They do not generate anymore invalidation events until their value is recomputed and valid again.</div> <dl> <dt><span class="simpleTagLabel">Since:</span></dt> <dd>JavaFX 2.0</dd> <dt><span class="seeLabel">See Also:</span></dt> <dd><a href="../../javafx/beans/value/ObservableValue.html" title="interface in javafx.beans.value"><code>ObservableValue</code></a>, <a href="../../javafx/collections/ObservableList.html" title="interface in javafx.collections"><code>ObservableList</code></a>, <a href="../../javafx/collections/ObservableMap.html" title="interface in javafx.collections"><code>ObservableMap</code></a></dd> </dl> </li> </ul> </div> <div class="summary"> <ul class="blockList"> <li class="blockList"> <!-- ========== METHOD SUMMARY =========== --> <ul class="blockList"> <li class="blockList"><a name="method.summary"> <!-- --> </a> <h3>Method Summary</h3> <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Abstract Methods</a></span><span class="tabEnd"> </span></span></caption> <tr> <th class="colFirst" scope="col">Modifier and Type</th> <th class="colLast" scope="col">Method and Description</th> </tr> <tr id="i0" class="altColor"> <td class="colFirst"><code>void</code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../javafx/beans/Observable.html#addListener-javafx.beans.InvalidationListener-">addListener</a></span>(<a href="../../javafx/beans/InvalidationListener.html" title="interface in javafx.beans">InvalidationListener</a> listener)</code> <div class="block">Adds an <a href="../../javafx/beans/InvalidationListener.html" title="interface in javafx.beans"><code>InvalidationListener</code></a> which will be notified whenever the <code>Observable</code> becomes invalid.</div> </td> </tr> <tr id="i1" class="rowColor"> <td class="colFirst"><code>void</code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../javafx/beans/Observable.html#removeListener-javafx.beans.InvalidationListener-">removeListener</a></span>(<a href="../../javafx/beans/InvalidationListener.html" title="interface in javafx.beans">InvalidationListener</a> listener)</code> <div class="block">Removes the given listener from the list of listeners, that are notified whenever the value of the <code>Observable</code> becomes invalid.</div> </td> </tr> </table> </li> </ul> </li> </ul> </div> <div class="details"> <ul class="blockList"> <li class="blockList"> <!-- ============ METHOD DETAIL ========== --> <ul class="blockList"> <li class="blockList"><a name="method.detail"> <!-- --> </a> <h3>Method Detail</h3> <a name="addListener-javafx.beans.InvalidationListener-"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>addListener</h4> <pre>void addListener(<a href="../../javafx/beans/InvalidationListener.html" title="interface in javafx.beans">InvalidationListener</a> listener)</pre> <div class="block">Adds an <a href="../../javafx/beans/InvalidationListener.html" title="interface in javafx.beans"><code>InvalidationListener</code></a> which will be notified whenever the <code>Observable</code> becomes invalid. If the same listener is added more than once, then it will be notified more than once. That is, no check is made to ensure uniqueness. <p> Note that the same actual <code>InvalidationListener</code> instance may be safely registered for different <code>Observables</code>. <p> The <code>Observable</code> stores a strong reference to the listener which will prevent the listener from being garbage collected and may result in a memory leak. It is recommended to either unregister a listener by calling <a href="../../javafx/beans/Observable.html#removeListener-javafx.beans.InvalidationListener-"><code>removeListener</code></a> after use or to use an instance of <a href="../../javafx/beans/WeakInvalidationListener.html" title="class in javafx.beans"><code>WeakInvalidationListener</code></a> avoid this situation.</div> <dl> <dt><span class="paramLabel">Parameters:</span></dt> <dd><code>listener</code> - The listener to register</dd> <dt><span class="throwsLabel">Throws:</span></dt> <dd><code>java.lang.NullPointerException</code> - if the listener is null</dd> <dt><span class="seeLabel">See Also:</span></dt> <dd><a href="../../javafx/beans/Observable.html#removeListener-javafx.beans.InvalidationListener-"><code>removeListener(InvalidationListener)</code></a></dd> </dl> </li> </ul> <a name="removeListener-javafx.beans.InvalidationListener-"> <!-- --> </a> <ul class="blockListLast"> <li class="blockList"> <h4>removeListener</h4> <pre>void removeListener(<a href="../../javafx/beans/InvalidationListener.html" title="interface in javafx.beans">InvalidationListener</a> listener)</pre> <div class="block">Removes the given listener from the list of listeners, that are notified whenever the value of the <code>Observable</code> becomes invalid. <p> If the given listener has not been previously registered (i.e. it was never added) then this method call is a no-op. If it had been previously added then it will be removed. If it had been added more than once, then only the first occurrence will be removed.</div> <dl> <dt><span class="paramLabel">Parameters:</span></dt> <dd><code>listener</code> - The listener to remove</dd> <dt><span class="throwsLabel">Throws:</span></dt> <dd><code>java.lang.NullPointerException</code> - if the listener is null</dd> <dt><span class="seeLabel">See Also:</span></dt> <dd><a href="../../javafx/beans/Observable.html#addListener-javafx.beans.InvalidationListener-"><code>addListener(InvalidationListener)</code></a></dd> </dl> </li> </ul> </li> </ul> </li> </ul> </div> </div> <!-- ========= END OF CLASS DATA ========= --> <!-- ======= START OF BOTTOM NAVBAR ====== --> <div class="bottomNav"><a name="navbar.bottom"> <!-- --> </a> <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> <a name="navbar.bottom.firstrow"> <!-- --> </a> <ul class="navList" title="Navigation"> <li><a href="../../overview-summary.html">Overview</a></li> <li><a href="package-summary.html">Package</a></li> <li class="navBarCell1Rev">Class</li> <li><a href="class-use/Observable.html">Use</a></li> <li><a href="package-tree.html">Tree</a></li> <li><a href="../../deprecated-list.html">Deprecated</a></li> <li><a href="../../index-all.html">Index</a></li> <li><a href="../../help-doc.html">Help</a></li> </ul> <div class="aboutLanguage">JavaFX 8</div> </div> <div class="subNav"> <ul class="navList"> <li><a href="../../javafx/beans/NamedArg.html" title="annotation in javafx.beans"><span class="typeNameLink">Prev Class</span></a></li> <li><a href="../../javafx/beans/WeakInvalidationListener.html" title="class in javafx.beans"><span class="typeNameLink">Next Class</span></a></li> </ul> <ul class="navList"> <li><a href="../../index.html?javafx/beans/Observable.html" target="_top">Frames</a></li> <li><a href="Observable.html" target="_top">No Frames</a></li> </ul> <ul class="navList" id="allclasses_navbar_bottom"> <li><a href="../../allclasses-noframe.html">All Classes</a></li> </ul> <div> <script type="text/javascript"><!-- allClassesLink = document.getElementById("allclasses_navbar_bottom"); if(window==top) { allClassesLink.style.display = "block"; } else { allClassesLink.style.display = "none"; } //--> </script> </div> <div> <ul class="subNavList"> <li>Summary: </li> <li>Nested | </li> <li>Field | </li> <li>Constr | </li> <li><a href="#method.summary">Method</a></li> </ul> <ul class="subNavList"> <li>Detail: </li> <li>Field | </li> <li>Constr | </li> <li><a href="#method.detail">Method</a></li> </ul> </div> <a name="skip.navbar.bottom"> <!-- --> </a></div> <!-- ======== END OF BOTTOM NAVBAR ======= --> <p class="legalCopy"><small><font size="-1"><a href="http://bugreport.java.com/bugreport/" target="_blank">Submit a bug or feature</a><br>For further API reference and developer documentation, see <a href="https://docs.oracle.com/javase/8/docs/index.html" target="_blank">Java SE Documentation</a>. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.<br> <a href="https://docs.oracle.com/javase/8/docs/legal/cpyr.html" target="_blank">Copyright</a> © 2008, 2018, Oracle and/or its affiliates. All rights reserved. Use is subject to <a href="http://download.oracle.com/otndocs/jcp/java_se-8-mrel-spec/license.html" target="_blank">license terms</a>. Also see the <a target="_blank" href="http://www.oracle.com/technetwork/java/redist-137594.html" target="_blank">documentation redistribution policy</a>.</font></small></p> </body> </html>