Bagikan melalui


MergeOption Enumeration

Microsoft Silverlight will reach end of support after October 2021. Learn more.

Determines the synchronization option for sending or receiving entities to or from a data service.

Namespace:  System.Data.Services.Client
Assembly:  System.Data.Services.Client (in System.Data.Services.Client.dll)

Syntax

'Declaration
Public Enumeration MergeOption
public enum MergeOption

Members

Member name Description
AppendOnly Append new entities only. Existing entities or their original values will not be modified. No client-side changes are lost in this merge. This is the default behavior.
OverwriteChanges All current values on the client are overwritten with current values from the data service regardless of whether they have been changed on the client.
PreserveChanges Current values that have been changed on the client are not modified, but any unchanged values are updated with current values from the data service. No client-side changes are lost in this merge.
NoTracking Objects are always loaded from the data source. Any property changes made to objects in the object context are overwritten by the data source values.

Remarks

This value is used when materializing objects. Set this property to the appropriate materialization option before executing any queries or updates to the data service. The default value is MergeOption.AppendOnly.

Version Information

Silverlight

Supported in: 5, 4, 3

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.