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

Unified Diff: tracing/tracing/value/histogram.py

Issue 2977283002: Ownership into GenericSets (Closed)
Patch Set: Fix tests after reabse Created 3 years, 5 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 | « tracing/tracing/value/diagnostics/reserved_names.html ('k') | tracing/tracing/value/histogram_unittest.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/value/histogram.py
diff --git a/tracing/tracing/value/histogram.py b/tracing/tracing/value/histogram.py
index 52f16167ec79528a0ef81215358304d343e58b7c..405158ad7840df9901dc6ccf9466c9837b3221cb 100644
--- a/tracing/tracing/value/histogram.py
+++ b/tracing/tracing/value/histogram.py
@@ -331,50 +331,6 @@ class RunningStatistics(object):
AsFloatOrNone(x) for x in dct[1:]]
return result
-
-class Ownership(diagnostic.Diagnostic):
-
- def __init__(self, emails, component=None):
- super(Ownership, self).__init__()
-
- emails = emails or []
-
- self._emails = emails[:]
-
- if (component is None) or isinstance(component, basestring):
- self._component = component
- else:
- raise TypeError('component must be None or string')
-
- def __eq__(self, other):
- if self.component != other.component:
- return False
- if self.emails != other.emails:
- return False
-
- return True
-
- def __ne__(self, other):
- return not self == other
-
- @property
- def emails(self):
- return self._emails[:]
-
- @property
- def component(self):
- return self._component
-
- def _AsDictInto(self, dct):
- dct['emails'] = self.emails
-
- if self.component is not None:
- dct['component'] = self.component
-
- @staticmethod
- def FromDict(dct):
- return Ownership(dct.get('emails'), dct.get('component'))
-
class Breakdown(diagnostic.Diagnostic):
def __init__(self):
@@ -1793,7 +1749,6 @@ all_diagnostics.DIAGNOSTICS_BY_NAME.update({
'DateRange': DateRange,
'DeviceInfo': DeviceInfo,
'TagMap': TagMap,
- 'Ownership': Ownership,
'RelatedHistogramBreakdown': RelatedHistogramBreakdown,
'TelemetryInfo': TelemetryInfo,
'RelatedHistogramMap': RelatedHistogramMap,
« no previous file with comments | « tracing/tracing/value/diagnostics/reserved_names.html ('k') | tracing/tracing/value/histogram_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698