ITableDataSource.Subscribe(ITableDataSink) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Subscribe to ITableEntrys created by this data source.
public:
IDisposable ^ Subscribe(Microsoft::VisualStudio::Shell::TableManager::ITableDataSink ^ sink);
public IDisposable Subscribe (Microsoft.VisualStudio.Shell.TableManager.ITableDataSink sink);
abstract member Subscribe : Microsoft.VisualStudio.Shell.TableManager.ITableDataSink -> IDisposable
Public Function Subscribe (sink As ITableDataSink) As IDisposable
Parameters
- sink
- ITableDataSink
Contains methods called when the entries provided by the source change.
Returns
A key that controls the lifetime of the subscription. The ITableDataSource must continue to provide updates until either the key is disposed or the source is removed from the table (which will, as a side-effect, cause the key to be disposed of).
Remarks
If, when the call is made to subscribe to a ITableDataSource, the source already has entries, then the source needs to add these entries using sink
. It can make the call to add the entries before returning from the Subscribe(ITableDataSink) call.
A ITableDataSource can have multiple, simultaneous subscribers (and each subscriber will have its own ITableDataSink.