Base Framework
Public Member Functions | List of all members
WebAssemblyFunction Class Reference

#include <base/webassembly/WebAssembly.h>

Public Member Functions

 WebAssemblyFunction ()
 
 WebAssemblyFunction (WebAssembly wa, const String &id)
 
 WebAssemblyFunction (WebAssembly wa, unsigned int id)
 
WebAssembly::FunctionType getType ()
 
void call (const WebAssembly::WASMValue *arguments, WebAssembly::WASMValue *results)
 
template<typename RESULT , typename... ARGS>
RESULT invoke (ARGS... args)
 
template<typename RESULT , typename... ARGS>
RESULT operator() (ARGS... args)
 
void operator() (const WebAssembly::WASMValue *arguments, WebAssembly::WASMValue *results)
 

Detailed Description

Function reference.

Constructor & Destructor Documentation

◆ WebAssemblyFunction() [1/3]

WebAssemblyFunction::WebAssemblyFunction ( )

Initializes function.

◆ WebAssemblyFunction() [2/3]

WebAssemblyFunction::WebAssemblyFunction ( WebAssembly  wa,
const String id 
)

Initializes function.

◆ WebAssemblyFunction() [3/3]

WebAssemblyFunction::WebAssemblyFunction ( WebAssembly  wa,
unsigned int  id 
)

Initializes function.

Member Function Documentation

◆ call()

void WebAssemblyFunction::call ( const WebAssembly::WASMValue arguments,
WebAssembly::WASMValue results 
)
inline

Calls function.

◆ getType()

WebAssembly::FunctionType WebAssemblyFunction::getType ( )

Returns the type of the function.

◆ invoke()

template<typename RESULT , typename... ARGS>
RESULT WebAssemblyFunction::invoke ( ARGS...  args)
inline

Calls function.

◆ operator()() [1/2]

template<typename RESULT , typename... ARGS>
RESULT WebAssemblyFunction::operator() ( ARGS...  args)
inline

Calls function.

◆ operator()() [2/2]

void WebAssemblyFunction::operator() ( const WebAssembly::WASMValue arguments,
WebAssembly::WASMValue results 
)
inline

Calls function.