MetricIdentifier.fromJson constructor
Creates a MetricIdentifier from JSON data.
Implementation
factory MetricIdentifier.fromJson(Map<String, dynamic> json) {
final tempNameJson = json['name'];
final tempSelectorJson = json['selector'];
final String tempName = tempNameJson;
final LabelSelector? tempSelector = tempSelectorJson != null
? LabelSelector.fromJson(tempSelectorJson)
: null;
return MetricIdentifier(
name: tempName,
selector: tempSelector,
);
}