Loading...
Searching...
No Matches
v8-json.h
Go to the documentation of this file.
1// Copyright 2021 the V8 project authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef INCLUDE_V8_JSON_H_
6#define INCLUDE_V8_JSON_H_
7
8#include <optional>
9
10#include "v8-local-handle.h" // NOLINT(build/include_directory)
11#include "v8-message.h" // NOLINT(build/include_directory)
12#include "v8config.h" // NOLINT(build/include_directory)
13
14namespace v8 {
15
16class Context;
17class Value;
18class String;
19
24 public:
37 Local<Context> context, Local<String> json_string,
38 std::optional<ScriptOrigin> origin = std::nullopt);
39
48 Local<Context> context, Local<Value> json_object,
50};
51
52} // namespace v8
53
54#endif // INCLUDE_V8_JSON_H_
Definition: v8-json.h:23
static MaybeLocal< Value > Parse(Local< Context > context, Local< String > json_string, std::optional< ScriptOrigin > origin=std::nullopt)
static MaybeLocal< String > Stringify(Local< Context > context, Local< Value > json_object, Local< String > gap=Local< String >())
Definition: v8-local-handle.h:366
Definition: v8-local-handle.h:734
Definition: libplatform.h:15
#define V8_EXPORT
Definition: v8config.h:849
#define V8_WARN_UNUSED_RESULT
Definition: v8config.h:684