N|Solid
Public Types | Public Member Functions | List of all members
node::nsolid::Snapshot Class Reference

class that allows taking heap snapshots from a specific JS thread. More...

#include <nsolid.h>

Public Types

using snapshot_proxy_sig = void(*)(int, std::string, void *)
 

Public Member Functions

template<typename Cb , typename... Data>
int TakeSnapshot (uint64_t thread_id, Cb &&cb, Data &&... data)
 allows taking a heap snapshot from a specific JS thread. Only 1 concurrent snapshot per thread can be taken. More...
 

Detailed Description

class that allows taking heap snapshots from a specific JS thread.

Member Function Documentation

◆ TakeSnapshot()

template<typename Cb , typename... Data>
int node::nsolid::Snapshot::TakeSnapshot ( uint64_t  thread_id,
Cb &&  cb,
Data &&...  data 
)

allows taking a heap snapshot from a specific JS thread. Only 1 concurrent snapshot per thread can be taken.

Parameters
thread_idJS thread to take the snapshot from.
cbcallback function with the following signature: cb(int status, std::string snapshot, ...Data)
datavariable number of arguments to be propagated to the callback.
Returns
NSOLID_E_SUCCESS in case of success or a different NSOLID_E_ error value otherwise.

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