Skip to content

Commit 0f20a98

Browse files
committed
8252389: Fix mistakes in FX API docs
Reviewed-by: aghaisas, kcr
1 parent 1d45997 commit 0f20a98

File tree

5 files changed

+25
-29
lines changed

5 files changed

+25
-29
lines changed

modules/javafx.base/src/main/java/javafx/beans/binding/Bindings.java

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6123,7 +6123,7 @@ public ObservableList<?> getDependencies() {
61236123
* @param <E> the type of the {@code List} elements
61246124
* @return the new {@code ObjectBinding}
61256125
* @throws NullPointerException if the {@code ObservableList} is {@code null}
6126-
* @throws IllegalArgumentException if (@code index &lt; 0)
6126+
* @throws IllegalArgumentException if {@code index < 0}
61276127
* @since JavaFX 2.1
61286128
*/
61296129
public static <E> ObjectBinding<E> valueAt(final ObservableList<E> op, final int index) {
@@ -6230,7 +6230,7 @@ public ObservableList<?> getDependencies() {
62306230
* @param index the position in the {@code List}
62316231
* @return the new {@code BooleanBinding}
62326232
* @throws NullPointerException if the {@code ObservableList} is {@code null}
6233-
* @throws IllegalArgumentException if (@code index &lt; 0)
6233+
* @throws IllegalArgumentException if {@code index < 0}
62346234
* @since JavaFX 2.1
62356235
*/
62366236
public static BooleanBinding booleanValueAt(final ObservableList<Boolean> op, final int index) {
@@ -6345,7 +6345,7 @@ public ObservableList<?> getDependencies() {
63456345
* @param index the position in the {@code List}
63466346
* @return the new {@code DoubleBinding}
63476347
* @throws NullPointerException if the {@code ObservableList} is {@code null}
6348-
* @throws IllegalArgumentException if (@code index &lt; 0)
6348+
* @throws IllegalArgumentException if {@code index < 0}
63496349
* @since JavaFX 2.1
63506350
*/
63516351
public static DoubleBinding doubleValueAt(final ObservableList<? extends Number> op, final int index) {
@@ -6460,7 +6460,7 @@ public ObservableList<?> getDependencies() {
64606460
* @param index the position in the {@code List}
64616461
* @return the new {@code FloatBinding}
64626462
* @throws NullPointerException if the {@code ObservableList} is {@code null}
6463-
* @throws IllegalArgumentException if (@code index &lt; 0)
6463+
* @throws IllegalArgumentException if {@code index < 0}
64646464
* @since JavaFX 2.1
64656465
*/
64666466
public static FloatBinding floatValueAt(final ObservableList<? extends Number> op, final int index) {
@@ -6575,7 +6575,7 @@ public ObservableList<?> getDependencies() {
65756575
* @param index the position in the {@code List}
65766576
* @return the new {@code IntegerBinding}
65776577
* @throws NullPointerException if the {@code ObservableList} is {@code null}
6578-
* @throws IllegalArgumentException if (@code index &lt; 0)
6578+
* @throws IllegalArgumentException if {@code index < 0}
65796579
* @since JavaFX 2.1
65806580
*/
65816581
public static IntegerBinding integerValueAt(final ObservableList<? extends Number> op, final int index) {
@@ -6690,7 +6690,7 @@ public ObservableList<?> getDependencies() {
66906690
* @param index the position in the {@code List}
66916691
* @return the new {@code LongBinding}
66926692
* @throws NullPointerException if the {@code ObservableList} is {@code null}
6693-
* @throws IllegalArgumentException if (@code index &lt; 0)
6693+
* @throws IllegalArgumentException if {@code index < 0}
66946694
* @since JavaFX 2.1
66956695
*/
66966696
public static LongBinding longValueAt(final ObservableList<? extends Number> op, final int index) {
@@ -6805,7 +6805,7 @@ public ObservableList<?> getDependencies() {
68056805
* @param index the position in the {@code List}
68066806
* @return the new {@code StringBinding}
68076807
* @throws NullPointerException if the {@code ObservableList} is {@code null}
6808-
* @throws IllegalArgumentException if (@code index &lt; 0)
6808+
* @throws IllegalArgumentException if {@code index < 0}
68096809
* @since JavaFX 2.1
68106810
*/
68116811
public static StringBinding stringValueAt(final ObservableList<String> op, final int index) {
@@ -7070,7 +7070,7 @@ public ObservableList<?> getDependencies() {
70707070
* @param index the position in the {@code ObservableArray}
70717071
* @return the new {@code FloatBinding}
70727072
* @throws NullPointerException if the {@code ObservableArray} is {@code null}
7073-
* @throws IllegalArgumentException if (@code index &lt; 0)
7073+
* @throws IllegalArgumentException if {@code index < 0}
70747074
* @since JavaFX 8.0
70757075
*/
70767076
public static FloatBinding floatValueAt(final ObservableFloatArray op, final int index) {
@@ -7175,7 +7175,7 @@ public ObservableList<?> getDependencies() {
71757175
* @param index the position in the {@code ObservableArray}
71767176
* @return the new {@code IntegerBinding}
71777177
* @throws NullPointerException if the {@code ObservableArray} is {@code null}
7178-
* @throws IllegalArgumentException if (@code index &lt; 0)
7178+
* @throws IllegalArgumentException if {@code index < 0}
71797179
* @since JavaFX 8.0
71807180
*/
71817181
public static IntegerBinding integerValueAt(final ObservableIntegerArray op, final int index) {

modules/javafx.base/src/main/java/javafx/collections/ListChangeListener.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ public abstract static class Change<E> {
118118
* The Change instance, in its initial state, is invalid and requires a call to {@code next()} before
119119
* calling other methods. The first {@code next()} call will make this object
120120
* represent the first change.
121-
* @return true if switched to the next change, false if this is the last change.
121+
* @return {@code true} if switched to the next change, {@code false} if this is the last change
122122
*/
123123
public abstract boolean next();
124124

@@ -156,7 +156,7 @@ public ObservableList<E> getList() {
156156

157157
/**
158158
* The end of the change interval.
159-
* @return an end (exclusive) of an interval related to the change.
159+
* @return an end (exclusive) of an interval related to the change
160160
* @throws IllegalStateException if this Change instance is in initial state
161161
* @see #getFrom()
162162
*/
@@ -172,7 +172,7 @@ public ObservableList<E> getList() {
172172

173173
/**
174174
* Indicates if the change was only a permutation.
175-
* @return true if the change was just a permutation.
175+
* @return {@code true} if the change was just a permutation
176176
* @throws IllegalStateException if this Change instance is in initial state
177177
*/
178178
public boolean wasPermutated() {
@@ -181,7 +181,7 @@ public boolean wasPermutated() {
181181

182182
/**
183183
* Indicates if elements were added during this change.
184-
* @return true if something was added to the list
184+
* @return {@code true} if something was added to the list
185185
* @throws IllegalStateException if this Change instance is in initial state
186186
*/
187187
public boolean wasAdded() {
@@ -192,7 +192,7 @@ public boolean wasAdded() {
192192
* Indicates if elements were removed during this change.
193193
* Note that using set will also produce a change with {@code wasRemoved()} returning
194194
* true. See {@link #wasReplaced()}.
195-
* @return true if something was removed from the list
195+
* @return {@code true} if something was removed from the list
196196
* @throws IllegalStateException if this Change instance is in initial state
197197
*/
198198
public boolean wasRemoved() {
@@ -220,7 +220,7 @@ public boolean wasReplaced() {
220220
* to {@link #getTo()} exclusive has changed.
221221
* This is the only optional event type and may not be
222222
* fired by all ObservableLists.
223-
* @return true if the current change is an update change.
223+
* @return {@code true} if the current change is an update change
224224
* @since JavaFX 2.1
225225
*/
226226
public boolean wasUpdated() {
@@ -236,7 +236,7 @@ public boolean wasUpdated() {
236236
* // do something
237237
* }
238238
* }</pre>
239-
* @return the newly created sublist view that contains all the added elements.
239+
* @return the newly created sublist view that contains all the added elements
240240
* @throws IllegalStateException if this Change instance is in initial state
241241
*/
242242
public List<E> getAddedSubList() {
@@ -284,9 +284,9 @@ public int getAddedSize() {
284284
* Note: default implementation of this method takes the information
285285
* from {@link #getPermutation()} method. You don't have to override this method.
286286
* @param i the old index that contained the element prior to this change
287+
* @return the new index of the same element
287288
* @throws IndexOutOfBoundsException if i is out of the bounds of the list
288289
* @throws IllegalStateException if this is not a permutation change
289-
* @return the new index of the same element
290290
*/
291291
public int getPermutation(int i) {
292292
if (!wasPermutated()) {

modules/javafx.controls/src/main/java/javafx/scene/control/MenuItem.java

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -503,24 +503,20 @@ public <E extends Event> void removeEventHandler(EventType<E> eventType, EventHa
503503
}
504504

505505
/**
506-
* Returns a previously set Object property, or null if no such property
507-
* has been set using the {@link MenuItem#setUserData(java.lang.Object)} method.
506+
* Returns the {@code Object} that was set by {@link #setUserData(Object)}, or {@code null} if no object has been
507+
* set.
508508
*
509-
* @return The Object that was previously set, or null if no property
510-
* has been set or if null was set.
509+
* @return the user object that was stored (including {@code null}), or {@code null} if no object has been set
511510
*/
512511
public Object getUserData() {
513512
return userData;
514513
}
515514

516515
/**
517-
* Convenience method for setting a single Object property that can be
518-
* retrieved at a later date. This is functionally equivalent to calling
519-
* the getProperties().put(Object key, Object value) method. This can later
520-
* be retrieved by calling {@link Node#getUserData()}.
516+
* Stores a user object that contains data at their discretion. It can later be retrieved by calling
517+
* {@link #getUserData()}.
521518
*
522-
* @param value The value to be stored - this can later be retrieved by calling
523-
* {@link Node#getUserData()}.
519+
* @param value the user object to be stored
524520
*/
525521
public void setUserData(Object value) {
526522
this.userData = value;

modules/javafx.controls/src/main/java/javafx/scene/control/TableFocusModel.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727

2828
/**
2929
* The abstract base class for FocusModel implementations that are used within
30-
* table-like controls (most notably {@link TableView} and {@link TreeTableView}.
30+
* table-like controls (most notably {@link TableView} and {@link TreeTableView}).
3131
*
3232
* @param <T> The type of the underlying data model for the UI control.
3333
* @param <TC> The concrete subclass of {@link TableColumnBase} that is used by the

modules/javafx.controls/src/main/java/javafx/scene/control/TableSelectionModel.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030

3131
/**
3232
* The abstract base class for MultipleSelectionModel implementations that are used within
33-
* table-like controls (most notably {@link TableView} and {@link TreeTableView}.
33+
* table-like controls (most notably {@link TableView} and {@link TreeTableView}).
3434
*
3535
* @param <T> The type of the underlying data model for the UI control.
3636
* @since JavaFX 8.0

0 commit comments

Comments
 (0)