ArkScript
A small, fast, functional and scripting language for video games
Ark::internal::Future Class Reference

#include <Future.hpp>

+ Collaboration diagram for Ark::internal::Future:

Public Member Functions

 Future (ExecutionContext *context, VM *vm, std::vector< Value > &args)
 
Value resolve ()
 

Private Attributes

ExecutionContextm_context
 
VMm_vm
 
std::future< Valuem_value
 

Detailed Description

Definition at line 23 of file Future.hpp.

Constructor & Destructor Documentation

◆ Future()

Ark::internal::Future::Future ( ExecutionContext context,
VM vm,
std::vector< Value > &  args 
)

Definition at line 7 of file Future.cpp.

References Ark::internal::Builtins::Async::async(), m_value, and Ark::VM::resolve().

Member Function Documentation

◆ resolve()

Value Ark::internal::Future::resolve ( )

Definition at line 15 of file Future.cpp.

References Ark::VM::deleteContext(), m_context, m_value, and m_vm.

Member Data Documentation

◆ m_context

ExecutionContext* Ark::internal::Future::m_context
private

Definition at line 31 of file Future.hpp.

Referenced by resolve().

◆ m_value

std::future<Value> Ark::internal::Future::m_value
private

Definition at line 33 of file Future.hpp.

Referenced by Future(), and resolve().

◆ m_vm

VM* Ark::internal::Future::m_vm
private

Definition at line 32 of file Future.hpp.

Referenced by resolve().


The documentation for this class was generated from the following files: