PresentationHelpers::GetChildShapes<T> Method (IShape^)
Visual Studio 2015
Get child shapes that display the specified type of model element.
Assembly: Microsoft.VisualStudio.ArchitectureTools.Extensibility (in Microsoft.VisualStudio.ArchitectureTools.Extensibility.dll)
public: generic<typename T> where T : IElement [ExtensionAttribute] static IEnumerable<IShape<T>^>^ GetChildShapes( IShape^ shape )
Parameters
- shape
-
Type:
Microsoft.VisualStudio.ArchitectureTools.Extensibility.Presentation::IShape^
The parent shape or diagram.
Return Value
Type: System.Collections.Generic::IEnumerable<IShape<T>^>^All shapes that display model elements of type T or one of its subtypes.
Type Parameters
- T
The types of elements to show. A subtype of IElement.
For more information, see:
IClassDiagram classDiagram;
// Find only the class shapes, omitting interfaces, packages, and so on.
foreach (IClass class in classDiagram.GetChildShapes<IClass>()) { ... }
Show: