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

Unified Diff: tools/telemetry/telemetry/core/possible_app.py

Issue 647193002: Adding App, AndroidApp, AppBackend, AndroidAppBackend, PossibleApp. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/telemetry/telemetry/core/browser.py ('k') | tools/telemetry/telemetry/core/possible_browser.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/telemetry/telemetry/core/possible_app.py
diff --git a/tools/telemetry/telemetry/core/possible_app.py b/tools/telemetry/telemetry/core/possible_app.py
new file mode 100644
index 0000000000000000000000000000000000000000..63bdb8f0ec524c84eef9e68ab155c16d8ad63e28
--- /dev/null
+++ b/tools/telemetry/telemetry/core/possible_app.py
@@ -0,0 +1,48 @@
+# Copyright 2012 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+
+class PossibleApp(object):
+ """A factory class that can be used to create a running instance of app.
+
+ Call Create() to launch the app and begin manipulating it.
+ """
+
+ def __init__(self, app_type, target_os, finder_options):
+ self._app_type = app_type
+ self._target_os = target_os
+ self._finder_options = finder_options
+ self._platform = None
+ self._platform_backend = None
+
+ def __repr__(self):
+ return 'PossibleApp(app_type=%s)' % self.app_type
+
+ @property
+ def app_type(self):
+ return self._app_type
+
+ @property
+ def target_os(self):
+ """Target OS, the app will run on."""
+ return self._target_os
+
+ @property
+ def finder_options(self):
+ return self._finder_options
+
+ @property
+ def platform(self):
+ self._InitPlatformIfNeeded()
+ return self._platform
+
+ def _InitPlatformIfNeeded(self):
+ raise NotImplementedError()
+
+ def Create(self):
+ raise NotImplementedError()
+
+ def SupportsOptions(self, finder_options):
+ """Tests for extension support."""
+ raise NotImplementedError()
« no previous file with comments | « tools/telemetry/telemetry/core/browser.py ('k') | tools/telemetry/telemetry/core/possible_browser.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698