125 * Option.RETAIN_CLASS_REFERENCE}. |
125 * Option.RETAIN_CLASS_REFERENCE}. |
126 */ |
126 */ |
127 public Class<?> getDeclaringClass(); |
127 public Class<?> getDeclaringClass(); |
128 |
128 |
129 /** |
129 /** |
|
130 * Returns the index to the code array of the {@code Code} attribute |
|
131 * containing the execution point represented by this stack frame. |
|
132 * The code array gives the actual bytes of Java Virtual Machine code |
|
133 * that implement the method. |
|
134 * |
|
135 * @return the index to the code array of the {@code Code} attribute |
|
136 * containing the execution point represented by this stack frame, |
|
137 * or a negative number if the method is native. |
|
138 * |
|
139 * @jvms 4.7.3 The {@code Code} Attribute |
|
140 */ |
|
141 public int getByteCodeIndex(); |
|
142 |
|
143 /** |
130 * Returns the name of the source file containing the execution point |
144 * Returns the name of the source file containing the execution point |
131 * represented by this stack frame. Generally, this corresponds |
145 * represented by this stack frame. Generally, this corresponds |
132 * to the {@code SourceFile} attribute of the relevant {@code class} |
146 * to the {@code SourceFile} attribute of the relevant {@code class} |
133 * file as defined by <cite>The Java Virtual Machine Specification</cite>. |
147 * file as defined by <cite>The Java Virtual Machine Specification</cite>. |
134 * In some systems, the name may refer to some source code unit |
148 * In some systems, the name may refer to some source code unit |
135 * other than a file, such as an entry in a source repository. |
149 * other than a file, such as an entry in a source repository. |
136 * |
150 * |
137 * @return the name of the file containing the execution point |
151 * @return the name of the file containing the execution point |
138 * represented by this stack frame, or empty {@code Optional} |
152 * represented by this stack frame, or {@code null} if |
139 * is unavailable. |
153 * this information is unavailable. |
140 * |
154 * |
141 * @jvms 4.7.10 The {@code SourceFile} Attribute |
155 * @jvms 4.7.10 The {@code SourceFile} Attribute |
142 */ |
156 */ |
143 public Optional<String> getFileName(); |
157 public String getFileName(); |
144 |
158 |
145 /** |
159 /** |
146 * Returns the line number of the source line containing the execution |
160 * Returns the line number of the source line containing the execution |
147 * point represented by this stack frame. Generally, this is |
161 * point represented by this stack frame. Generally, this is |
148 * derived from the {@code LineNumberTable} attribute of the relevant |
162 * derived from the {@code LineNumberTable} attribute of the relevant |
149 * {@code class} file as defined by <cite>The Java Virtual Machine |
163 * {@code class} file as defined by <cite>The Java Virtual Machine |
150 * Specification</cite>. |
164 * Specification</cite>. |
151 * |
165 * |
152 * @return the line number of the source line containing the execution |
166 * @return the line number of the source line containing the execution |
153 * point represented by this stack frame, or empty |
167 * point represented by this stack frame, or a negative number if |
154 * {@code Optional} if this information is unavailable. |
168 * this information is unavailable. |
155 * |
169 * |
156 * @jvms 4.7.12 The {@code LineNumberTable} Attribute |
170 * @jvms 4.7.12 The {@code LineNumberTable} Attribute |
157 */ |
171 */ |
158 public OptionalInt getLineNumber(); |
172 public int getLineNumber(); |
159 |
173 |
160 /** |
174 /** |
161 * Returns {@code true} if the method containing the execution point |
175 * Returns {@code true} if the method containing the execution point |
162 * represented by this stack frame is a native method. |
176 * represented by this stack frame is a native method. |
163 * |
177 * |