ExecutableNode
public abstract class ExecutableNode extends Node- Known subtypes
Constructors1
ExecutableNode(TruffleLanguage<?>)
ExecutableNode
since 0.31protected ExecutableNode(TruffleLanguage< ?> language)Creates new executable node with a given language instance. The language instance is obtainable while TruffleLanguage.parse(InlineParsingRequest) is executed.
Parameters
languageTruffleLanguage<?> - the language this executable node is associated with
Methods3 + 26 inherited
Object execute(VirtualFrame)
execute
abstractsince 0.31public abstract Object execute(VirtualFrame frame)Execute this fragment at the place where it was parsed.
Parameters
frameVirtualFrame- the actual frame valid at the parsed location
Returns
Object- the result of the execution, must be an interop type (i.e. either implementing TruffleObject or be a primitive value), or
null.
LanguageInfo getLanguageInfo()
getLanguageInfo
since 0.31public final LanguageInfo getLanguageInfo()Returns public information about the language. The language can be assumed equal if the instances of the language info instance are the same. To access internal details of the language within the language implementation use a LanguageReference.
Returns
LanguageInfo- No description.
C getLanguage(Class<C>)
getLanguage
since 0.31public final < C extends TruffleLanguage> C getLanguage(Class< C> languageClass)Returns the language instance associated with this executable node. The language instance is intended for internal use in languages and is only accessible if the concrete type of the language is known. Public information about the language can be accessed using getLanguageInfo(). The language is null if the executable node is not associated with a language. This method is guaranteed to return a PE constant if the root node is also a PE constant.
Parameters
languageClassClass<C> - No description.
Returns
C- No description.