Compartilhar via


INodeFilter.IsVisible(WorkspaceVisualNodeBase) Method

Definition

Keeps or removes a node from the Solution Explorer tree visualization.

public:
 bool IsVisible(Microsoft::VisualStudio::Workspace::VSIntegration::UI::WorkspaceVisualNodeBase ^ node);
public bool IsVisible (Microsoft.VisualStudio.Workspace.VSIntegration.UI.WorkspaceVisualNodeBase node);
abstract member IsVisible : Microsoft.VisualStudio.Workspace.VSIntegration.UI.WorkspaceVisualNodeBase -> bool
Public Function IsVisible (node As WorkspaceVisualNodeBase) As Boolean

Parameters

node
WorkspaceVisualNodeBase

A UI node to check for filtering rules.

Returns

true if the node should be visible, or false if it should be hidden.

Remarks

Even if an INodeFilter returns true, a given node may be hidden for other reasons such as another active filter. A filter is only used for removal of nodes and not for requiring a node to be shown.

When choosing to filter a node or not, it's useful to check the node's type. If the type is one recognized by the filter, such as IFileSystemNode or a custom type, then the filter should apply the appropriate logic. If the type is not recognized, then it's up to the filter to decide if the node should be filtered or not. The recommended practice is to not filter unrecognized nodes.

This does not filter the Solution Explorer for opened solution and projects.

Applies to

See also