SyncSessionContext Constructor

Initializes a new instance of the SyncSessionContext class by using the specified ID format schema and callback object.

Namespace:  Microsoft.Synchronization
Assembly:  Microsoft.Synchronization (in Microsoft.Synchronization.dll)

Syntax

'Declaration
Public Sub New ( _
    idFormats As SyncIdFormatGroup, _
    callbacks As SyncCallbacks _
)
'Usage
Dim idFormats As SyncIdFormatGroup
Dim callbacks As SyncCallbacks

Dim instance As New SyncSessionContext(idFormats, _
    callbacks)
public SyncSessionContext(
    SyncIdFormatGroup idFormats,
    SyncCallbacks callbacks
)
public:
SyncSessionContext(
    SyncIdFormatGroup^ idFormats, 
    SyncCallbacks^ callbacks
)
new : 
        idFormats:SyncIdFormatGroup * 
        callbacks:SyncCallbacks -> SyncSessionContext
public function SyncSessionContext(
    idFormats : SyncIdFormatGroup, 
    callbacks : SyncCallbacks
)

Parameters

Exceptions

Exception Condition
ArgumentNullException

idFormats is a null reference (Nothing in Visual Basic).

Remarks

A SyncSessionContext object is typically created by Sync Framework and passed to the provider in the BeginSession method. This constructor is useful when a proxy provider is communicating with a remote provider across a computer boundary, because it allows the remote provider to create a SyncSessionContext object. Be aware that when callbacks is not a null reference (Nothing in Visual Basic), notifications are sent from the remote provider to the application, which can degrade performance, so callbacks should only be used when necessary or when performance is not an issue. Also, in the callback methods, the position of the remote provider is reported as Unknown.

See Also

Reference

SyncSessionContext Class

Microsoft.Synchronization Namespace