Class Overview
Provides a limited interface to the Dalvik VM stack. This class is mostly
used for implementing security checks.
Summary
[Expand]
Inherited Methods |
From class java.lang.Object
Object
|
clone()
Creates and returns a copy of this Object .
|
boolean
|
equals(Object o)
Compares this instance with the specified object and indicates if they
are equal.
|
void
|
finalize()
Is called before the object's memory is being reclaimed by the VM.
|
final
Class<? extends Object>
|
getClass()
Returns the unique instance of Class which represents this
object's class.
|
int
|
hashCode()
Returns an integer hash code for this object.
|
final
void
|
notify()
Causes a thread which is waiting on this object's monitor (by means of
calling one of the wait() methods) to be woken up.
|
final
void
|
notifyAll()
Causes all threads which are waiting on this object's monitor (by means
of calling one of the wait() methods) to be woken up.
|
String
|
toString()
Returns a string containing a concise, human-readable description of this
object.
|
final
void
|
wait(long millis, int nanos)
Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object or until the
specified timeout expires.
|
final
void
|
wait(long millis)
Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object or until the
specified timeout expires.
|
final
void
|
wait()
Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object.
|
|
Public Constructors
Public Methods
public
static
ClassLoader
getCallingClassLoader
()
Returns the defining class loader of the caller's caller.
Returns
- the requested class loader, or
null
if this is the
bootstrap class loader.
public
static
ClassLoader
getCallingClassLoader2
()
Returns the defining class loader of the caller's caller's caller.
Returns
- the requested class loader, or
null
if this is the
bootstrap class loader.
public
static
Class[]<?>
getClasses
(int maxDepth, boolean stopAtPrivileged)
Creates an array of classes from the methods at the top of the stack.
We continue until we reach the bottom of the stack or exceed the
specified maximum depth. If stopAtPrivileged is set, the last
element of the array will be the caller of the most-recent privileged
method.
The topmost stack frame (this method) and the one above that (the
caller) are excluded from the array. Frames with java.lang.reflect
classes are skipped over.
The classes in the array are the defining classes of the methods.
This is expected to be identical to Harmony's VMStack.getClasses.
Parameters
maxDepth
| maximum number of classes to return, or -1 for all |
stopAtPrivileged
| stop when a privileged frame is reached |
Returns
- an array with classes for the most-recent methods on the stack
Retrieves the stack trace from the specified thread.
Returns
- an array of stack trace elements, or null if the thread
doesn't have a stack trace (e.g. because it exited)