diff options
| author | Paul Buetow <paul@buetow.org> | 2022-04-03 19:15:16 +0100 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2022-04-03 20:03:06 +0100 |
| commit | dc9500c513173a0f527e5edc7a8e9c26f1acd99a (patch) | |
| tree | fa44718ea94d19b6b7a38e9ef927f20a6f5b4ab9 /sources/utils | |
| parent | d47aedde47148f6725b56128b26ae2ac3a56dde1 (diff) | |
fix java deprecation notices
Diffstat (limited to 'sources/utils')
| -rw-r--r-- | sources/utils/VS3Tupel.java | 26 | ||||
| -rw-r--r-- | sources/utils/VSAboutFrame.java | 41 | ||||
| -rw-r--r-- | sources/utils/VSClassLoader.java | 28 | ||||
| -rw-r--r-- | sources/utils/VSFrame.java | 33 | ||||
| -rw-r--r-- | sources/utils/VSInfoArea.java | 34 | ||||
| -rw-r--r-- | sources/utils/VSPriorityQueue.java | 23 | ||||
| -rw-r--r-- | sources/utils/VSRandom.java | 26 | ||||
| -rw-r--r-- | sources/utils/VSTools.java | 27 |
8 files changed, 27 insertions, 211 deletions
diff --git a/sources/utils/VS3Tupel.java b/sources/utils/VS3Tupel.java index d419d36..ac7ffba 100644 --- a/sources/utils/VS3Tupel.java +++ b/sources/utils/VS3Tupel.java @@ -1,26 +1,3 @@ -/* - * Copyright (c) 2008 Paul C. Buetow, vs-sim@dev.buetow.org - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - * All icons of the icons/ folder are under a Creative Commons - * Attribution-Noncommercial-Share Alike License a CC-by-nc-sa. - * - * The icon's homepage is http://code.google.com/p/ultimate-gnome/ - */ - package utils; /** @@ -30,9 +7,6 @@ package utils; * @author Paul C. Buetow */ public final class VS3Tupel<A,B,C> { - /** The serial version uid */ - private static final long serialVersionUID = 1L; - /** The a. */ private A a; diff --git a/sources/utils/VSAboutFrame.java b/sources/utils/VSAboutFrame.java index 32e7810..ef64ffa 100644 --- a/sources/utils/VSAboutFrame.java +++ b/sources/utils/VSAboutFrame.java @@ -1,34 +1,18 @@ -/* - * Copyright (c) 2008 Paul C. Buetow, vs-sim@dev.buetow.org - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - * All icons of the icons/ folder are under a Creative Commons - * Attribution-Noncommercial-Share Alike License a CC-by-nc-sa. - * - * The icon's homepage is http://code.google.com/p/ultimate-gnome/ - */ - package utils; -import java.awt.*; -import java.awt.event.*; -import javax.swing.*; +import java.awt.BorderLayout; +import java.awt.Color; +import java.awt.Component; +import java.awt.Container; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; + +import javax.swing.JButton; +import javax.swing.JPanel; +import javax.swing.JScrollPane; -import prefs.*; //import utils.*; +import prefs.VSPrefs; /** * The class VSAboutFrame. This class is only for the about window which @@ -37,9 +21,6 @@ import prefs.*; * @author Paul C. Buetow */ public class VSAboutFrame extends VSFrame { - /** The serial version uid */ - private static final long serialVersionUID = 1L; - /** The prefs. */ private VSPrefs prefs; diff --git a/sources/utils/VSClassLoader.java b/sources/utils/VSClassLoader.java index 37d5976..37f4027 100644 --- a/sources/utils/VSClassLoader.java +++ b/sources/utils/VSClassLoader.java @@ -1,26 +1,3 @@ -/* - * Copyright (c) 2008 Paul C. Buetow, vs-sim@dev.buetow.org - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - * All icons of the icons/ folder are under a Creative Commons - * Attribution-Noncommercial-Share Alike License a CC-by-nc-sa. - * - * The icon's homepage is http://code.google.com/p/ultimate-gnome/ - */ - package utils; /** @@ -30,9 +7,6 @@ package utils; * @author Paul C. Buetow */ public class VSClassLoader extends ClassLoader { - /** The serial version uid */ - private static final long serialVersionUID = 1L; - /** * Creates a new instance of the given classname. * @@ -44,7 +18,7 @@ public class VSClassLoader extends ClassLoader { Object object = null; try { - object = super.loadClass(classname, true).newInstance(); + object = super.loadClass(classname, true).getDeclaredConstructor().newInstance(); } catch (Exception e) { System.out.println(e + "; Classname " + classname); diff --git a/sources/utils/VSFrame.java b/sources/utils/VSFrame.java index 8029554..818a72d 100644 --- a/sources/utils/VSFrame.java +++ b/sources/utils/VSFrame.java @@ -1,30 +1,13 @@ -/* - * Copyright (c) 2008 Paul C. Buetow, vs-sim@dev.buetow.org - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - * All icons of the icons/ folder are under a Creative Commons - * Attribution-Noncommercial-Share Alike License a CC-by-nc-sa. - * - * The icon's homepage is http://code.google.com/p/ultimate-gnome/ - */ - package utils; -import java.awt.*; -import java.awt.event.*; +import java.awt.Component; +import java.awt.Dimension; +import java.awt.Point; +import java.awt.Toolkit; +import java.awt.Window; +import java.awt.event.WindowAdapter; +import java.awt.event.WindowEvent; + import javax.swing.JFrame; /** diff --git a/sources/utils/VSInfoArea.java b/sources/utils/VSInfoArea.java index 3168821..645afb1 100644 --- a/sources/utils/VSInfoArea.java +++ b/sources/utils/VSInfoArea.java @@ -1,35 +1,15 @@ -/* - * Copyright (c) 2008 Paul C. Buetow, vs-sim@dev.buetow.org - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - * All icons of the icons/ folder are under a Creative Commons - * Attribution-Noncommercial-Share Alike License a CC-by-nc-sa. - * - * The icon's homepage is http://code.google.com/p/ultimate-gnome/ - */ - package utils; -import java.awt.*; -import javax.swing.*; -import javax.swing.border.*; +import java.awt.Color; + +import javax.swing.JTextPane; +import javax.swing.border.CompoundBorder; +import javax.swing.border.EmptyBorder; +import javax.swing.border.LineBorder; /** * The class VSInfoArea, an object of this class is used for some information - *areas. E.g. in the VSAboutFrame class. + * areas. E.g. in the VSAboutFrame class. * * @author Paul C. Buetow */ diff --git a/sources/utils/VSPriorityQueue.java b/sources/utils/VSPriorityQueue.java index 443e796..d706352 100644 --- a/sources/utils/VSPriorityQueue.java +++ b/sources/utils/VSPriorityQueue.java @@ -1,26 +1,3 @@ -/* - * Copyright (c) 2008 Paul C. Buetow, vs-sim@dev.buetow.org - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - * All icons of the icons/ folder are under a Creative Commons - * Attribution-Noncommercial-Share Alike License a CC-by-nc-sa. - * - * The icon's homepage is http://code.google.com/p/ultimate-gnome/ - */ - package utils; import java.util.PriorityQueue; diff --git a/sources/utils/VSRandom.java b/sources/utils/VSRandom.java index e6978de..6c1de90 100644 --- a/sources/utils/VSRandom.java +++ b/sources/utils/VSRandom.java @@ -1,26 +1,3 @@ -/* - * Copyright (c) 2008 Paul C. Buetow, vs-sim@dev.buetow.org - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - * All icons of the icons/ folder are under a Creative Commons - * Attribution-Noncommercial-Share Alike License a CC-by-nc-sa. - * - * The icon's homepage is http://code.google.com/p/ultimate-gnome/ - */ - package utils; import java.util.Random; @@ -31,9 +8,6 @@ import java.util.Random; * @author Paul C. Buetow */ public final class VSRandom extends Random { - /** The serial version uid */ - private static final long serialVersionUID = 1L; - /** * Instantiates a new VSrandom object. * diff --git a/sources/utils/VSTools.java b/sources/utils/VSTools.java index 6f60993..ceb5760 100644 --- a/sources/utils/VSTools.java +++ b/sources/utils/VSTools.java @@ -1,26 +1,3 @@ -/* - * Copyright (c) 2008 Paul C. Buetow, vs-sim@dev.buetow.org - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - * All icons of the icons/ folder are under a Creative Commons - * Attribution-Noncommercial-Share Alike License a CC-by-nc-sa. - * - * The icon's homepage is http://code.google.com/p/ultimate-gnome/ - */ - package utils; import java.util.Vector; @@ -32,9 +9,6 @@ import java.util.Vector; * @author Paul C. Buetow */ public final class VSTools { - /** The serial version uid */ - private static final long serialVersionUID = 1L; - /** * Gets the time string. * @@ -113,7 +87,6 @@ public final class VSTools { } catch (StringIndexOutOfBoundsException e) { } catch (NumberFormatException e) { } - return vec; } } |
