public final class ReadOnlyJavaBeanIntegerProperty extends ReadOnlyIntegerPropertyBase implements ReadOnlyJavaBeanProperty<Number>
ReadOnlyJavaBeanIntegerProperty
provides an adapter between a regular
read only Java Bean property of type int
or Integer
and a JavaFX
ReadOnlyIntegerProperty
. It cannot be created directly, but a
ReadOnlyJavaBeanIntegerPropertyBuilder
has to be used.
As a minimum, the Java Bean must implement a getter for the
property. If the getter of an instance of this class is called, the property of
the Java Bean is returned. If the Java Bean property is bound (i.e. it supports
PropertyChangeListeners), this ReadOnlyJavaBeanIntegerProperty
will be
aware of changes in the Java Bean. Otherwise it can be notified about
changes by calling fireValueChangedEvent()
.
ReadOnlyIntegerProperty
,
ReadOnlyJavaBeanIntegerPropertyBuilder
Modifier and Type | Method and Description |
---|---|
void |
dispose()
Signals to the JavaFX property that it will not be used anymore and any
references can be removed.
|
void |
fireValueChangedEvent()
Sends notifications to all attached
InvalidationListeners and
ChangeListeners . |
int |
get()
Returns the current value of this
ObservableIntegerValue . |
Object |
getBean()
Returns the
Object that contains this property. |
String |
getName()
Returns the name of this property.
|
addListener, addListener, removeListener, removeListener
asObject, readOnlyIntegerProperty, toString
add, add, add, add, divide, divide, divide, divide, doubleValue, floatValue, getValue, integerExpression, integerExpression, intValue, longValue, multiply, multiply, multiply, multiply, negate, subtract, subtract, subtract, subtract
add, asString, asString, asString, divide, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, greaterThanOrEqualTo, greaterThanOrEqualTo, greaterThanOrEqualTo, greaterThanOrEqualTo, greaterThanOrEqualTo, isEqualTo, isEqualTo, isEqualTo, isEqualTo, isEqualTo, isEqualTo, isEqualTo, isEqualTo, isNotEqualTo, isNotEqualTo, isNotEqualTo, isNotEqualTo, isNotEqualTo, isNotEqualTo, isNotEqualTo, isNotEqualTo, lessThan, lessThan, lessThan, lessThan, lessThan, lessThanOrEqualTo, lessThanOrEqualTo, lessThanOrEqualTo, lessThanOrEqualTo, lessThanOrEqualTo, multiply, numberExpression, subtract
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addListener, getValue, removeListener
addListener, removeListener
public int get()
ObservableIntegerValue
.get
in interface ObservableIntegerValue
UndeclaredThrowableException
- if calling the getter of the Java Bean
property throws an IllegalAccessException
or an
InvocationTargetException
.public Object getBean()
Object
that contains this property. If this property
is not contained in an Object
, null
is returned.getBean
in interface ReadOnlyProperty<Number>
Object
or null
public String getName()
String
.getName
in interface ReadOnlyProperty<Number>
String
public void fireValueChangedEvent()
InvalidationListeners
and
ChangeListeners
.
This method needs to be called, if the value of this property changes.fireValueChangedEvent
in interface ReadOnlyJavaBeanProperty<Number>
fireValueChangedEvent
in class ReadOnlyIntegerPropertyBase
public void dispose()
dispose
in interface ReadOnlyJavaBeanProperty<Number>
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 2008, 2017, Oracle and/or its affiliates. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.