Class NodeFactoryBase<T>
java.lang.Object
com.oracle.truffle.api.dsl.internal.NodeFactoryBase<T>
- All Implemented Interfaces:
NodeFactory<T>
This is NOT public API. Do not use directly. This code may change without notice.
-
Constructor Summary
ConstructorsConstructorDescriptionNodeFactoryBase(Class<T> nodeClass, Class<?>[] executionSignatures, Class<?>[][] nodeSignatures) -
Method Summary
Modifier and TypeMethodDescriptionabstract TcreateNode(Object... arguments) Instantiates the node using the arguments array.Returns a list of children that will be executed by the created node.Returns the node class that will get created byNodeFactory.createNode(Object...).Returns a list of signatures that can be used to invokeNodeFactory.createNode(Object...).
-
Constructor Details
-
NodeFactoryBase
-
-
Method Details
-
createNode
Description copied from interface:NodeFactoryInstantiates the node using the arguments array. The arguments length and types must suffice one of the returned signatures inNodeFactory.getNodeSignatures(). If the arguments array does not suffice one of the node signatures anIllegalArgumentExceptionis thrown.- Specified by:
createNodein interfaceNodeFactory<T>- Parameters:
arguments- the argument values- Returns:
- the instantiated node
-
getNodeClass
Description copied from interface:NodeFactoryReturns the node class that will get created byNodeFactory.createNode(Object...). The node class does not match exactly to the instantiated object but they are guaranteed to be assignable.- Specified by:
getNodeClassin interfaceNodeFactory<T>
-
getNodeSignatures
Description copied from interface:NodeFactoryReturns a list of signatures that can be used to invokeNodeFactory.createNode(Object...).- Specified by:
getNodeSignaturesin interfaceNodeFactory<T>
-
getExecutionSignature
Description copied from interface:NodeFactoryReturns a list of children that will be executed by the created node. This is useful for base nodes that can execute a variable amount of nodes.- Specified by:
getExecutionSignaturein interfaceNodeFactory<T>
-