V8 API Reference Guide generated from the header files
Public Types | Public Member Functions
v8::GlobalValueMap< K, V, Traits > Class Template Reference
Inheritance diagram for v8::GlobalValueMap< K, V, Traits >:
v8::PersistentValueMapBase< K, V, Traits > v8::StdGlobalValueMap< K, V, Traits >

Public Types

typedef PersistentValueMapBase< K, V, Traits >::PersistentValueReference PersistentValueReference
 

Public Member Functions

 GlobalValueMap (Isolate *isolate)
 
Global< V > Set (const K &key, Local< V > value)
 
Global< V > Set (const K &key, Global< V > value)
 
Global< V > SetUnique (const K &key, Global< V > *persistent)
 
Global< V > Set (const K &key, Global< V > value, PersistentValueReference *reference)
 
- Public Member Functions inherited from v8::PersistentValueMapBase< K, V, Traits >
IsolateGetIsolate ()
 
size_t Size ()
 
bool IsWeak ()
 
Local< V > Get (const K &key)
 
bool Contains (const K &key)
 
bool SetReturnValue (const K &key, ReturnValue< Value > returnValue)
 
void RegisterExternallyReferencedObject (K &key)
 
Global< V > Remove (const K &key)
 
void Clear ()
 
PersistentValueReference GetReference (const K &key)
 

Additional Inherited Members

- Protected Member Functions inherited from v8::PersistentValueMapBase< K, V, Traits >
 PersistentValueMapBase (Isolate *isolate)
 
Isolateisolate ()
 
Traits::Impl * impl ()
 
void RemoveWeak (const K &key)
 
- Static Protected Member Functions inherited from v8::PersistentValueMapBase< K, V, Traits >
static V * FromVal (PersistentContainerValue v)
 
static PersistentContainerValue ClearAndLeak (Global< V > *persistent)
 
static PersistentContainerValue Leak (Global< V > *persistent)
 
static Global< V > Release (PersistentContainerValue v)
 

Member Function Documentation

◆ Set() [1/3]

template<typename K , typename V , typename Traits >
Global<V> v8::GlobalValueMap< K, V, Traits >::Set ( const K &  key,
Local< V >  value 
)
inline

Put value into map. Depending on Traits::kIsWeak, the value will be held by the map strongly or weakly. Returns old value as Global.

◆ Set() [2/3]

template<typename K , typename V , typename Traits >
Global<V> v8::GlobalValueMap< K, V, Traits >::Set ( const K &  key,
Global< V >  value 
)
inline

Put value into map, like Set(const K&, Local<V>).

◆ Set() [3/3]

template<typename K , typename V , typename Traits >
Global<V> v8::GlobalValueMap< K, V, Traits >::Set ( const K &  key,
Global< V >  value,
PersistentValueReference reference 
)
inline

Put a value into the map and update the reference. Restrictions of GetReference apply here as well.

◆ SetUnique()

template<typename K , typename V , typename Traits >
Global<V> v8::GlobalValueMap< K, V, Traits >::SetUnique ( const K &  key,
Global< V > *  persistent 
)
inline

Put the value into the map, and set the 'weak' callback when demanded by the Traits class.


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