StackTraceElement
public
final
class
StackTraceElement
extends Object
implements
Serializable
| java.lang.Object | |
| ↳ | java.lang.StackTraceElement |
An element in a stack trace, as returned by Throwable.getStackTrace(). Each element represents a single stack frame.
All stack frames except for the one at the top of the stack represent
a method invocation. The frame at the top of the stack represents the
execution point at which the stack trace was generated. Typically,
this is the point at which the throwable corresponding to the stack trace
was created.
Summary
Public constructors | |
|---|---|
StackTraceElement(String declaringClass, String methodName, String fileName, int lineNumber)
Creates a stack trace element representing the specified execution point. |
|
Public methods | |
|---|---|
boolean
|
equals(Object obj)
Returns true if the specified object is another
|
String
|
getClassName()
Returns the fully qualified name of the class containing the execution point represented by this stack trace element. |
String
|
getFileName()
Returns the name of the source file containing the execution point represented by this stack trace element. |
int
|
getLineNumber()
Returns the line number of the source line containing the execution point represented by this stack trace element. |
String
|
getMethodName()
Returns the name of the method containing the execution point represented by this stack trace element. |
int
|
hashCode()
Returns a hash code value for this stack trace element. |
boolean
|
isNativeMethod()
Returns true if the method containing the execution point represented by this stack trace element is a native method. |
String
|
toString()
Returns a string representation of this stack trace element. |
Inherited methods | |
|---|---|