src/share/classes/sun/management/snmp/jvminstr/JvmThreadingImpl.java

Print this page
rev 10195 : 8048267: Replace uses of 'new Long()' with appropriate alternative across core classes
Reviewed-by: chegar, psandoz
Contributed-by: otaviojava@java.net

*** 301,340 **** /** * Getter for the "JvmThreadTotalStartedCount" variable. */ public Long getJvmThreadTotalStartedCount() throws SnmpStatusException { ! return new Long(getThreadMXBean().getTotalStartedThreadCount()); } /** * Getter for the "JvmThreadPeakCount" variable. */ public Long getJvmThreadPeakCount() throws SnmpStatusException { ! return new Long(getThreadMXBean().getPeakThreadCount()); } /** * Getter for the "JvmThreadDaemonCount" variable. */ public Long getJvmThreadDaemonCount() throws SnmpStatusException { ! return new Long(getThreadMXBean().getDaemonThreadCount()); } /** * Getter for the "JvmThreadCount" variable. */ public Long getJvmThreadCount() throws SnmpStatusException { ! return new Long(getThreadMXBean().getThreadCount()); } /** * Getter for the "JvmThreadPeakCountReset" variable. */ public synchronized Long getJvmThreadPeakCountReset() throws SnmpStatusException { ! return new Long(jvmThreadPeakCountReset); } /** * Setter for the "JvmThreadPeakCountReset" variable. */ --- 301,340 ---- /** * Getter for the "JvmThreadTotalStartedCount" variable. */ public Long getJvmThreadTotalStartedCount() throws SnmpStatusException { ! return getThreadMXBean().getTotalStartedThreadCount(); } /** * Getter for the "JvmThreadPeakCount" variable. */ public Long getJvmThreadPeakCount() throws SnmpStatusException { ! return (long)getThreadMXBean().getPeakThreadCount(); } /** * Getter for the "JvmThreadDaemonCount" variable. */ public Long getJvmThreadDaemonCount() throws SnmpStatusException { ! return (long)getThreadMXBean().getDaemonThreadCount(); } /** * Getter for the "JvmThreadCount" variable. */ public Long getJvmThreadCount() throws SnmpStatusException { ! return (long)getThreadMXBean().getThreadCount(); } /** * Getter for the "JvmThreadPeakCountReset" variable. */ public synchronized Long getJvmThreadPeakCountReset() throws SnmpStatusException { ! return jvmThreadPeakCountReset; } /** * Setter for the "JvmThreadPeakCountReset" variable. */