Module jdk.jshell
Package jdk.jshell

## Class UnresolvedReferenceException

- java.lang.Object
- - java.lang.Throwable
  - - java.lang.Exception
    - - jdk.jshell.UnresolvedReferenceException

All Implemented Interfaces:
  Serializable

    public class UnresolvedReferenceException
    extends Exception

Exception reported on attempting to execute a `RECOVERABLE_DEFINED` snippet.

The stack can be queried by methods on `Exception`. Note that in stack trace frames representing JShell Snippets, `StackTraceElement.getFileName()` will return "#" followed by the Snippet id and for snippets without a method name (for example an expression) `StackTraceElement.getName()` will be the empty string.

See Also:
  Serialized Form

### Method Summary

All Methods Instance Methods Concrete Methods
`DeclarationSnippet` `getSnippet()` Return the Snippet which has the unresolved reference(s).

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Methods inherited from class java.lang.Throwable

`addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString`

### Method Detail

#### getSnippet

    public DeclarationSnippet getSnippet()

Return the Snippet which has the unresolved reference(s).

Returns:
  the `Snippet` of the `RECOVERABLE_DEFINED` definition snippet.