V8 Project
|
A PersistentBase which has move semantics. More...
#include <v8.h>
Classes | |
struct | RValue |
Public Member Functions | |
UniquePersistent () | |
A UniquePersistent with no storage cell. More... | |
template<class S > | |
UniquePersistent (Isolate *isolate, Handle< S > that) | |
Construct a UniquePersistent from a Handle. More... | |
template<class S > | |
UniquePersistent (Isolate *isolate, const PersistentBase< S > &that) | |
Construct a UniquePersistent from a PersistentBase. More... | |
UniquePersistent (RValue rvalue) | |
Move constructor. More... | |
~UniquePersistent () | |
template<class S > | |
UniquePersistent & | operator= (UniquePersistent< S > rhs) |
Move via assignment. More... | |
operator RValue () | |
Cast operator for moves. More... | |
UniquePersistent | Pass () |
Pass allows returning uniques from functions, etc. More... | |
![]() | |
void | Reset () |
If non-empty, destroy the underlying storage cell IsEmpty() will return true after this call. More... | |
template<class S > | |
void | Reset (Isolate *isolate, const Handle< S > &other) |
If non-empty, destroy the underlying storage cell and create a new one with the contents of other if other is non empty. More... | |
template<class S > | |
void | Reset (Isolate *isolate, const PersistentBase< S > &other) |
If non-empty, destroy the underlying storage cell and create a new one with the contents of other if other is non empty. More... | |
bool | IsEmpty () const |
template<class S > | |
bool | operator== (const PersistentBase< S > &that) const |
template<class S > | |
bool | operator== (const Handle< S > &that) const |
template<class S > | |
bool | operator!= (const PersistentBase< S > &that) const |
template<class S > | |
bool | operator!= (const Handle< S > &that) const |
template<typename P > | |
void | SetWeak (P *parameter, typename WeakCallbackData< T, P >::Callback callback) |
Install a finalization callback on this object. More... | |
template<typename S , typename P > | |
void | SetWeak (P *parameter, typename WeakCallbackData< S, P >::Callback callback) |
template<typename P > | |
P * | ClearWeak () |
void | ClearWeak () |
void | MarkIndependent () |
Marks the reference to this object independent. More... | |
void | MarkPartiallyDependent () |
Marks the reference to this object partially dependent. More... | |
bool | IsIndependent () const |
bool | IsNearDeath () const |
Checks if the handle holds the only reference to an object. More... | |
bool | IsWeak () const |
Returns true if the handle's reference is weak. More... | |
void | SetWrapperClassId (uint16_t class_id) |
Assigns a wrapper class ID to the handle. More... | |
uint16_t | WrapperClassId () const |
Returns the class ID previously assigned to this handle or 0 if no class ID was previously assigned. More... | |
Private Member Functions | |
UniquePersistent (UniquePersistent &) | |
void | operator= (UniquePersistent &) |
A PersistentBase which has move semantics.
Note: Persistent class hierarchy is subject to future changes.
|
inline |
A UniquePersistent with no storage cell.
Definition at line 733 of file v8.h.
Referenced by v8::UniquePersistent< T >::Pass().
|
inline |
Construct a UniquePersistent from a Handle.
When the Handle is non-empty, a new storage cell is created pointing to the same object, and no flags are set.
Definition at line 740 of file v8.h.
References S, T, and TYPE_CHECK.
|
inline |
Construct a UniquePersistent 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 750 of file v8.h.
References S, T, and TYPE_CHECK.
|
inline |
Move constructor.
Definition at line 757 of file v8.h.
References v8::UniquePersistent< T >::RValue::object, and v8::PersistentBase< T >::val_.
|
inline |
Definition at line 761 of file v8.h.
References v8::PersistentBase< T >::Reset().
|
private |
|
inline |
|
private |
|
inline |
Move via assignment.
Definition at line 766 of file v8.h.
References v8::PersistentBase< T >::Reset(), S, T, TYPE_CHECK, and v8::PersistentBase< T >::val_.
|
inline |
Pass allows returning uniques from functions, etc.
Definition at line 780 of file v8.h.
References v8::UniquePersistent< T >::UniquePersistent().
Referenced by v8::PersistentValueMap< K, V, Traits >::Release().