5#ifndef MOLYBDEN_JS_RETURN_VALUE_HPP
6#define MOLYBDEN_JS_RETURN_VALUE_HPP
10#include "molybden/js/js_error.hpp"
11#include "molybden/js/js_value.hpp"
15class JsReturnValueVariant;
71 explicit operator bool()
const;
74 std::unique_ptr<JsReturnValueVariant> impl_;
Represents the JS function return value.
Definition js_return_value.hpp:35
JsError asError() &&
Returns the error that the return value represents if it does, otherwise it should not be called.
bool isCorrect() const
Indicates if the execution finished successfully and returned a value.
JsValue asValue() &&
Returns the value that the return value represents if it does, otherwise it should not be called.
A JavaScript value.
Definition js_value.hpp:44
Represents a JavaScript exception.
Definition js_error.hpp:83