V8 Project
v8::ScriptCompiler::StreamedSource Class Reference

Source code which can be streamed into V8 in pieces. More...

#include <v8.h>

+ Collaboration diagram for v8::ScriptCompiler::StreamedSource:

Public Types

enum  Encoding { ONE_BYTE , TWO_BYTE , UTF8 }
 

Public Member Functions

 StreamedSource (ExternalSourceStream *source_stream, Encoding encoding)
 
 ~StreamedSource ()
 
const CachedDataGetCachedData () const
 
internal::StreamedSourceimpl () const
 

Private Member Functions

 StreamedSource (const StreamedSource &)
 
StreamedSourceoperator= (const StreamedSource &)
 

Private Attributes

internal::StreamedSourceimpl_
 

Detailed Description

Source code which can be streamed into V8 in pieces.

It will be parsed while streaming. It can be compiled after the streaming is complete. StreamedSource must be kept alive while the streaming task is ran (see ScriptStreamingTask below).

Definition at line 1127 of file v8.h.

Member Enumeration Documentation

◆ Encoding

Enumerator
ONE_BYTE 
TWO_BYTE 
UTF8 

Definition at line 1129 of file v8.h.

Constructor & Destructor Documentation

◆ StreamedSource() [1/2]

v8::ScriptCompiler::StreamedSource::StreamedSource ( ExternalSourceStream source_stream,
Encoding  encoding 
)

Definition at line 1569 of file api.cc.

1571  : impl_(new i::StreamedSource(stream, encoding)) {}
internal::StreamedSource * impl_
Definition: v8.h:1146

◆ ~StreamedSource()

v8::ScriptCompiler::StreamedSource::~StreamedSource ( )

Definition at line 1574 of file api.cc.

1574 { delete impl_; }

◆ StreamedSource() [2/2]

v8::ScriptCompiler::StreamedSource::StreamedSource ( const StreamedSource )
private

Member Function Documentation

◆ GetCachedData()

const ScriptCompiler::CachedData * v8::ScriptCompiler::StreamedSource::GetCachedData ( ) const

Definition at line 1578 of file api.cc.

1578  {
1579  return impl_->cached_data.get();
1580 }
SmartPointer< ScriptCompiler::CachedData > cached_data

◆ impl()

internal::StreamedSource* v8::ScriptCompiler::StreamedSource::impl ( ) const
inline

Definition at line 1139 of file v8.h.

1139 { return impl_; }

Referenced by v8::ScriptCompiler::Compile(), and v8::ScriptCompiler::StartStreamingScript().

+ Here is the caller graph for this function:

◆ operator=()

StreamedSource& v8::ScriptCompiler::StreamedSource::operator= ( const StreamedSource )
private

Member Data Documentation

◆ impl_

internal::StreamedSource* v8::ScriptCompiler::StreamedSource::impl_
private

Definition at line 1146 of file v8.h.


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