Share via


PresentationHelpers.GetSelectedShapes<T> Method

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Get all selected shapes that display elements of the specified type.

Namespace:  Microsoft.VisualStudio.Uml.Presentation
Assembly:  Microsoft.VisualStudio.Uml.Extensions (in Microsoft.VisualStudio.Uml.Extensions.dll)

Syntax

'Declaration
<ExtensionAttribute> _
Public Shared Function GetSelectedShapes(Of T As IElement) ( _
    diagram As IDiagram _
) As IEnumerable(Of IShape(Of T))
'Usage
Dim diagram As IDiagram
Dim returnValue As IEnumerable(Of IShape(Of T))

returnValue = diagram.GetSelectedShapes()
public static IEnumerable<IShape<T>> GetSelectedShapes<T>(
    this IDiagram diagram
)
where T : IElement
[ExtensionAttribute]
public:
generic<typename T>
where T : IElement
static IEnumerable<IShape<T>^>^ GetSelectedShapes(
    IDiagram^ diagram
)
static member GetSelectedShapes : 
        diagram:IDiagram -> IEnumerable<IShape<'T>>  when 'T : IElement
JScript does not support generic types or methods.

Type Parameters

  • T

Parameters

Return Value

Type: System.Collections.Generic.IEnumerable<IShape<T>>
All selected shapes that display UML elements of the given type. Empty enumeration if none found.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IDiagram. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

.NET Framework Security

See Also

Reference

PresentationHelpers Class

PresentationHelpers Members

Microsoft.VisualStudio.Uml.Presentation Namespace