Categories:
Audio (13)
Biotech (29)
Bytecode (36)
Database (77)
Framework (7)
Game (7)
General (507)
Graphics (53)
I/O (35)
IDE (2)
JAR Tools (102)
JavaBeans (21)
JDBC (121)
JDK (426)
JSP (20)
Logging (108)
Mail (58)
Messaging (8)
Network (84)
PDF (97)
Report (7)
Scripting (84)
Security (32)
Server (121)
Servlet (26)
SOAP (24)
Testing (54)
Web (15)
XML (322)
Collections:
Other Resources:
JUnit 4.13.2 Source Code Files
JUnit Source Code Files are provided in the
source package file, junit-4.13.2-sources.jar.
You can browse JUnit Source Code files below:
✍: FYIcenter.com
⏎ org/junit/internal/management/ReflectiveRuntimeMXBean.java
package org.junit.internal.management;
import org.junit.internal.Classes;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.util.Collections;
import java.util.List;
/**
* Implementation of {@link RuntimeMXBean} using the JVM reflectively.
*/
final class ReflectiveRuntimeMXBean implements RuntimeMXBean {
private final Object runtimeMxBean;
private static final class Holder {
private static final Method getInputArgumentsMethod;
static {
Method inputArguments = null;
try {
Class<?> threadMXBeanClass = Classes.getClass("java.lang.management.RuntimeMXBean");
inputArguments = threadMXBeanClass.getMethod("getInputArguments");
} catch (ClassNotFoundException e) {
// do nothing, input arguments will be null on failure
} catch (NoSuchMethodException e) {
// do nothing, input arguments will be null on failure
} catch (SecurityException e) {
// do nothing, input arguments will be null on failure
}
getInputArgumentsMethod = inputArguments;
}
}
ReflectiveRuntimeMXBean(Object runtimeMxBean) {
super();
this.runtimeMxBean = runtimeMxBean;
}
/**
* {@inheritDoc}
*/
@SuppressWarnings("unchecked")
public List<String> getInputArguments() {
if (Holder.getInputArgumentsMethod != null) {
try {
return (List<String>) Holder.getInputArgumentsMethod.invoke(runtimeMxBean);
} catch (ClassCastException e) { // no multi-catch with source level 6
// fallthrough
} catch (IllegalAccessException e) {
// fallthrough
} catch (IllegalArgumentException e) {
// fallthrough
} catch (InvocationTargetException e) {
// fallthrough
}
}
return Collections.emptyList();
}
}
⏎ org/junit/internal/management/ReflectiveRuntimeMXBean.java
Or download all of them as a single archive file:
File name: junit-4.13.2-sources.jar File size: 234540 bytes Release date: 2021-02-13 Download
⇒ Download and Install junit-4.12.jar
⇐ Download and Install junit-4.13.2.jar
2016-03-28, ≈132🔥, 0💬
Popular Posts:
JDK 11 jdk.internal.opt.jmod is the JMOD file for JDK 11 Internal Opt module. JDK 11 Internal Opt mo...
maven-core-3.5.4.jar is the JAR file for Apache Maven 3.5.4 Core module. Apache Maven is a software ...
Java Architecture for XML Binding (JAXB) is a Java API that allows Java developers to map Java class...
How to download and install javamail-1_2.zip? The JavaMail API is a set of abstract APIs that model ...
Jackson is "the Java JSON library" or "the best JSON parser for Java". Or simply as "JSON for Java"....