IElementFactory Interface

Definition

Supports the creation and recycling of UIElement objects.

public interface class IElementFactory
/// [Windows.Foundation.Metadata.ContractVersion(Microsoft.UI.Xaml.WinUIContract, 65536)]
/// [Windows.Foundation.Metadata.Guid(1979365959, 11506, 21678, 145, 230, 5, 129, 85, 111, 221, 170)]
/// [Windows.Foundation.Metadata.WebHostHidden]
struct IElementFactory
[Windows.Foundation.Metadata.ContractVersion(typeof(Microsoft.UI.Xaml.WinUIContract), 65536)]
[Windows.Foundation.Metadata.Guid(1979365959, 11506, 21678, 145, 230, 5, 129, 85, 111, 221, 170)]
[Windows.Foundation.Metadata.WebHostHidden]
public interface IElementFactory
Public Interface IElementFactory
Derived
Attributes
Windows.Foundation.Metadata.ContractVersionAttribute Windows.Foundation.Metadata.GuidAttribute Windows.Foundation.Metadata.WebHostHiddenAttribute

Remarks

Two concrete implementations of this interface are:

  1. DataTemplate, and
  2. DataTemplateSelector

The GetElement method is used to retrieve a valid instance of a UIElement. The RecycleElement method is used to recycle elements.

Methods

GetElement(ElementFactoryGetArgs)

Gets an UIElement object.

RecycleElement(ElementFactoryRecycleArgs)

Recycles a UIElement that was previously retrieved using GetElement.

Applies to

See also