V8 Project
v8::LineEditor Class Referenceabstract

#include <d8.h>

+ Inheritance diagram for v8::LineEditor:
+ Collaboration diagram for v8::LineEditor:

Public Types

enum  Type { DUMB = 0 , READLINE = 1 }
 

Public Member Functions

 LineEditor (Type type, const char *name)
 
virtual ~LineEditor ()
 
virtual Handle< StringPrompt (const char *prompt)=0
 
virtual bool Open (Isolate *isolate)
 
virtual bool Close ()
 
virtual void AddHistory (const char *str)
 
const char * name ()
 

Static Public Member Functions

static LineEditorGet ()
 

Private Attributes

Type type_
 
const char * name_
 

Static Private Attributes

static LineEditorcurrent_ = NULL
 

Detailed Description

Definition at line 97 of file d8.h.

Member Enumeration Documentation

◆ Type

Enumerator
DUMB 
READLINE 

Definition at line 99 of file d8.h.

99 { DUMB = 0, READLINE = 1 };
@ DUMB
Definition: d8.h:99
@ READLINE
Definition: d8.h:99

Constructor & Destructor Documentation

◆ LineEditor()

v8::LineEditor::LineEditor ( Type  type,
const char *  name 
)

Definition at line 120 of file d8.cc.

121  : type_(type), name_(name) {
122  if (current_ == NULL || current_->type_ < type) current_ = this;
123 }
const char * name_
Definition: d8.h:112
const char * name()
Definition: d8.h:108
Type type_
Definition: d8.h:111
static LineEditor * current_
Definition: d8.h:113
enable harmony numeric enable harmony object literal extensions Optimize object Array DOM strings and string trace pretenuring decisions of HAllocate instructions Enables optimizations which favor memory size over execution speed maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining trace the tracking of allocation sites deoptimize every n garbage collections perform array bounds checks elimination analyze liveness of environment slots and zap dead values flushes the cache of optimized code for closures on every GC allow uint32 values on optimize frames if they are used only in safe operations track concurrent recompilation artificial compilation delay in ms do not emit check maps for constant values that have a leaf deoptimize the optimized code if the layout of the maps changes enable context specialization in TurboFan execution budget before interrupt is triggered max percentage of megamorphic generic ICs to allow optimization enable use of SAHF instruction if enable use of VFP3 instructions if available enable use of NEON instructions if enable use of SDIV and UDIV instructions if enable use of MLS instructions if enable loading bit constant by means of movw movt instruction enable unaligned accesses for enable use of d16 d31 registers on ARM this requires VFP3 force all emitted branches to be in long enable alignment of csp to bytes on platforms which prefer the register to always be NULL

References current_, NULL, and type_.

◆ ~LineEditor()

virtual v8::LineEditor::~LineEditor ( )
inlinevirtual

Definition at line 101 of file d8.h.

101 { }

Member Function Documentation

◆ AddHistory()

virtual void v8::LineEditor::AddHistory ( const char *  str)
inlinevirtual

Reimplemented in v8::ReadLineEditor.

Definition at line 106 of file d8.h.

106 { }

◆ Close()

virtual bool v8::LineEditor::Close ( )
inlinevirtual

Reimplemented in v8::ReadLineEditor.

Definition at line 105 of file d8.h.

105 { return true; }

Referenced by v8::Shell::OnExit().

+ Here is the caller graph for this function:

◆ Get()

static LineEditor* v8::LineEditor::Get ( )
inlinestatic

Definition at line 109 of file d8.h.

109 { return current_; }

References current_.

Referenced by v8::Shell::OnExit(), and v8::Shell::RunShell().

+ Here is the caller graph for this function:

◆ name()

const char* v8::LineEditor::name ( )
inline

Definition at line 108 of file d8.h.

108 { return name_; }

References name_.

Referenced by v8::Shell::RunShell().

+ Here is the caller graph for this function:

◆ Open()

virtual bool v8::LineEditor::Open ( Isolate isolate)
inlinevirtual

Reimplemented in v8::ReadLineEditor.

Definition at line 104 of file d8.h.

104 { return true; }

Referenced by v8::Shell::RunShell().

+ Here is the caller graph for this function:

◆ Prompt()

virtual Handle<String> v8::LineEditor::Prompt ( const char *  prompt)
pure virtual

Implemented in v8::DumbLineEditor, and v8::ReadLineEditor.

Referenced by v8::Shell::RunShell().

+ Here is the caller graph for this function:

Member Data Documentation

◆ current_

LineEditor * v8::LineEditor::current_ = NULL
staticprivate

Definition at line 113 of file d8.h.

Referenced by Get(), and LineEditor().

◆ name_

const char* v8::LineEditor::name_
private

Definition at line 112 of file d8.h.

Referenced by name().

◆ type_

Type v8::LineEditor::type_
private

Definition at line 111 of file d8.h.

Referenced by LineEditor().


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