public static final class TruffleLanguage.ContextReference<C> extends Object
TruffleLanguage.getContextReference() and the current context can be
accessed using the TruffleLanguage.ContextReference.get() method of the returned reference.
Please note that the current context might vary between executions if resources or code is shared between multiple contexts.
| Modifier and Type | Method and Description |
|---|---|
C |
get()
Returns the current context associated with the language this reference was created with.
|
public C get()
context
creation or in the language class constructor an IllegalStateException is
thrown. This methods is designed to be called safely from compiled code paths.
Please note that the current context might vary between
executions if resources or code is shared between
multiple contexts.