OLD | NEW |
1 # Copyright 2017 The Chromium Authors. All rights reserved. | 1 # Copyright 2017 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 class _Info(object): | 5 class _Info(object): |
6 | 6 |
7 def __init__(self, name, _type=None): | 7 def __init__(self, name, _type=None): |
8 self._name = name | 8 self._name = name |
9 self._type = _type | 9 self._type = _type |
10 | 10 |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 STORIES = _Info('stories', 'GenericSet') | 44 STORIES = _Info('stories', 'GenericSet') |
45 STORYSET_REPEATS = _Info('storysetRepeats', 'GenericSet') | 45 STORYSET_REPEATS = _Info('storysetRepeats', 'GenericSet') |
46 STORY_TAGS = _Info('storyTags', 'GenericSet') | 46 STORY_TAGS = _Info('storyTags', 'GenericSet') |
47 TAG_MAP = _Info('tagmap', 'TagMap') | 47 TAG_MAP = _Info('tagmap', 'TagMap') |
48 TRACE_START = _Info('traceStart', 'DateRange') | 48 TRACE_START = _Info('traceStart', 'DateRange') |
49 TRACE_URLS = _Info('traceUrls', 'GenericSet') | 49 TRACE_URLS = _Info('traceUrls', 'GenericSet') |
50 V8_COMMIT_POSITIONS = _Info('v8CommitPositions', 'DateRange') | 50 V8_COMMIT_POSITIONS = _Info('v8CommitPositions', 'DateRange') |
51 V8_REVISIONS = _Info('v8Revisions', 'GenericSet') | 51 V8_REVISIONS = _Info('v8Revisions', 'GenericSet') |
52 WEBRTC_REVISIONS = _Info('webrtcRevisions', 'GenericSet') | 52 WEBRTC_REVISIONS = _Info('webrtcRevisions', 'GenericSet') |
53 | 53 |
54 # DEPRECATED https://github.com/catapult-project/catapult/issues/3507 | |
55 INTERACTION_RECORD = _Info('tir', 'GenericSet') | |
56 ITERATION = _Info('iteration') # Legacy name for TELEMETRY | |
57 TELEMETRY = _Info('telemetry') # TelemetryInfo or MergedTelemetryInfo | |
58 | |
59 def GetTypeForName(name): | 54 def GetTypeForName(name): |
60 for info in globals().itervalues(): | 55 for info in globals().itervalues(): |
61 if isinstance(info, _Info) and info.name == name: | 56 if isinstance(info, _Info) and info.name == name: |
62 return info.type | 57 return info.type |
OLD | NEW |