Subscribe(TContextItemType) Method (SubscribeContextCallback(TContextItemType))
Adds an event callback that will be invoked with a context item of the given item type changes.
Namespace: Microsoft.Data.Tools.Design.Core.Context
Assembly: Microsoft.Data.Tools.Design.Core (in Microsoft.Data.Tools.Design.Core.dll)
Syntax
'Declaration
Public Sub Subscribe(Of TContextItemType As ContextItem) ( _
callback As SubscribeContextCallback(Of TContextItemType) _
)
'Usage
Dim instance As ContextItemCollection
Dim callback As SubscribeContextCallback(Of TContextItemType)
instance.Subscribe(callback)
public void Subscribe<TContextItemType>(
SubscribeContextCallback<TContextItemType> callback
)
where TContextItemType : ContextItem
public:
generic<typename TContextItemType>
where TContextItemType : ContextItem
void Subscribe(
SubscribeContextCallback<TContextItemType>^ callback
)
member Subscribe :
callback:SubscribeContextCallback<'TContextItemType> -> unit when 'TContextItemType : ContextItem
JScript does not support generic types and methods.
Type Parameters
- TContextItemType
Parameters
- callback
Type: Microsoft.Data.Tools.Design.Core.Context..::..SubscribeContextCallback< (Of < ( <'TContextItemType> ) > ) >
A callback that will be invoked when contextItemType changes.
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | if callback is null. |