v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
v8::internal::StringStream Class Referencefinal

#include <string-stream.h>

Collaboration diagram for v8::internal::StringStream:

Classes

class  FmtElm
 

Public Types

enum  ObjectPrintMode { kPrintObjectConcise , kPrintObjectVerbose }
 

Public Member Functions

 StringStream (StringAllocator *allocator, ObjectPrintMode object_print_mode=kPrintObjectVerbose)
 
bool Put (char c)
 
bool Put (Tagged< String > str)
 
bool Put (Tagged< String > str, int start, int end)
 
void Add (const char *format)
 
void Add (base::Vector< const char > format)
 
template<typename... Args>
void Add (const char *format, Args... args)
 
template<typename... Args>
void Add (base::Vector< const char > format, Args... args)
 
void OutputToFile (FILE *out)
 
void OutputToStdOut ()
 
void Log (Isolate *isolate)
 
DirectHandle< StringToString (Isolate *isolate)
 
std::unique_ptr< char[]> ToCString () const
 
int length () const
 
void PrintName (Tagged< Object > o)
 
void PrintFixedArray (Tagged< FixedArray > array, unsigned int limit)
 
void PrintByteArray (Tagged< ByteArray > ba)
 
void PrintUsingMap (Isolate *isolate, Tagged< JSObject > js_object)
 
void PrintPrototype (Isolate *isolate, Tagged< JSFunction > fun, Tagged< Object > receiver)
 
void PrintSecurityTokenIfChanged (Isolate *isolate, Tagged< JSFunction > function)
 
void PrintFunction (Isolate *isolate, Tagged< JSFunction > function, Tagged< Object > receiver)
 
void Reset ()
 
void PrintMentionedObjectCache (Isolate *isolate)
 

Static Public Member Functions

static V8_EXPORT_PRIVATE void ClearMentionedObjectCache (Isolate *isolate)
 

Static Public Attributes

static const int kInitialCapacity = 16
 

Private Member Functions

void Add (base::Vector< const char > format, base::Vector< FmtElm > elms)
 
void PrintObject (Tagged< Object > obj)
 
bool full () const
 
int space () const
 
 DISALLOW_IMPLICIT_CONSTRUCTORS (StringStream)
 

Private Attributes

StringAllocatorallocator_
 
ObjectPrintMode object_print_mode_
 
unsigned capacity_
 
unsigned length_
 
char * buffer_
 

Detailed Description

Definition at line 91 of file string-stream.h.

Member Enumeration Documentation

◆ ObjectPrintMode

Enumerator
kPrintObjectConcise 
kPrintObjectVerbose 

Definition at line 142 of file string-stream.h.

Constructor & Destructor Documentation

◆ StringStream()

v8::internal::StringStream::StringStream ( StringAllocator * allocator,
ObjectPrintMode object_print_mode = kPrintObjectVerbose )
inlineexplicit

Definition at line 143 of file string-stream.h.

Member Function Documentation

◆ Add() [1/5]

void v8::internal::StringStream::Add ( base::Vector< const char > format)
inline

Definition at line 157 of file string-stream.h.

Here is the call graph for this function:

◆ Add() [2/5]

template<typename... Args>
void v8::internal::StringStream::Add ( base::Vector< const char > format,
Args... args )
inline

Definition at line 167 of file string-stream.h.

Here is the call graph for this function:

◆ Add() [3/5]

void v8::internal::StringStream::Add ( base::Vector< const char > format,
base::Vector< FmtElm > elms )
private

Definition at line 88 of file string-stream.cc.

Here is the call graph for this function:

◆ Add() [4/5]

void v8::internal::StringStream::Add ( const char * format)
inline

Definition at line 156 of file string-stream.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Add() [5/5]

template<typename... Args>
void v8::internal::StringStream::Add ( const char * format,
Args... args )
inline

Definition at line 162 of file string-stream.h.

Here is the call graph for this function:

◆ ClearMentionedObjectCache()

void v8::internal::StringStream::ClearMentionedObjectCache ( Isolate * isolate)
static

Definition at line 256 of file string-stream.cc.

Here is the caller graph for this function:

◆ DISALLOW_IMPLICIT_CONSTRUCTORS()

v8::internal::StringStream::DISALLOW_IMPLICIT_CONSTRUCTORS ( StringStream )
private

◆ full()

bool v8::internal::StringStream::full ( ) const
inlineprivate

Definition at line 217 of file string-stream.h.

Here is the caller graph for this function:

◆ length()

int v8::internal::StringStream::length ( ) const
inline

Definition at line 178 of file string-stream.h.

Here is the caller graph for this function:

◆ Log()

void v8::internal::StringStream::Log ( Isolate * isolate)

Definition at line 231 of file string-stream.cc.

Here is the caller graph for this function:

◆ OutputToFile()

void v8::internal::StringStream::OutputToFile ( FILE * out)

Definition at line 235 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ OutputToStdOut()

void v8::internal::StringStream::OutputToStdOut ( )
inline

Definition at line 174 of file string-stream.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PrintByteArray()

void v8::internal::StringStream::PrintByteArray ( Tagged< ByteArray > ba)

Definition at line 346 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PrintFixedArray()

void v8::internal::StringStream::PrintFixedArray ( Tagged< FixedArray > array,
unsigned int limit )

Definition at line 330 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PrintFunction()

void v8::internal::StringStream::PrintFunction ( Isolate * isolate,
Tagged< JSFunction > function,
Tagged< Object > receiver )

Definition at line 413 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PrintMentionedObjectCache()

void v8::internal::StringStream::PrintMentionedObjectCache ( Isolate * isolate)

Definition at line 367 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PrintName()

void v8::internal::StringStream::PrintName ( Tagged< Object > o)

Definition at line 289 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PrintObject()

void v8::internal::StringStream::PrintObject ( Tagged< Object > obj)
private

Definition at line 194 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PrintPrototype()

void v8::internal::StringStream::PrintPrototype ( Isolate * isolate,
Tagged< JSFunction > fun,
Tagged< Object > receiver )

Definition at line 418 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PrintSecurityTokenIfChanged()

void v8::internal::StringStream::PrintSecurityTokenIfChanged ( Isolate * isolate,
Tagged< JSFunction > function )

Definition at line 403 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PrintUsingMap()

void v8::internal::StringStream::PrintUsingMap ( Isolate * isolate,
Tagged< JSObject > js_object )

Definition at line 302 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Put() [1/3]

bool v8::internal::StringStream::Put ( char c)

Definition at line 36 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Put() [2/3]

bool v8::internal::StringStream::Put ( Tagged< String > str)

Definition at line 271 of file string-stream.cc.

Here is the call graph for this function:

◆ Put() [3/3]

bool v8::internal::StringStream::Put ( Tagged< String > str,
int start,
int end )

Definition at line 275 of file string-stream.cc.

Here is the call graph for this function:

◆ Reset()

void v8::internal::StringStream::Reset ( )
inline

Definition at line 193 of file string-stream.h.

◆ space()

int v8::internal::StringStream::space ( ) const
inlineprivate

Definition at line 218 of file string-stream.h.

◆ ToCString()

std::unique_ptr< char[]> v8::internal::StringStream::ToCString ( ) const

Definition at line 224 of file string-stream.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ToString()

DirectHandle< String > v8::internal::StringStream::ToString ( Isolate * isolate)

Definition at line 250 of file string-stream.cc.

Here is the caller graph for this function:

Member Data Documentation

◆ allocator_

StringAllocator* v8::internal::StringStream::allocator_
private

Definition at line 211 of file string-stream.h.

◆ buffer_

char* v8::internal::StringStream::buffer_
private

Definition at line 215 of file string-stream.h.

◆ capacity_

unsigned v8::internal::StringStream::capacity_
private

Definition at line 213 of file string-stream.h.

◆ kInitialCapacity

const int v8::internal::StringStream::kInitialCapacity = 16
static

Definition at line 205 of file string-stream.h.

◆ length_

unsigned v8::internal::StringStream::length_
private

Definition at line 214 of file string-stream.h.

◆ object_print_mode_

ObjectPrintMode v8::internal::StringStream::object_print_mode_
private

Definition at line 212 of file string-stream.h.


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