Skip to content

Commit 8591eff

Browse files
nizarbenallaaivanov-jdk
authored andcommitted
8332103: since-checker - Add missing @ since tags to java.desktop
Reviewed-by: tr, aivanov
1 parent 8374d16 commit 8591eff

File tree

9 files changed

+42
-8
lines changed

9 files changed

+42
-8
lines changed

src/java.desktop/share/classes/java/awt/geom/Path2D.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2006, 2021, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2006, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -292,6 +292,9 @@ public Float(Shape s, AffineTransform at) {
292292
}
293293
}
294294

295+
/**
296+
* @since 10
297+
*/
295298
@Override
296299
public final void trimToSize() {
297300
// trim arrays:
@@ -1178,6 +1181,9 @@ public Double(Shape s, AffineTransform at) {
11781181
}
11791182
}
11801183

1184+
/**
1185+
* @since 10
1186+
*/
11811187
@Override
11821188
public final void trimToSize() {
11831189
// trim arrays:

src/java.desktop/share/classes/java/beans/package-info.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1998, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -108,5 +108,7 @@
108108
* Long-Term Persistence</a>, an article in
109109
* <em>The Swing Connection</em>.</li>
110110
* </ul>
111+
*
112+
* @since 1.1
111113
*/
112114
package java.beans;

src/java.desktop/share/classes/javax/swing/DefaultComboBoxModel.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1998, 2018, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1998, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -183,6 +183,8 @@ public void removeAllElements() {
183183
*
184184
* @param c the collection which contains the elements to add
185185
* @throws NullPointerException if {@code c} is null
186+
*
187+
* @since 11
186188
*/
187189
public void addAll(Collection<? extends E> c) {
188190
if (c.isEmpty()) {
@@ -205,6 +207,8 @@ public void addAll(Collection<? extends E> c) {
205207
* @throws ArrayIndexOutOfBoundsException if {@code index} does not
206208
* fall within the range of number of elements currently held
207209
* @throws NullPointerException if {@code c} is null
210+
*
211+
* @since 11
208212
*/
209213
public void addAll(int index, Collection<? extends E> c) {
210214
if (index < 0 || index > getSize()) {

src/java.desktop/share/classes/javax/swing/DefaultListModel.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1997, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -530,6 +530,8 @@ public void removeRange(int fromIndex, int toIndex) {
530530
*
531531
* @param c the collection which contains the elements to add
532532
* @throws NullPointerException if {@code c} is null
533+
*
534+
* @since 11
533535
*/
534536
public void addAll(Collection<? extends E> c) {
535537
if (c.isEmpty()) {
@@ -552,6 +554,8 @@ public void addAll(Collection<? extends E> c) {
552554
* @throws ArrayIndexOutOfBoundsException if {@code index} does not
553555
* fall within the range of number of elements currently held
554556
* @throws NullPointerException if {@code c} is null
557+
*
558+
* @since 11
555559
*/
556560
public void addAll(int index, Collection<? extends E> c) {
557561
if (index < 0 || index > getSize()) {

src/java.desktop/share/classes/javax/swing/JSlider.java

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1997, 2023, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1997, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -1461,6 +1461,8 @@ public AccessibleStateSet getAccessibleStateSet() {
14611461
*
14621462
* @param e a {@code ChangeEvent} object. Must not be {@code null}
14631463
* @throws NullPointerException if the parameter is {@code null}
1464+
*
1465+
* @since 16
14641466
*/
14651467
public void stateChanged(ChangeEvent e) {
14661468
if (e == null) {
@@ -1561,6 +1563,8 @@ public AccessibleAction getAccessibleAction() {
15611563
* which decrements the slider value
15621564
*
15631565
* @return the zero-based number of Actions in this object
1566+
*
1567+
* @since 17
15641568
*/
15651569
public int getAccessibleActionCount() {
15661570
return 2;
@@ -1572,6 +1576,8 @@ public int getAccessibleActionCount() {
15721576
* @param i zero-based index of the actions
15731577
* @return a String description of the action
15741578
* @see #getAccessibleActionCount
1579+
*
1580+
* @since 17
15751581
*/
15761582
public String getAccessibleActionDescription(int i) {
15771583
if (i == 0) {
@@ -1590,6 +1596,8 @@ public String getAccessibleActionDescription(int i) {
15901596
* action (index 1) is AccessibleAction.DECREMENT.
15911597
* @return true if the action was performed, otherwise false
15921598
* @see #getAccessibleActionCount
1599+
*
1600+
* @since 17
15931601
*/
15941602
public boolean doAccessibleAction(int i) {
15951603
if (i < 0 || i > 1) {

src/java.desktop/share/classes/javax/swing/package-info.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1998, 2022, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1998, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -149,5 +149,7 @@
149149
* </ul>
150150
*
151151
* @serial exclude
152+
*
153+
* @since 1.2
152154
*/
153155
package javax.swing;

src/java.desktop/share/classes/javax/swing/plaf/basic/BasicSliderUI.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,8 @@ public class BasicSliderUI extends SliderUI{
150150

151151
/**
152152
* Constructs a {@code BasicSliderUI}.
153+
*
154+
* @since 16
153155
* @deprecated This constructor was exposed erroneously and will be removed in a future release.
154156
* Use {@link #BasicSliderUI(JSlider)} instead.
155157
*/

src/java.desktop/share/classes/javax/swing/plaf/synth/package-info.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2003, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -139,5 +139,7 @@
139139
* <bind style="style" type="region" key="Table"/>
140140
* <bind style="style" type="region" key="List"/>
141141
* }</pre>
142+
*
143+
* @since 1.5
142144
*/
143145
package javax.swing.plaf.synth;

src/java.desktop/share/classes/javax/swing/text/DefaultEditorKit.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1997, 2023, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1997, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -648,6 +648,8 @@ public void write(Writer out, Document doc, int pos, int len)
648648
* beginning of the previous line if the caret is
649649
* already at the beginning of the line.
650650
* @see #getActions
651+
*
652+
* @since 20
651653
*/
652654
public static final String beginLineUpAction = "caret-begin-line-and-up";
653655

@@ -657,6 +659,8 @@ public void write(Writer out, Document doc, int pos, int len)
657659
* end of the next line if the caret is already
658660
* at the end of the line.
659661
* @see #getActions
662+
*
663+
* @since 20
660664
*/
661665
public static final String endLineDownAction = "caret-end-line-and-down";
662666

0 commit comments

Comments
 (0)