98 // If we reach this point, then we can safely assume that
99 // getCompilationMXBean() will not return null, because this
100 // object will not be instantiated when there is no compilation
101 // system (see JVM_MANAGEMENT_MIB_IMPL).
102 //
103 if(getCompilationMXBean().isCompilationTimeMonitoringSupported())
104 return JvmJITCompilerTimeMonitoringSupported;
105 else
106 return JvmJITCompilerTimeMonitoringUnsupported;
107 }
108
109 /**
110 * Getter for the "JvmJITCompilerTimeMs" variable.
111 */
112 public Long getJvmJITCompilerTimeMs() throws SnmpStatusException {
113 final long t;
114 if(getCompilationMXBean().isCompilationTimeMonitoringSupported())
115 t = getCompilationMXBean().getTotalCompilationTime();
116 else
117 t = 0;
118 return new Long(t);
119 }
120
121 /**
122 * Getter for the "JvmJITCompilerName" variable.
123 */
124 public String getJvmJITCompilerName() throws SnmpStatusException {
125 return JVM_MANAGEMENT_MIB_IMPL.
126 validJavaObjectNameTC(getCompilationMXBean().getName());
127 }
128
129 }
|
98 // If we reach this point, then we can safely assume that
99 // getCompilationMXBean() will not return null, because this
100 // object will not be instantiated when there is no compilation
101 // system (see JVM_MANAGEMENT_MIB_IMPL).
102 //
103 if(getCompilationMXBean().isCompilationTimeMonitoringSupported())
104 return JvmJITCompilerTimeMonitoringSupported;
105 else
106 return JvmJITCompilerTimeMonitoringUnsupported;
107 }
108
109 /**
110 * Getter for the "JvmJITCompilerTimeMs" variable.
111 */
112 public Long getJvmJITCompilerTimeMs() throws SnmpStatusException {
113 final long t;
114 if(getCompilationMXBean().isCompilationTimeMonitoringSupported())
115 t = getCompilationMXBean().getTotalCompilationTime();
116 else
117 t = 0;
118 return t;
119 }
120
121 /**
122 * Getter for the "JvmJITCompilerName" variable.
123 */
124 public String getJvmJITCompilerName() throws SnmpStatusException {
125 return JVM_MANAGEMENT_MIB_IMPL.
126 validJavaObjectNameTC(getCompilationMXBean().getName());
127 }
128
129 }
|