Exemplo n.º 1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EntityTrackingAdapter" /> class.
 /// </summary>
 /// <param name="entityTracker">The entity tracker.</param>
 /// <param name="mergeOption">The merge option.</param>
 /// <param name="model">The model.</param>
 /// <param name="context">The context.</param>
 internal EntityTrackingAdapter(EntityTrackerBase entityTracker, MergeOption mergeOption, ClientEdmModel model, DataServiceContext context)
 {
     this.MaterializationLog = new AtomMaterializerLog(mergeOption, model, entityTracker);
     this.MergeOption = mergeOption;
     this.EntityTracker = entityTracker;
     this.Model = model;
     this.Context = context;
 }
Exemplo n.º 2
0
        /// <summary>
        /// Initializes a new <see cref="AtomMaterializerLog"/> instance.
        /// </summary>
        /// <param name="mergeOption">The merge option for the log.</param>
        /// <param name="model">The model for the log.</param>
        /// <param name="entityTracker">The entity tracker for the log.</param>
        /// <remarks>
        /// Note that the merge option can't be changed.
        /// </remarks>
        internal AtomMaterializerLog(MergeOption mergeOption, ClientEdmModel model, EntityTrackerBase entityTracker)
        {
            Debug.Assert(model != null, "model != null");
            Debug.Assert(entityTracker != null, "entityTracker != null");

            this.appendOnlyEntries = new Dictionary <Uri, ODataResource>(EqualityComparer <Uri> .Default);
            this.mergeOption       = mergeOption;
            this.clientEdmModel    = model;
            this.entityTracker     = entityTracker;
            this.identityStack     = new Dictionary <Uri, ODataResource>(EqualityComparer <Uri> .Default);
            this.links             = new List <LinkDescriptor>();
        }
Exemplo n.º 3
0
        /// <summary>
        /// Initializes a new <see cref="AtomMaterializerLog"/> instance.
        /// </summary>
        /// <param name="mergeOption">The merge option for the log.</param>
        /// <param name="model">The model for the log.</param>
        /// <param name="entityTracker">The entity tracker for the log.</param>
        /// <remarks>
        /// Note that the merge option can't be changed.
        /// </remarks>
        internal AtomMaterializerLog(MergeOption mergeOption, ClientEdmModel model, EntityTrackerBase entityTracker)
        {
            Debug.Assert(model != null, "model != null");
            Debug.Assert(entityTracker != null, "entityTracker != null");

            this.appendOnlyEntries = new Dictionary<Uri, ODataEntry>(EqualityComparer<Uri>.Default);
            this.mergeOption = mergeOption;
            this.clientEdmModel = model;
            this.entityTracker = entityTracker;
            this.identityStack = new Dictionary<Uri, ODataEntry>(EqualityComparer<Uri>.Default);
            this.links = new List<LinkDescriptor>();
        }