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

Side by Side Diff: tools/logreader.js

Issue 7910001: Fixing presubmit. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 3 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 | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 /** 128 /**
129 * Does a dispatch of a log record. 129 * Does a dispatch of a log record.
130 * 130 *
131 * @param {Array.<string>} fields Log record. 131 * @param {Array.<string>} fields Log record.
132 * @private 132 * @private
133 */ 133 */
134 LogReader.prototype.dispatchLogRow_ = function(fields) { 134 LogReader.prototype.dispatchLogRow_ = function(fields) {
135 // Obtain the dispatch. 135 // Obtain the dispatch.
136 var command = fields[0]; 136 var command = fields[0];
137 if (!(command in this.dispatchTable_)) return; 137 if (!(command in this.dispatchTable_)) return;
138 138
139 var dispatch = this.dispatchTable_[command]; 139 var dispatch = this.dispatchTable_[command];
140 140
141 if (dispatch === null || this.skipDispatch(dispatch)) { 141 if (dispatch === null || this.skipDispatch(dispatch)) {
142 return; 142 return;
143 } 143 }
144 144
145 // Parse fields. 145 // Parse fields.
146 var parsedFields = []; 146 var parsedFields = [];
147 for (var i = 0; i < dispatch.parsers.length; ++i) { 147 for (var i = 0; i < dispatch.parsers.length; ++i) {
148 var parser = dispatch.parsers[i]; 148 var parser = dispatch.parsers[i];
(...skipping 26 matching lines...) Expand all
175 continue; 175 continue;
176 } 176 }
177 try { 177 try {
178 var fields = this.csvParser_.parseLine(line); 178 var fields = this.csvParser_.parseLine(line);
179 this.dispatchLogRow_(fields); 179 this.dispatchLogRow_(fields);
180 } catch (e) { 180 } catch (e) {
181 this.printError('line ' + (this.lineNum_ + 1) + ': ' + (e.message || e)); 181 this.printError('line ' + (this.lineNum_ + 1) + ': ' + (e.message || e));
182 } 182 }
183 } 183 }
184 }; 184 };
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698