Class ModuleImplementor
java.lang.Object
ai.timefold.jpyinterpreter.implementors.ModuleImplementor
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidimportFrom(FunctionMetadata functionMetadata, StackMetadata stackMetadata, PythonBytecodeInstruction instruction) TOS is a module; Push the attribute co_names[instruction.arg] from module onto the stack.static voidimportName(FunctionMetadata functionMetadata, StackMetadata stackMetadata, PythonBytecodeInstruction instruction) TOS is from_list (list or None); TOS1 is level.
-
Constructor Details
-
ModuleImplementor
public ModuleImplementor()
-
-
Method Details
-
importName
public static void importName(FunctionMetadata functionMetadata, StackMetadata stackMetadata, PythonBytecodeInstruction instruction) TOS is from_list (list or None); TOS1 is level. Imports co_names[instruction.arg] using __import__ with the given from_list and level (using the function globals and locals). TOS and TOS1 are popped, and the imported module is pushed. -
importFrom
public static void importFrom(FunctionMetadata functionMetadata, StackMetadata stackMetadata, PythonBytecodeInstruction instruction) TOS is a module; Push the attribute co_names[instruction.arg] from module onto the stack. TOS is NOT popped. (i.e. after this instruction, stack is module, attribute)
-