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

Side by Side Diff: tools/telemetry/telemetry/browser_backend.py

Issue 12082091: [telemetry] Add TraceResult as return value from tracing, and placeholder trace_event_importer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: nits Created 7 years, 10 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
OLDNEW
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import urllib2 5 import urllib2
6 import httplib 6 import httplib
7 import socket 7 import socket
8 import json 8 import json
9 import re 9 import re
10 import sys 10 import sys
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 return True 131 return True
132 132
133 def StartTracing(self): 133 def StartTracing(self):
134 if self._tracing_backend is None: 134 if self._tracing_backend is None:
135 self._tracing_backend = tracing_backend.TracingBackend(self._port) 135 self._tracing_backend = tracing_backend.TracingBackend(self._port)
136 self._tracing_backend.BeginTracing() 136 self._tracing_backend.BeginTracing()
137 137
138 def StopTracing(self): 138 def StopTracing(self):
139 self._tracing_backend.EndTracing() 139 self._tracing_backend.EndTracing()
140 140
141 def GetTrace(self): 141 def GetTraceResultAndReset(self):
142 return self._tracing_backend.GetTraceAndReset() 142 return self._tracing_backend.GetTraceAndReset()
143 143
144 def GetRemotePort(self, _): 144 def GetRemotePort(self, _):
145 return util.GetAvailableLocalPort() 145 return util.GetAvailableLocalPort()
146 146
147 def Close(self): 147 def Close(self):
148 if self._tracing_backend: 148 if self._tracing_backend:
149 self._tracing_backend.Close() 149 self._tracing_backend.Close()
150 self._tracing_backend = None 150 self._tracing_backend = None
151 151
152 def CreateForwarder(self, *port_pairs): 152 def CreateForwarder(self, *port_pairs):
153 raise NotImplementedError() 153 raise NotImplementedError()
154 154
155 def IsBrowserRunning(self): 155 def IsBrowserRunning(self):
156 raise NotImplementedError() 156 raise NotImplementedError()
157 157
158 def GetStandardOutput(self): 158 def GetStandardOutput(self):
159 raise NotImplementedError() 159 raise NotImplementedError()
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698