PresentationHelpers.Shapes<T> Method

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

All shapes that represent elements of a given type.

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

Syntax

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

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

Type Parameters

  • T

Parameters

  • element
    Type: T
    UML element to get all shapes for.

Return Value

Type: System.Collections.Generic.IEnumerable<IShape<T>>
All shapes on all opened or given diagram that represents the given element. 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 . 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