ContextItemManager Class
Maintains a set of context items.
Inheritance Hierarchy
System.Object
Microsoft.Windows.Design.ContextItemManager
Namespace: Microsoft.Windows.Design
Assembly: Microsoft.Windows.Design.Extensibility (in Microsoft.Windows.Design.Extensibility.dll)
Syntax
'Declaration
Public MustInherit Class ContextItemManager _
Implements IEnumerable(Of ContextItem), IEnumerable
public abstract class ContextItemManager : IEnumerable<ContextItem>,
IEnumerable
public ref class ContextItemManager abstract : IEnumerable<ContextItem^>,
IEnumerable
[<AbstractClass>]
type ContextItemManager =
class
interface IEnumerable<ContextItem>
interface IEnumerable
end
public abstract class ContextItemManager implements IEnumerable<ContextItem>, IEnumerable
The ContextItemManager type exposes the following members.
Constructors
Name | Description | |
---|---|---|
ContextItemManager | Initializes a new instance of the ContextItemManager class. |
Top
Methods
Name | Description | |
---|---|---|
Contains(Type) | When overridden in a derived class, returns a value indicating whether the context item manager contains an item of the specified type. | |
Contains<TItemType>() | Returns a value indicating whether the context item manager contains an item of the specified type. | |
Equals | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) | |
GetEnumerator | When overridden in a derived class, gets an enumeration of context items in the editing context. | |
GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) | |
GetTarget | A utility method that returns the target object for a delegate. | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
GetValue(Type) | When overridden in a derived class, returns an instance of the requested item type. | |
GetValue<TItemType>() | Returns an instance of the requested item type. | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
NotifyItemChanged | Invokes the protected OnItemChanged method on the specified ContextItem. | |
RemoveCallback | A helper method that performs a Delegate.Remove, but knows how to unwrap delegates that are proxies to generic callbacks. | |
SetValue | When overridden in a derived class, sets a context item to the specified value. | |
Subscribe(Type, SubscribeContextCallback) | When overridden in a derived class, adds a callback that is invoked when a context item of the specified item type changes. | |
Subscribe<TContextItemType>(SubscribeContextCallback<TContextItemType>) | Adds a callback that is invoked when a context item of the specified item type changes. | |
ToString | Returns a string that represents the current object. (Inherited from Object.) | |
Unsubscribe(Type, SubscribeContextCallback) | When overridden in a derived class, removes a subscription. | |
Unsubscribe<TContextItemType>(SubscribeContextCallback<TContextItemType>) | Removes a subscription. |
Top
Explicit Interface Implementations
Name | Description | |
---|---|---|
IEnumerable.GetEnumerator | For a description of this member, see IEnumerable.GetEnumerator. |
Top
Remarks
The ContextItemManager class maintains a set of context items. A context item represents a transient piece of state in a designer.
Create a ContextItemManager by calling the CreateContextItemManager method on EditingContext.
Use the Subscribe method to subscribe to change notifications on context items.
Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
See Also
Reference
Microsoft.Windows.Design Namespace
SubscribeContextCallback<TContextItemType>