org.reflections.util
Class Utils
java.lang.Object
org.reflections.util.Utils
public abstract class Utils
- extends Object
a garbage can of convenient methods
Constructor Summary |
Utils()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Utils
public Utils()
repeat
public static String repeat(String string,
int times)
isEmpty
public static boolean isEmpty(String s)
- isEmpty compatible with Java 5
isEmpty
public static boolean isEmpty(Object[] objects)
prepareFile
public static File prepareFile(String filename)
getMemberFromDescriptor
public static Member getMemberFromDescriptor(String descriptor,
ClassLoader... classLoaders)
throws ReflectionsException
- Throws:
ReflectionsException
getMethodsFromDescriptors
public static Set<Method> getMethodsFromDescriptors(Iterable<String> annotatedWith,
ClassLoader... classLoaders)
getConstructorsFromDescriptors
public static Set<Constructor> getConstructorsFromDescriptors(Iterable<String> annotatedWith,
ClassLoader... classLoaders)
getMembersFromDescriptors
public static Set<Member> getMembersFromDescriptors(Iterable<String> values,
ClassLoader... classLoaders)
getFieldFromString
public static Field getFieldFromString(String field,
ClassLoader... classLoaders)
close
public static void close(InputStream closeable)
findLogger
@Nullable
public static org.slf4j.Logger findLogger(Class<?> aClass)
isConstructor
public static boolean isConstructor(String fqn)
name
public static String name(Class type)
names
public static List<String> names(Iterable<Class<?>> types)
names
public static List<String> names(Class<?>... types)
name
public static String name(Constructor constructor)
name
public static String name(Method method)
name
public static String name(Field field)
Copyright © 2014. All rights reserved.