public class Classes extends Object
ClassFactory
Modifier and Type | Class and Description |
---|---|
protected static class |
Classes.ClassFactoryProvider
ClassFactoryProvider is used to hide the "swapability" of ClassFactory.
|
Constructor and Description |
---|
Classes() |
Modifier and Type | Method and Description |
---|---|
static ClassFactory |
getClassFactory() |
static boolean |
isConcrete(Class<?> clazz) |
static <T> T |
newInstance(String className,
Object... params)
Convenience/shortcut method for instantiating new classes.
|
static <T> T |
quietNewInstance(String className,
Object... params)
Convenience/shortcut for
newInstance(String, Object...) , returning null both in case
of a ClassNotFoundException or if the class could not be instantiated. |
public static boolean isConcrete(Class<?> clazz)
public static <T> T newInstance(String className, Object... params) throws ClassNotFoundException
ClassNotFoundException
ClassFactory
,
getClassFactory()
public static <T> T quietNewInstance(String className, Object... params)
newInstance(String, Object...)
, returning null both in case
of a ClassNotFoundException or if the class could not be instantiated.
(which could be related to the parameters, etc)public static ClassFactory getClassFactory()
Copyright © 2003–2018 Magnolia International Ltd.. All rights reserved.