Breyta

Deila með


IAddChild Interface

Definition

Provides a means to parse elements that permit mixtures of child elements or text.

public interface class IAddChild
public interface IAddChild
type IAddChild = interface
Public Interface IAddChild
Derived

Remarks

For purposes of establishing or defining a content property or content model in WPF, IAddChild is obsolete. Apply the ContentPropertyAttribute to a custom class instead.

For purposes of XAML parser/processor behavior, IAddChild is obsolete. Collection behavior is now integrally part of the XAML type system and XAML processor implementations should use the dedicated APIs in the System.Xaml assembly. General user code should use the Add methods on the collection type used for the relevant type's child collection property.

The main remaining scenario for IAddChild is to support a FrameworkElementFactory that can handle child object creation, which is an advanced scenario. See FrameworkElementFactory.

Callers in .NET Framework 4.5 Beta targeted applications that attempt to use the IAddChild API for one of its original .NET Framework 3.0 era purposes (WPF content model, XAML processing) should expect that many current IAddChild-implementing classes will return NotImplementedException or similar results for the IAddChild API.

Methods

AddChild(Object)

Adds a child object.

AddText(String)

Adds the text content of a node to the object.

Applies to

See also