| Index: src/api-natives.h
|
| diff --git a/src/api-natives.h b/src/api-natives.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..8f93d6415daa784ca29faa40104c5597859b43a2
|
| --- /dev/null
|
| +++ b/src/api-natives.h
|
| @@ -0,0 +1,38 @@
|
| +// Copyright 2015 the V8 project authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef V8_API_NATIVES_H_
|
| +#define V8_API_NATIVES_H_
|
| +
|
| +#include "src/handles.h"
|
| +
|
| +namespace v8 {
|
| +namespace internal {
|
| +
|
| +class ApiNatives {
|
| + public:
|
| + MUST_USE_RESULT static MaybeHandle<JSFunction> InstantiateFunction(
|
| + Handle<FunctionTemplateInfo> data);
|
| + MUST_USE_RESULT static MaybeHandle<JSObject> InstantiateObject(
|
| + Handle<ObjectTemplateInfo> data);
|
| + MUST_USE_RESULT static MaybeHandle<FunctionTemplateInfo> ConfigureInstance(
|
| + Isolate* isolate, Handle<FunctionTemplateInfo> instance,
|
| + Handle<JSObject> data);
|
| +
|
| + enum ApiInstanceType {
|
| + JavaScriptObjectType,
|
| + GlobalObjectType,
|
| + GlobalProxyType
|
| + };
|
| +
|
| + static Handle<JSFunction> CreateApiFunction(Isolate* isolate,
|
| + Handle<FunctionTemplateInfo> obj,
|
| + Handle<Object> prototype,
|
| + ApiInstanceType instance_type);
|
| +};
|
| +
|
| +} // namespace internal
|
| +} // namespace v8
|
| +
|
| +#endif
|
|
|