v8  3.14.5(node0.10.28)
V8 is Google's open source JavaScript engine
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Message Class Reference

#include <v8.h>

Public Member Functions

Local< StringGet () const
 
Local< StringGetSourceLine () const
 
Handle< ValueGetScriptResourceName () const
 
Handle< ValueGetScriptData () const
 
Handle< StackTraceGetStackTrace () const
 
int GetLineNumber () const
 
int GetStartPosition () const
 
int GetEndPosition () const
 
int GetStartColumn () const
 
int GetEndColumn () const
 

Static Public Member Functions

static void PrintCurrentStackTrace (FILE *out)
 

Static Public Attributes

static const int kNoLineNumberInfo = 0
 
static const int kNoColumnInfo = 0
 

Detailed Description

An error message.

Definition at line 697 of file v8.h.

Member Function Documentation

Local< String > Get ( ) const

Definition at line 1781 of file api.cc.

References HandleScope::Close(), ENTER_V8, MessageHandler::GetMessage(), ON_BAILOUT, and Utils::ToLocal().

Referenced by main().

int GetEndColumn ( ) const

Returns the index within the line of the last character where the error occurred.

Definition at line 1928 of file api.cc.

References Handle< T >::cast(), ENTER_V8, EXCEPTION_BAILOUT_CHECK, EXCEPTION_PREAMBLE, Message::kNoColumnInfo, and message.

Referenced by main(), and ReportException().

int GetEndPosition ( ) const

Returns the index within the script of the last character where the error occurred.

Definition at line 1899 of file api.cc.

References Handle< T >::cast(), ENTER_V8, and message.

int GetLineNumber ( ) const

Returns the number, 1-based, of the line where the error occurred.

Definition at line 1873 of file api.cc.

References ENTER_V8, EXCEPTION_BAILOUT_CHECK, EXCEPTION_PREAMBLE, Message::kNoLineNumberInfo, and ON_BAILOUT.

Referenced by main(), and ReportException().

v8::Handle< Value > GetScriptData ( ) const

Returns the resource data for the script from where the function causing the error originates.

Definition at line 1810 of file api.cc.

References Handle< T >::cast(), Script::cast(), HandleScope::Close(), ENTER_V8, message, and Utils::ToLocal().

v8::Handle< Value > GetScriptResourceName ( ) const

Returns the resource name for the script from where the function causing the error originates.

Definition at line 1793 of file api.cc.

References Handle< T >::cast(), Script::cast(), HandleScope::Close(), ENTER_V8, message, and Utils::ToLocal().

Referenced by ReportException().

Local< String > GetSourceLine ( ) const
v8::Handle< v8::StackTrace > GetStackTrace ( ) const

Exception stack trace. By default stack traces are not captured for uncaught exceptions. SetCaptureStackTraceForUncaughtExceptions allows to change this option.

Definition at line 1827 of file api.cc.

References Handle< T >::cast(), HandleScope::Close(), ENTER_V8, message, and Utils::StackTraceToLocal().

int GetStartColumn ( ) const

Returns the index within the line of the first character where the error occurred.

Definition at line 1910 of file api.cc.

References ENTER_V8, EXCEPTION_BAILOUT_CHECK, EXCEPTION_PREAMBLE, and Message::kNoColumnInfo.

Referenced by main(), and ReportException().

int GetStartPosition ( ) const

Returns the index within the script of the first character where the error occurred.

Definition at line 1888 of file api.cc.

References Handle< T >::cast(), ENTER_V8, and message.

void PrintCurrentStackTrace ( FILE *  out)
static

Definition at line 1966 of file api.cc.

References ENTER_V8, and Isolate::PrintCurrentStackTrace().

Field Documentation

const int kNoColumnInfo = 0
static

Definition at line 754 of file v8.h.

Referenced by StackFrame::GetColumn(), Message::GetEndColumn(), and Message::GetStartColumn().

const int kNoLineNumberInfo = 0
static

Definition at line 753 of file v8.h.

Referenced by Message::GetLineNumber(), and StackFrame::GetLineNumber().


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