org.apache.commons.classscan.util
Class CallStack
java.lang.Object
org.apache.commons.classscan.util.CallStack
public abstract class CallStack
- extends Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CallStack
public CallStack()
getCallerClass
public static Class<?> getCallerClass(int callStackDepth)
- Return the Class of the caller.
- Parameters:
callStackDepth
- The number of stack frames to skip.
A value of 0 will return the calling Class of this method.
A value of 1 will return the calling Class of the caller of this method.
- Returns:
- The Class at callStackDepth down the call stack
getClassLoader
public static ClassLoader getClassLoader(int callStackDepth)
- Return the ClassLoader of the caller.
- Parameters:
callStackDepth
- The number of stack frames to skip.
A value of 0 will return the ClassLoader of the calling Class of this method.
A value of 1 will return the ClassLoader of the calling Class of the caller of this method.
- Returns:
- The ClassLoader of the Class at callStackDepth down the call stack
Copyright © 2012 The Apache Software Foundation. All Rights Reserved.