#include <sp_vm_api.h>
Definition at line 532 of file sp_vm_api.h.
Public Member Functions | |
virtual unsigned int | GetAPIVersion ()=0 |
Returns the current API version. | |
virtual const char * | GetVMName ()=0 |
Returns the string name of a VM implementation. | |
virtual ICompilation * | StartCompilation (sp_plugin_t *plugin)=0 |
Begins a new compilation. | |
virtual bool | SetCompilationOption (ICompilation *co, const char *key, const char *val)=0 |
Sets a compilation option. | |
virtual sp_context_t * | CompileToContext (ICompilation *co, int *err)=0 |
Finalizes a compilation into a new sp_context_t. Note: This will free the ICompilation pointer. | |
virtual void | AbortCompilation (ICompilation *co)=0 |
Aborts a compilation and frees the ICompilation pointer. | |
virtual void | FreeContext (sp_context_t *ctx)=0 |
Frees any internal variable usage on a context. | |
virtual int | ContextExecute (sp_context_t *ctx, uint32_t code_addr, cell_t *result)=0 |
Calls the "execute" function on a context. | |
virtual bool | FunctionLookup (const sp_context_t *ctx, uint32_t code_addr, unsigned int *result)=0 |
Given a context and a code address, returns the index of the function. | |
virtual unsigned int | FunctionCount (const sp_context_t *ctx)=0 |
Returns the number of functions defined in the context. | |
virtual const char * | GetVersionString ()=0 |
Returns a version string. | |
virtual const char * | GetCPUOptimizations ()=0 |
Returns a string describing optimizations. |
virtual ICompilation* SourcePawn::IVirtualMachine::StartCompilation | ( | sp_plugin_t * | plugin | ) | [pure virtual] |
Begins a new compilation.
plugin | Pointer to a plugin structure. |
virtual bool SourcePawn::IVirtualMachine::SetCompilationOption | ( | ICompilation * | co, | |
const char * | key, | |||
const char * | val | |||
) | [pure virtual] |
Sets a compilation option.
co | Pointer to a compilation. | |
key | Option key name. | |
val | Option value string. |
virtual sp_context_t* SourcePawn::IVirtualMachine::CompileToContext | ( | ICompilation * | co, | |
int * | err | |||
) | [pure virtual] |
Finalizes a compilation into a new sp_context_t. Note: This will free the ICompilation pointer.
co | Compilation pointer. | |
err | Filled with error code on exit. |
virtual void SourcePawn::IVirtualMachine::AbortCompilation | ( | ICompilation * | co | ) | [pure virtual] |
virtual void SourcePawn::IVirtualMachine::FreeContext | ( | sp_context_t * | ctx | ) | [pure virtual] |
Frees any internal variable usage on a context.
ctx | Context structure pointer. |
virtual int SourcePawn::IVirtualMachine::ContextExecute | ( | sp_context_t * | ctx, | |
uint32_t | code_addr, | |||
cell_t * | result | |||
) | [pure virtual] |
Calls the "execute" function on a context.
ctx | Executes a function in a context. | |
code_addr | Index into the code section. | |
result | Pointer to store result into. |
virtual bool SourcePawn::IVirtualMachine::FunctionLookup | ( | const sp_context_t * | ctx, | |
uint32_t | code_addr, | |||
unsigned int * | result | |||
) | [pure virtual] |
Given a context and a code address, returns the index of the function.
ctx | Context to search. | |
code_addr | Index into the code section. | |
result | Pointer to store result into. |
virtual unsigned int SourcePawn::IVirtualMachine::FunctionCount | ( | const sp_context_t * | ctx | ) | [pure virtual] |
Returns the number of functions defined in the context.
ctx | Context to search. |
virtual const char* SourcePawn::IVirtualMachine::GetVersionString | ( | ) | [pure virtual] |
Returns a version string.
virtual const char* SourcePawn::IVirtualMachine::GetCPUOptimizations | ( | ) | [pure virtual] |
Returns a string describing optimizations.