v8  7.0.276 (node 11.14.0)
V8 is Google's open source JavaScript engine
Global< T > Class Template Reference

#include <v8.h>

Inheritance diagram for Global< T >:
Collaboration diagram for Global< T >:

Public Types

typedef void MoveOnlyTypeForCPP03
 

Public Member Functions

V8_INLINE Global ()
 
template<class S >
V8_INLINE Global (Isolate *isolate, Local< S > that)
 
template<class S >
V8_INLINE Global (Isolate *isolate, const PersistentBase< S > &that)
 
V8_INLINE Global (Global &&other)
 
V8_INLINE ~Global ()
 
template<class S >
V8_INLINE Globaloperator= (Global< S > &&rhs)
 
Global Pass ()
 
 Global (const Global &)=delete
 
void operator= (const Global &)=delete
 
- Public Member Functions inherited from PersistentBase< T >
V8_INLINE void Reset ()
 
template<class S >
V8_INLINE void Reset (Isolate *isolate, const Local< S > &other)
 
template<class S >
V8_INLINE void Reset (Isolate *isolate, const PersistentBase< S > &other)
 
V8_INLINE bool IsEmpty () const
 
V8_INLINE void Empty ()
 
V8_INLINE Local< T > Get (Isolate *isolate) const
 
template<class S >
V8_INLINE bool operator== (const PersistentBase< S > &that) const
 
template<class S >
V8_INLINE bool operator== (const Local< S > &that) const
 
template<class S >
V8_INLINE bool operator!= (const PersistentBase< S > &that) const
 
template<class S >
V8_INLINE bool operator!= (const Local< S > &that) const
 
template<typename P >
V8_INLINE void SetWeak (P *parameter, typename WeakCallbackInfo< P >::Callback callback, WeakCallbackType type)
 
V8_INLINE void SetWeak ()
 
template<typename P >
V8_INLINE P * ClearWeak ()
 
V8_INLINE void ClearWeak ()
 
V8_INLINE void AnnotateStrongRetainer (const char *label)
 
V8_INLINE void RegisterExternalReference (Isolate *isolate) const
 
 V8_DEPRECATE_SOON ("Objects are always considered independent. " "Use MarkActive to avoid collecting otherwise dead weak handles.", V8_INLINE void MarkIndependent())
 
V8_INLINE void MarkActive ()
 
 V8_DEPRECATE_SOON ("See MarkIndependent.", V8_INLINE bool IsIndependent() const)
 
V8_INLINE bool IsNearDeath () const
 
V8_INLINE bool IsWeak () const
 
V8_INLINE void SetWrapperClassId (uint16_t class_id)
 
V8_INLINE uint16_t WrapperClassId () const
 
 PersistentBase (const PersistentBase &other)=delete
 
void operator= (const PersistentBase &)=delete
 

Friends

template<class F >
class ReturnValue
 

Detailed Description

template<class T>
class v8::Global< T >

A PersistentBase which has move semantics.

Note: Persistent class hierarchy is subject to future changes.

Definition at line 878 of file v8.h.

Member Typedef Documentation

◆ MoveOnlyTypeForCPP03

typedef void MoveOnlyTypeForCPP03

Definition at line 932 of file v8.h.

Constructor & Destructor Documentation

◆ Global() [1/5]

V8_INLINE Global ( )
inline

A Global with no storage cell.

Definition at line 883 of file v8.h.

References Local< T >::PersistentBase.

◆ Global() [2/5]

V8_INLINE Global ( Isolate isolate,
Local< S >  that 
)
inline

Construct a Global from a Local. When the Local is non-empty, a new storage cell is created pointing to the same object, and no flags are set.

Definition at line 890 of file v8.h.

References Local< T >::PersistentBase.

◆ Global() [3/5]

V8_INLINE Global ( Isolate isolate,
const PersistentBase< S > &  that 
)
inline

Construct a Global from a PersistentBase. When the Persistent is non-empty, a new storage cell is created pointing to the same object, and no flags are set.

Definition at line 900 of file v8.h.

References Local< T >::PersistentBase.

◆ Global() [4/5]

V8_INLINE Global ( Global< T > &&  other)
inline

Move constructor.

Definition at line 907 of file v8.h.

References Local< T >::PersistentBase.

◆ ~Global()

V8_INLINE ~Global ( )
inline

Definition at line 910 of file v8.h.

◆ Global() [5/5]

Global ( const Global< T > &  )
delete

Member Function Documentation

◆ operator=() [1/2]

void operator= ( const Global< T > &  )
delete

◆ operator=() [2/2]

V8_INLINE Global& operator= ( Global< S > &&  rhs)
inline

Move via assignment.

Definition at line 915 of file v8.h.

◆ Pass()

Global Pass ( )
inline

Pass allows returning uniques from functions, etc.

Definition at line 927 of file v8.h.

References PersistentBase< T >::Global.

Friends And Related Function Documentation

◆ ReturnValue

friend class ReturnValue
friend

Definition at line 939 of file v8.h.


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