org.reactfx.inhibeans.ObservableBase Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of richtextfx Show documentation
Show all versions of richtextfx Show documentation
FX-Text-Area for formatted text and other special effects.
package org.reactfx.inhibeans;
import javafx.beans.InvalidationListener;
import javafx.beans.Observable;
import org.reactfx.util.ListHelper;
@Deprecated
public abstract class ObservableBase implements Observable {
private ListHelper listeners;
@Override
public void addListener(InvalidationListener listener) {
listeners = ListHelper.add(listeners, listener);
}
@Override
public void removeListener(InvalidationListener listener) {
listeners = ListHelper.remove(listeners, listener);
}
protected void notifyListeners() {
ListHelper.forEach(listeners, l -> l.invalidated(this));
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy