VCOM:VectorWorks:Scripting:IPythonWrapper::LoadModule: Difference between revisions

From Vectorworks Developer
Jump to navigation Jump to search
No edit summary
No edit summary
 
Line 9: Line 9:
Member of [[VCOM:VectorWorks:Scripting:IPythonWrapper]]
Member of [[VCOM:VectorWorks:Scripting:IPythonWrapper]]


...put some description here...
Load a python module in the current run-time.
 
A file with this name representing the module will be search in the current search path and if found will be loaded.
 
The other option is to load a moddule from memory buffer. This is the binary format of the .pyo file (compiled automatically by python from .py file)
</desc>
</desc>


Line 28: Line 32:
moduleName
moduleName
const char*
const char*
no info.
Module name.
</line>
<line>
memory
void*
Memory buffer containing the module.
</line>
<line>
memorySize
int
The size of the memory buffer.
</line>
</line>
</lineList>
</lineList>

Latest revision as of 17:32, 19 September 2013

Description

namespace VectorWorks::Scripting

Member of VCOM:VectorWorks:Scripting:IPythonWrapper

Load a python module in the current run-time.

A file with this name representing the module will be search in the current search path and if found will be loaded.

The other option is to load a moddule from memory buffer. This is the binary format of the .pyo file (compiled automatically by python from .py file)

virtual bool VCOM_CALLTYPE LoadModule(
const char* moduleName) = 0;
virtual bool VCOM_CALLTYPE LoadModule(
const char* moduleName,
void* memory,
int memorySize) = 0;

Parameters

moduleName const char* Module name.
memory void* Memory buffer containing the module.
memorySize int The size of the memory buffer.

Return Value

Uses standard VCOM Error Reporting.

Return value meaning:

kVCOMError_NotInitialized Bad VCOM instance used to call the fuction.
kVCOMError_Failed Routine failed.

Version

Availability: from Vectorworks 2014