Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(230)

Side by Side Diff: src/d8.h

Issue 42641: Add a system() call to the d8 shell (Unix only). (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/SConscript ('k') | src/d8.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2008 the V8 project authors. All rights reserved. 1 // Copyright 2009 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
11 // with the distribution. 11 // with the distribution.
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 static Handle<Array> GetCompletions(Handle<String> text, 123 static Handle<Array> GetCompletions(Handle<String> text,
124 Handle<String> full); 124 Handle<String> full);
125 static Handle<Object> DebugMessageDetails(Handle<String> message); 125 static Handle<Object> DebugMessageDetails(Handle<String> message);
126 static Handle<Value> DebugCommandToJSONRequest(Handle<String> command); 126 static Handle<Value> DebugCommandToJSONRequest(Handle<String> command);
127 127
128 static Handle<Value> Print(const Arguments& args); 128 static Handle<Value> Print(const Arguments& args);
129 static Handle<Value> Yield(const Arguments& args); 129 static Handle<Value> Yield(const Arguments& args);
130 static Handle<Value> Quit(const Arguments& args); 130 static Handle<Value> Quit(const Arguments& args);
131 static Handle<Value> Version(const Arguments& args); 131 static Handle<Value> Version(const Arguments& args);
132 static Handle<Value> Load(const Arguments& args); 132 static Handle<Value> Load(const Arguments& args);
133 // system("program_name", ["arg1", "arg2", ...], timeout1, timeout2) will run
134 // the command, passing the arguments to the program. The standard output of
135 // the program will be picked up and returned as a multiline string. If
136 // timeout1 is present then it should be a number. -1 indicates no timeout
137 // and a positive number is used as a timeout in milliseconds that limits the
138 // time spent waiting between receiving output characters from the program.
139 // timeout2, if present, should be a number indicating the limit in
140 // milliseconds on the total running time of the program. Exceptions are
141 // thrown on timeouts or other errors or if the exit status of the program
142 // indicates an error.
143 static Handle<Value> System(const Arguments& args);
133 144
134 static Handle<Context> utility_context() { return utility_context_; } 145 static Handle<Context> utility_context() { return utility_context_; }
135 146
136 static const char* kHistoryFileName; 147 static const char* kHistoryFileName;
137 static const char* kPrompt; 148 static const char* kPrompt;
138 private: 149 private:
139 static Persistent<Context> utility_context_; 150 static Persistent<Context> utility_context_;
140 static Persistent<Context> evaluation_context_; 151 static Persistent<Context> evaluation_context_;
141 static CounterMap* counter_map_; 152 static CounterMap* counter_map_;
142 // We statically allocate a set of local counters to be used if we 153 // We statically allocate a set of local counters to be used if we
(...skipping 22 matching lines...) Expand all
165 const char* name_; 176 const char* name_;
166 LineEditor* next_; 177 LineEditor* next_;
167 static LineEditor* first_; 178 static LineEditor* first_;
168 }; 179 };
169 180
170 181
171 } // namespace v8 182 } // namespace v8
172 183
173 184
174 #endif // V8_D8_H_ 185 #endif // V8_D8_H_
OLDNEW
« no previous file with comments | « src/SConscript ('k') | src/d8.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698