filterProperties method Null safety
- List<
DiagnosticsNode> nodes, - DiagnosticsNode owner
override
Filters the list of DiagnosticsNode
s that will be included as properties
for the given owner
node.
The callback may return a subset of the properties in the provided list or replace the entire list with new property nodes.
By default, nodes
is returned as-is.
See also:
- includeProperties, which controls whether properties will be included at all.
Implementation
@override
List<DiagnosticsNode> filterProperties(List<DiagnosticsNode> nodes, DiagnosticsNode owner) {
final bool createdByLocalProject = _nodesCreatedByLocalProject.contains(owner);
return nodes.where((DiagnosticsNode node) {
return !node.isFiltered(createdByLocalProject ? DiagnosticLevel.fine : DiagnosticLevel.info);
}).toList();
}