v8 10.2.154 (node 18.16.0)
V8 is Google's open source JavaScript engine
Loading...
Searching...
No Matches
v8-date.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_DATE_H_
6#define INCLUDE_V8_DATE_H_
7
8#include "v8-local-handle.h" // NOLINT(build/include_directory)
9#include "v8-object.h" // NOLINT(build/include_directory)
10#include "v8config.h" // NOLINT(build/include_directory)
11
12namespace v8 {
13
14class Context;
15
19class V8_EXPORT Date : public Object {
20 public:
22 double time);
23
28 double ValueOf() const;
29
30 V8_INLINE static Date* Cast(Value* value) {
31#ifdef V8_ENABLE_CHECKS
32 CheckCast(value);
33#endif
34 return static_cast<Date*>(value);
35 }
36
37 private:
38 static void CheckCast(Value* obj);
39};
40
41} // namespace v8
42
43#endif // INCLUDE_V8_DATE_H_
static V8_INLINE Date * Cast(Value *value)
Definition v8-date.h:30
static V8_WARN_UNUSED_RESULT MaybeLocal< Value > New(Local< Context > context, double time)
double ValueOf() const
#define V8_EXPORT
Definition v8config.h:578
#define V8_INLINE
Definition v8config.h:425
#define V8_WARN_UNUSED_RESULT
Definition v8config.h:499