v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
v8::FunctionCallbackInfo< F > Class Template Reference

#include <v8-function-callback.h>

Collaboration diagram for v8::FunctionCallbackInfo< F >:

Public Member Functions

V8_INLINE int Length () const
 
V8_INLINE Local< Valueoperator[] (int i) const
 
V8_INLINE Local< ObjectThis () const
 
V8_INLINE Local< ValueNewTarget () const
 
V8_INLINE bool IsConstructCall () const
 
V8_INLINE Local< ValueData () const
 
V8_INLINE IsolateGetIsolate () const
 
V8_INLINE ReturnValue< TGetReturnValue () const
 

Private Member Functions

V8_INLINE FunctionCallbackInfo (internal::Address *implicit_args, internal::Address *values, int length)
 

Private Attributes

internal::Addressimplicit_args_
 
internal::Addressvalues_
 
internal::Address length_
 

Static Private Attributes

static constexpr int kUnusedIndex = 0
 
static constexpr int kIsolateIndex = 1
 
static constexpr int kContextIndex = 2
 
static constexpr int kReturnValueIndex = 3
 
static constexpr int kTargetIndex = 4
 
static constexpr int kNewTargetIndex = 5
 
static constexpr int kArgsLength = 6
 
static constexpr int kArgsLengthWithReceiver = kArgsLength + 1
 
static constexpr int kSize = 3 * internal::kApiSystemPointerSize
 
static constexpr int kImplicitArgsOffset = 0
 
static constexpr int kValuesOffset
 
static constexpr int kLengthOffset
 
static constexpr int kThisValuesIndex = -1
 

Friends

class internal::FunctionCallbackArguments
 
class internal::CustomArguments< FunctionCallbackInfo >
 
class debug::ConsoleCallArguments
 
void internal::PrintFunctionCallbackInfo (void *)
 

Detailed Description

template<class F>
class v8::FunctionCallbackInfo< F >

The argument information given to function call callbacks. This class provides access to information about the context of the call, including the receiver, the number and values of arguments, and the holder of the function.

Definition at line 49 of file v8-local-handle.h.

Constructor & Destructor Documentation

◆ FunctionCallbackInfo()

template<typename T >
v8::FunctionCallbackInfo< T >::FunctionCallbackInfo ( internal::Address * implicit_args,
internal::Address * values,
int length )
private

Definition at line 615 of file v8-function-callback.h.

Member Function Documentation

◆ Data()

template<typename T >
Local< Value > v8::FunctionCallbackInfo< T >::Data ( ) const

The data argument specified when creating the callback.

Definition at line 639 of file v8-function-callback.h.

Here is the call graph for this function:

◆ GetIsolate()

template<typename T >
Isolate * v8::FunctionCallbackInfo< T >::GetIsolate ( ) const

The current Isolate.

Definition at line 645 of file v8-function-callback.h.

◆ GetReturnValue()

template<typename T >
ReturnValue< T > v8::FunctionCallbackInfo< T >::GetReturnValue ( ) const

The ReturnValue for the call.

Definition at line 650 of file v8-function-callback.h.

◆ IsConstructCall()

template<typename T >
bool v8::FunctionCallbackInfo< T >::IsConstructCall ( ) const

Indicates whether this is a regular call or a construct call.

Definition at line 655 of file v8-function-callback.h.

◆ Length()

template<typename T >
int v8::FunctionCallbackInfo< T >::Length ( ) const

The number of available arguments.

Definition at line 660 of file v8-function-callback.h.

◆ NewTarget()

template<typename T >
Local< Value > v8::FunctionCallbackInfo< T >::NewTarget ( ) const

For construct calls, this returns the "new.target" value.

Definition at line 634 of file v8-function-callback.h.

Here is the call graph for this function:

◆ operator[]()

template<typename T >
Local< Value > v8::FunctionCallbackInfo< T >::operator[] ( int i) const

Accessor for the available arguments. Returns undefined if the index is out of bounds.

Definition at line 621 of file v8-function-callback.h.

Here is the call graph for this function:

◆ This()

template<typename T >
Local< Object > v8::FunctionCallbackInfo< T >::This ( ) const

Returns the receiver. This corresponds to the "this" value.

Definition at line 628 of file v8-function-callback.h.

Here is the call graph for this function:

Friends And Related Symbol Documentation

◆ debug::ConsoleCallArguments

template<class F >
friend class debug::ConsoleCallArguments
friend

Definition at line 143 of file v8-function-callback.h.

◆ internal::CustomArguments< FunctionCallbackInfo >

template<class F >
friend class internal::CustomArguments< FunctionCallbackInfo >
friend

Definition at line 141 of file v8-function-callback.h.

◆ internal::FunctionCallbackArguments

template<class F >
friend class internal::FunctionCallbackArguments
friend

Definition at line 141 of file v8-function-callback.h.

◆ internal::PrintFunctionCallbackInfo

template<class F >
void internal::PrintFunctionCallbackInfo ( void * )
friend

Member Data Documentation

◆ implicit_args_

template<class F >
internal::Address* v8::FunctionCallbackInfo< F >::implicit_args_
private

Definition at line 177 of file v8-function-callback.h.

◆ kArgsLength

template<class F >
int v8::FunctionCallbackInfo< F >::kArgsLength = 6
staticconstexprprivate

Definition at line 155 of file v8-function-callback.h.

◆ kArgsLengthWithReceiver

template<class F >
int v8::FunctionCallbackInfo< F >::kArgsLengthWithReceiver = kArgsLength + 1
staticconstexprprivate

Definition at line 157 of file v8-function-callback.h.

◆ kContextIndex

template<class F >
int v8::FunctionCallbackInfo< F >::kContextIndex = 2
staticconstexprprivate

Definition at line 151 of file v8-function-callback.h.

◆ kImplicitArgsOffset

template<class F >
int v8::FunctionCallbackInfo< F >::kImplicitArgsOffset = 0
staticconstexprprivate

Definition at line 161 of file v8-function-callback.h.

◆ kIsolateIndex

template<class F >
int v8::FunctionCallbackInfo< F >::kIsolateIndex = 1
staticconstexprprivate

Definition at line 150 of file v8-function-callback.h.

◆ kLengthOffset

template<class F >
int v8::FunctionCallbackInfo< F >::kLengthOffset
staticconstexprprivate
Initial value:

Definition at line 164 of file v8-function-callback.h.

◆ kNewTargetIndex

template<class F >
int v8::FunctionCallbackInfo< F >::kNewTargetIndex = 5
staticconstexprprivate

Definition at line 154 of file v8-function-callback.h.

◆ kReturnValueIndex

template<class F >
int v8::FunctionCallbackInfo< F >::kReturnValueIndex = 3
staticconstexprprivate

Definition at line 152 of file v8-function-callback.h.

◆ kSize

template<class F >
int v8::FunctionCallbackInfo< F >::kSize = 3 * internal::kApiSystemPointerSize
staticconstexprprivate

Definition at line 160 of file v8-function-callback.h.

◆ kTargetIndex

template<class F >
int v8::FunctionCallbackInfo< F >::kTargetIndex = 4
staticconstexprprivate

Definition at line 153 of file v8-function-callback.h.

◆ kThisValuesIndex

template<class F >
int v8::FunctionCallbackInfo< F >::kThisValuesIndex = -1
staticconstexprprivate

Definition at line 167 of file v8-function-callback.h.

◆ kUnusedIndex

template<class F >
int v8::FunctionCallbackInfo< F >::kUnusedIndex = 0
staticconstexprprivate

Definition at line 149 of file v8-function-callback.h.

◆ kValuesOffset

template<class F >
int v8::FunctionCallbackInfo< F >::kValuesOffset
staticconstexprprivate
Initial value:

Definition at line 162 of file v8-function-callback.h.

◆ length_

template<class F >
internal::Address v8::FunctionCallbackInfo< F >::length_
private

Definition at line 179 of file v8-function-callback.h.

◆ values_

template<class F >
internal::Address* v8::FunctionCallbackInfo< F >::values_
private

Definition at line 178 of file v8-function-callback.h.


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