Adds or removes the parts in the specified CompositionBatch from the container and executes composition.
Assembly: System.ComponentModel.Composition (in System.ComponentModel.Composition.dll)
This method is the primary way of directly adding or removing parts from the container. The CompositionContainer will always maintain a stable, composed state. Therefore, calling with an empty CompositionBatch is never necessary to start composition. Instead, call the method whenever you need to make changes to the parts available to the CompositionContainer.
The CompositionBatch can contain both parts to be added and parts to be removed. Recomposition will take place only once for each call to .
Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.