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

Unified Diff: tracing/tracing/model/attribute.html

Issue 1744563002: [memory-infra] Move 'infos' field from Attribute to MemoryAllocatorDump (Closed) Base URL: git@github.com:catapult-project/catapult.git@master
Patch Set: Address Primiano's comment Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tracing/tracing/model/attribute_test.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/model/attribute.html
diff --git a/tracing/tracing/model/attribute.html b/tracing/tracing/model/attribute.html
index bb1f56e57469836711c358da655921aafd3e6a7b..88063d2a059a5fdfa4d112b97ff096d8ea4da8c4 100644
--- a/tracing/tracing/model/attribute.html
+++ b/tracing/tracing/model/attribute.html
@@ -18,12 +18,10 @@ tr.exportTo('tr.model', function() {
/**
* @constructor
*/
+ // TODO(petrcermak): Replace this class with tr.v.ScalarNumeric
+ // (https://github.com/catapult-project/catapult/issues/1928).
function Attribute(units) {
this.units = units;
-
- // A list of information about the attribute (e.g. about how it was
- // calculated). The interpretation of the items is domain-specific.
- this.infos = [];
}
Attribute.fromDictIfPossible = function(dict, opt_model) {
@@ -165,16 +163,6 @@ tr.exportTo('tr.model', function() {
}
};
- Attribute.prototype.cloneWithoutInfos = function() {
- return new Attribute(this.units);
- };
-
- Attribute.prototype.cloneWithInfos = function() {
- var attr = this.cloneWithoutInfos();
- attr.infos = this.infos.slice();
- return attr;
- };
-
var options = new tr.b.ExtensionRegistryOptions(tr.b.BASIC_REGISTRY_MODE);
tr.b.decorateExtensionRegistry(Attribute, options);
@@ -211,10 +199,6 @@ tr.exportTo('tr.model', function() {
ScalarAttribute.prototype.__proto__ = Attribute.prototype;
- ScalarAttribute.prototype.cloneWithoutInfos = function() {
- return new ScalarAttribute(this.units, this.value);
- };
-
Attribute.register(ScalarAttribute, {type: 'scalar'});
/**
@@ -231,10 +215,6 @@ tr.exportTo('tr.model', function() {
StringAttribute.prototype.__proto__ = Attribute.prototype;
- StringAttribute.prototype.cloneWithoutInfos = function() {
- return new StringAttribute(this.units, this.value);
- };
-
Attribute.register(StringAttribute, {type: 'string'});
/**
@@ -251,10 +231,6 @@ tr.exportTo('tr.model', function() {
UnknownAttribute.prototype.__proto__ = Attribute.prototype;
- UnknownAttribute.prototype.cloneWithoutInfos = function() {
- return new UnknownAttribute(this.units, this.value);
- };
-
return {
Attribute: Attribute,
ScalarAttribute: ScalarAttribute,
« no previous file with comments | « no previous file | tracing/tracing/model/attribute_test.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698