V8 API Reference Guide for node.js v9.9.0
Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | Static Protected Attributes | Friends | List of all members
v8::FunctionCallbackInfo< T > Class Template Reference

#include <v8.h>

Public Member Functions

V8_INLINE int Length () const
V8_INLINE Local< Valueoperator[] (int i) const
V8_INLINE V8_DEPRECATED ("Use Data() to explicitly pass Callee instead", Local< Function > Callee() const)
V8_INLINE Local< ObjectThis () const
V8_INLINE Local< ObjectHolder () const
V8_INLINE Local< ValueNewTarget () const
V8_INLINE bool IsConstructCall () const
V8_INLINE Local< ValueData () const
V8_INLINE IsolateGetIsolate () const
V8_INLINE ReturnValue< T > GetReturnValue () const

Static Public Attributes

static const int kArgsLength = 8

Protected Member Functions

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

Protected Attributes

internal::Object ** implicit_args_
internal::Object ** values_
int length_

Static Protected Attributes

static const int kHolderIndex = 0
static const int kIsolateIndex = 1
static const int kReturnValueDefaultValueIndex = 2
static const int kReturnValueIndex = 3
static const int kDataIndex = 4
static const int kCalleeIndex = 5
static const int kContextSaveIndex = 6
static const int kNewTargetIndex = 7


class internal::FunctionCallbackArguments
class internal::CustomArguments< FunctionCallbackInfo >
class debug::ConsoleCallArguments

Detailed Description

template<typename T>
class v8::FunctionCallbackInfo< T >

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.

Member Function Documentation

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

The data argument specified when creating the callback.

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

The current Isolate.

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

The ReturnValue for the call.

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

If the callback was created without a Signature, this is the same value as This(). If there is a signature, and the signature didn't match This() but one of its hidden prototypes, this will be the respective hidden prototype.

Note that this is not the prototype of This() on which the accessor referencing this callback was found (which in V8 internally is often referred to as holder [sic]).

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

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

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

The number of available arguments.

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

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

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

Accessor for the available arguments.

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

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

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