Skip to content

Commit

Permalink
8264087: Use the blessed modifier order in jdk.jconsole
Browse files Browse the repository at this point in the history
Reviewed-by: alanb, amenkov, redestad
  • Loading branch information
alblue authored and cl4es committed Mar 26, 2021
1 parent 054e0a4 commit 59ed1fa
Show file tree
Hide file tree
Showing 11 changed files with 31 additions and 31 deletions.
18 changes: 9 additions & 9 deletions src/jdk.jconsole/share/classes/sun/tools/jconsole/Formatter.java
Expand Up @@ -30,17 +30,17 @@


class Formatter {
final static long SECOND = 1000;
final static long MINUTE = 60 * SECOND;
final static long HOUR = 60 * MINUTE;
final static long DAY = 24 * HOUR;
static final long SECOND = 1000;
static final long MINUTE = 60 * SECOND;
static final long HOUR = 60 * MINUTE;
static final long DAY = 24 * HOUR;

final static String cr = System.getProperty("line.separator");
static final String cr = System.getProperty("line.separator");

final static DateFormat timeDF = new SimpleDateFormat("HH:mm");
private final static DateFormat timeWithSecondsDF = new SimpleDateFormat("HH:mm:ss");
private final static DateFormat dateDF = new SimpleDateFormat("yyyy-MM-dd");
private final static String decimalZero =
static final DateFormat timeDF = new SimpleDateFormat("HH:mm");
private static final DateFormat timeWithSecondsDF = new SimpleDateFormat("HH:mm:ss");
private static final DateFormat dateDF = new SimpleDateFormat("yyyy-MM-dd");
private static final String decimalZero =
new DecimalFormatSymbols().getDecimalSeparator() + "0";

static String formatTime(long t) {
Expand Down
Expand Up @@ -82,9 +82,9 @@ static void updateLafValues() {
}


private final static String title =
private static final String title =
Messages.JAVA_MONITORING___MANAGEMENT_CONSOLE;
public final static String ROOT_URL =
public static final String ROOT_URL =
"service:jmx:";

private static int updateInterval = 4000;
Expand Down
Expand Up @@ -29,7 +29,7 @@
* Class that contains localized messages.
*
*/
final public class Messages {
public final class Messages {
private static final String BUNDLE_NAME = "sun.tools.jconsole.resources.messages";

static {
Expand Down
14 changes: 7 additions & 7 deletions src/jdk.jconsole/share/classes/sun/tools/jconsole/Plotter.java
Expand Up @@ -91,15 +91,15 @@ public static enum Unit {
};


final static long SECOND = 1000;
final static long MINUTE = 60 * SECOND;
final static long HOUR = 60 * MINUTE;
final static long DAY = 24 * HOUR;
static final long SECOND = 1000;
static final long MINUTE = 60 * SECOND;
static final long HOUR = 60 * MINUTE;
static final long DAY = 24 * HOUR;

final static Color bgColor = new Color(250, 250, 250);
final static Color defaultColor = Color.blue.darker();
static final Color bgColor = new Color(250, 250, 250);
static final Color defaultColor = Color.blue.darker();

final static int ARRAY_SIZE_INCREMENT = 4000;
static final int ARRAY_SIZE_INCREMENT = 4000;

private static Stroke dashedStroke;

Expand Down
Expand Up @@ -87,8 +87,8 @@ public class ProxyClient implements JConsoleContext {
private boolean vmConnector = false;
private boolean sslRegistry = false;
private boolean sslStub = false;
final private String connectionName;
final private String displayName;
private final String connectionName;
private final String displayName;

private ClassLoadingMXBean classLoadingMBean = null;
private CompilationMXBean compilationMBean = null;
Expand All @@ -103,7 +103,7 @@ public class ProxyClient implements JConsoleContext {
private List<MemoryPoolProxy> memoryPoolProxies = null;
private List<GarbageCollectorMXBean> garbageCollectorMBeans = null;

final static private String HOTSPOT_DIAGNOSTIC_MXBEAN_NAME =
private static final String HOTSPOT_DIAGNOSTIC_MXBEAN_NAME =
"com.sun.management:type=HotSpotDiagnostic";

private ProxyClient(String hostName, int port,
Expand Down
Expand Up @@ -74,7 +74,7 @@ public static int getMnemonicInt(String message) {
}

/**
* Initializes all non-final public static fields in the given class with
* Initializes all public static non-final fields in the given class with
* messages from a {@link ResourceBundle}.
*
* @param clazz the class containing the fields
Expand Down
Expand Up @@ -83,7 +83,7 @@ public class XMBeanAttributes extends XTable {
final Logger LOGGER =
System.getLogger(XMBeanAttributes.class.getPackage().getName());

private final static String[] columnNames =
private static final String[] columnNames =
{Messages.NAME,
Messages.VALUE};

Expand Down
Expand Up @@ -50,7 +50,7 @@
@SuppressWarnings("serial")
public class XMBeanNotifications extends JTable implements NotificationListener {

private final static String[] columnNames = {
private static final String[] columnNames = {
Messages.TIME_STAMP,
Messages.TYPE,
Messages.USER_DATA,
Expand All @@ -63,7 +63,7 @@ public class XMBeanNotifications extends JTable implements NotificationListener
new HashMap<ObjectName, XMBeanNotificationsListener>();
private volatile boolean subscribed;
private XMBeanNotificationsListener currentListener;
public final static String NOTIFICATION_RECEIVED_EVENT =
public static final String NOTIFICATION_RECEIVED_EVENT =
"jconsole.xnotification.received";
private List<NotificationListener> notificationListenersList;
private volatile boolean enabled;
Expand Down
Expand Up @@ -37,7 +37,7 @@
public class XObject extends JLabel {
private Object object;
private static boolean useHashCodeRepresentation = true;
public final static XObject NULL_OBJECT = new XObject("null");
public static final XObject NULL_OBJECT = new XObject("null");
public XObject (Object object, Icon icon) {
this(object);
setIcon(icon);
Expand Down
Expand Up @@ -42,7 +42,7 @@
@SuppressWarnings("serial") // JDK implementation class
public abstract class XOperations extends JPanel implements ActionListener {

public final static String OPERATION_INVOCATION_EVENT =
public static final String OPERATION_INVOCATION_EVENT =
"jam.xoperations.invoke.result";
private java.util.List<NotificationListener> notificationListenersList;
private Hashtable<JButton, OperationEntry> operationEntryTable;
Expand Down
Expand Up @@ -44,9 +44,9 @@ public class XTextField extends JPanel

private static boolean allowNullSelection = false;

protected final static int COMPATIBLE_VALUE = 1;
protected final static int CURRENT_VALUE = 2;
protected final static int NULL_VALUE = 3;
protected static final int COMPATIBLE_VALUE = 1;
protected static final int CURRENT_VALUE = 2;
protected static final int NULL_VALUE = 3;

private JButton button;
private XOperations operation;
Expand Down

1 comment on commit 59ed1fa

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.