public final class ClassLoaderUtils extends Object
ClassLoaderUtils - Class loading related utilities holder.| Modifier and Type | Method and Description |
|---|---|
static boolean |
findClass(String className)
Find if Class denoted by the given string representation is loadable
|
static ClassLoader |
getClassLoader()
Load the available ClassLoader
|
static URL |
getResource(String resourceName)
Get the resource URL
|
static InputStream |
getResourceAsStream(String resourceName)
Get the resource InputStream
|
static <T> Class<T> |
loadClass(String className)
Load the Class denoted by the given string representation
|
public static ClassLoader getClassLoader()
public static <T> Class<T> loadClass(String className) throws ClassNotFoundException
T - class generic typeclassName - class string representationClassNotFoundException - if the class cannot be resolvedpublic static boolean findClass(String className)
className - class string representationpublic static URL getResource(String resourceName)
resourceName - resource namepublic static InputStream getResourceAsStream(String resourceName)
resourceName - resource nameCopyright © 2023. All rights reserved.