*/
class JsHttpRequestProcessor : public HttpRequestProcessor {
public:
-
// Creates a new processor that processes requests by invoking the
// Process function of the JavaScript script given as an argument.
explicit JsHttpRequestProcessor(Handle<String> script) : script_(script) { }
virtual bool Process(HttpRequest* req);
private:
-
// Execute the script associated with this processor and extract the
// Process function. Returns true if this succeeded, otherwise false.
bool ExecuteScript(Handle<String> script);
} while (next_function != NULL);
return false;
}
+
private:
void GetFunctions() {
functions_.Rewind(0);
int length() const { return length_; }
Object** arguments() { return arguments_; }
+
private:
int length_;
Object** arguments_;
class LGapResolver BASE_EMBEDDED {
public:
-
explicit LGapResolver(LCodeGen* owner);
// Resolve a set of parallel moves, emitting assembler instructions.
static int CheckStackGuardState(Address* return_address,
Code* re_code,
Address re_frame);
+
private:
// Offsets from frame_pointer() of function parameters and stored registers.
static const int kFramePointer = 0;
static bool PlusLess(const Bignum& a, const Bignum& b, const Bignum& c) {
return PlusCompare(a, b, c) < 0;
}
+
private:
typedef uint32_t Chunk;
typedef uint64_t DoubleChunk;
class PowersOfTenCache {
public:
-
// Not all powers of ten are cached. The decimal exponent of two neighboring
// cached numbers will differ by kDecimalExponentDistance.
static const int kDecimalExponentDistance;
// cache during debugging to make sure new scripts are always compiled.
void Enable();
void Disable();
+
private:
explicit CompilationCache(Isolate* isolate);
~CompilationCache();
static const unsigned kMaxArgs = 1000;
char** arg_array() { return exec_args_; }
char* arg0() { return exec_args_[0]; }
+
private:
char* exec_args_[kMaxArgs + 1];
};
#else
class Shell : public i::AllStatic {
#endif // V8_SHARED
+
public:
static bool ExecuteString(Handle<String> source,
Handle<Value> name,
class DateParser : public AllStatic {
public:
-
// Parse the string as a date. If parsing succeeds, return true after
// filling out the output array as follows (all integers are Smis):
// [0]: year
static DateToken Invalid() {
return DateToken(kInvalidTokenTag, 0, -1);
}
+
private:
enum TagType {
kInvalidTokenTag = -6,
}
return false;
}
+
private:
DateToken Scan();
static bool IsMinute(int x) { return Between(x, 0, 59); }
static bool IsHour(int x) { return Between(x, 0, 23); }
static bool IsSecond(int x) { return Between(x, 0, 59); }
+
private:
static bool IsHour12(int x) { return Between(x, 0, 12); }
static bool IsMillisecond(int x) { return Between(x, 0, 999); }
return NULL;
}
}
+
private:
Debug::AddressId id_;
};
virtual void Print(StringStream* accumulator,
PrintMode mode,
int index) const;
+
protected:
explicit ArgumentsAdaptorFrame(StackFrameIterator* iterator)
: JavaScriptFrame(iterator) { }
// Enable a specified feature within a scope.
class Scope BASE_EMBEDDED {
#ifdef DEBUG
+
public:
explicit Scope(CpuFeature f) {
uint64_t mask = static_cast<uint64_t>(1) << f;
isolate_->set_enabled_cpu_features(old_enabled_);
}
}
+
private:
Isolate* isolate_;
uint64_t old_enabled_;
#else
+
public:
explicit Scope(CpuFeature f) {}
#endif
class Inspector {
public:
-
static void DumpObjectType(FILE* out, Object *obj, bool print_more);
static void DumpObjectType(FILE* out, Object *obj) {
DumpObjectType(out, obj, false);
#endif // INSPECTOR
#endif // V8_INSPECTOR_H_
-
return (bits_ == (kInFirst | kInSecond | kInBoth));
}
int value() { return bits_; }
+
private:
int bits_;
};
template <typename Callback>
void ForEach(Callback* callback) { return tree()->ForEach(callback); }
+
private:
// There can't be a static empty set since it allocates its
// successors in a zone and caches them.
virtual int GreedyLoopTextLength() { return kNodeIsTooComplexForGreedyLoops; }
virtual ActionNode* Clone() { return new ActionNode(*this); }
virtual int ComputeFirstCharacterSet(int budget);
+
private:
union {
struct {
}
void CalculateOffsets();
virtual int ComputeFirstCharacterSet(int budget);
+
private:
enum TextEmitPassType {
NON_ASCII_MATCH, // Check for characters that can't match.
virtual AssertionNode* Clone() { return new AssertionNode(*this); }
AssertionNodeType type() { return type_; }
void set_type(AssertionNodeType type) { type_ = type; }
+
private:
AssertionNode(AssertionNodeType t, RegExpNode* on_success)
: SeqRegExpNode(on_success), type_(t) { }
}
virtual BackReferenceNode* Clone() { return new BackReferenceNode(*this); }
virtual int ComputeFirstCharacterSet(int budget);
+
private:
int start_reg_;
int end_reg_;
}
void InvalidateCurrentCharacter();
void AdvanceCurrentPositionInTrace(int by, RegExpCompiler* compiler);
+
private:
int FindAffectedRegisters(OutSet* affected_registers);
void PerformDeferredActions(RegExpMacroAssembler* macro,
void fail(const char* error_message) {
error_message_ = error_message;
}
+
private:
bool ignore_case_;
bool is_ascii_;
template <typename T, class P>
class List {
public:
-
List() { Initialize(0); }
INLINE(explicit List(int capacity)) { Initialize(capacity); }
INLINE(~List()) { DeleteData(data_); }
static Object* PrintObj(int obj_id);
private:
-
struct Element {
int id_;
HeapObject* obj_;
// Helper class for updating the LiveObjectList HeapObject pointers.
class UpdateLiveObjectListVisitor: public ObjectVisitor {
public:
-
void VisitPointer(Object** p) { UpdatePointer(p); }
void VisitPointers(Object** start, Object** end) {
} } // namespace v8::internal
#endif // V8_LIVEOBJECTLIST_H_
-
void WriteToLogFile();
private:
-
Log* log_;
ScopedLock sl;
int pos_;
}
return trampoline_slot;
}
+
private:
int start_;
int end_;
static int CheckStackGuardState(Address* return_address,
Code* re_code,
Address re_frame);
+
private:
// Offsets from frame_pointer() of function parameters and stored registers.
static const int kFramePointer = 0;
// raised rather than being silently ignored.
class ExternalArray: public FixedArrayBase {
public:
-
inline bool is_the_hole(int index) { return false; }
// [external_pointer]: The pointer to the external memory area backing this
// - truncating sliced string to enable otherwise unneeded parent to be GC'ed.
class SlicedString: public String {
public:
-
inline String* parent();
inline void set_parent(String* parent);
inline int offset();
class CygwinMutex : public Mutex {
public:
-
CygwinMutex() {
pthread_mutexattr_t attrs;
memset(&attrs, 0, sizeof(attrs));
class FreeBSDMutex : public Mutex {
public:
-
FreeBSDMutex() {
pthread_mutexattr_t attrs;
int result = pthread_mutexattr_init(&attrs);
class MacOSMutex : public Mutex {
public:
-
MacOSMutex() {
pthread_mutexattr_t attr;
pthread_mutexattr_init(&attr);
class SolarisMutex : public Mutex {
public:
-
SolarisMutex() {
pthread_mutexattr_t attr;
pthread_mutexattr_init(&attr);
virtual IrregexpImplementation Implementation();
virtual Handle<HeapObject> GetCode(Handle<String> source);
+
private:
void Expand();
// Code and bitmap emission.
virtual void WriteCurrentPositionToRegister(int reg, int cp_offset);
virtual void ClearRegisters(int reg_from, int reg_to);
virtual void WriteStackPointerToRegister(int reg);
+
private:
RegExpMacroAssembler* assembler_;
};
char* ArchiveStack(char* to);
char* RestoreStack(char* from);
void FreeThreadResources() { thread_local_.Free(); }
+
private:
RegExpStack();
~RegExpStack();
bool IsWhiteSpace(unibrow::uchar c) { return kIsWhiteSpace.get(c); }
private:
-
unibrow::Predicate<IdentifierStart, 128> kIsIdentifierStart;
unibrow::Predicate<IdentifierPart, 128> kIsIdentifierPart;
unibrow::Predicate<unibrow::LineTerminator, 128> kIsLineTerminator;
position_ = 0;
is_ascii_ = true;
}
+
private:
static const int kInitialCapacity = 16;
static const int kGrowthFactory = 4;
static SerializedScopeInfo* Empty();
private:
-
inline Object** ContextEntriesAddr();
inline Object** ParameterEntriesAddr();
void Clear();
static const int kNotFound = -2;
+
private:
ContextSlotCache() {
for (int i = 0; i < kLength; ++i) {
// Returns the number of total pages in this space.
int CountTotalPages();
#endif
- private:
+ private:
// Returns a pointer to the page of the relocation pointer.
Page* MCRelocationTopPage() { return TopPageOf(mc_forwarding_info_); }
void MarkNodes();
private:
-
Heap* heap_;
// Available bytes on the free list.
Value value() { return value_; }
Node* left() { return left_; }
Node* right() { return right_; }
- private:
+ private:
friend class SplayTree;
friend class Locator;
Key key_;
Value& value() { return node_->value_; }
void set_value(const Value& value) { node_->value_ = value; }
inline void bind(Node* node) { node_ = node; }
+
private:
Node* node_;
};
void ForEach(Callback* callback);
protected:
-
// Resets tree root. Existing nodes become unreachable.
void ResetRoot() { root_ = NULL; }
void Call(Node* node) { delete node; }
private:
-
DISALLOW_COPY_AND_ASSIGN(NodeDeleter);
};
FmtElm(void* value) : type_(POINTER) { // NOLINT
data_.u_pointer_ = value;
}
+
private:
friend class StringStream;
enum Type { INT, DOUBLE, C_STR, LC_STR, OBJ, HANDLE, POINTER };
int position_;
bool is_finalized() const { return position_ < 0; }
+
private:
DISALLOW_IMPLICIT_CONSTRUCTORS(SimpleStringBuilder);
};
// Get data area for archiving a thread.
char* data() { return data_; }
+
private:
explicit ThreadState(ThreadManager* thread_manager);
// Enable a specified feature within a scope.
class Scope BASE_EMBEDDED {
#ifdef DEBUG
+
public:
explicit Scope(CpuFeature f) {
uint64_t mask = V8_UINT64_C(1) << f;
isolate_->set_enabled_cpu_features(old_enabled_);
}
}
+
private:
Isolate* isolate_;
uint64_t old_enabled_;
#else
+
public:
explicit Scope(CpuFeature f) {}
#endif
// This method switches threads if we are running the Threading test.
// Otherwise it does nothing.
static void Fuzz();
+
private:
static bool fuzzing_;
static int tests_being_run_;
Handle<Object>(debug->debug_context()->global_proxy()), DONT_ENUM,
::v8::internal::kNonStrictMode);
}
+
private:
v8::Persistent<v8::Context> context_;
};
}
virtual void Run() = 0;
+
private:
class ThreadWithSemaphore : public i::Thread {
public:
CalcFibAndCheck();
}
}
+
private:
v8::Isolate* isolate_;
};
CalcFibAndCheck();
}
}
+
private:
v8::Isolate* isolate_;
};
thread.Join();
}
}
+
private:
v8::Isolate* isolate1_;
v8::Isolate* isolate2_;
}
semaphore_->Signal();
}
+
private:
i::List<i::ThreadId>* refs_;
int thread_no_;