Exemple #1
0
		/// <summary>
		/// Constructor
		/// </summary>
		/// <param name="persistentStore"></param>
		/// <param name="mode"></param>
		internal UpdateContext(PersistentStore persistentStore, UpdateContextSyncMode mode)
			: base(persistentStore)
		{
			if (mode == UpdateContextSyncMode.Hold)
				throw new NotSupportedException("UpdateContextSyncMode.Hold is not supported");

			// create a default change-set logger
			_changeSetRecorder = new DefaultEntityChangeSetRecorder();
			_validator = new DomainObjectValidator();
			_validationChangeTracker = new ChangeTracker();
		}
		internal void RemoveChangeTracker(ChangeTracker tracker)
		{
			_changeTrackers.Remove(tracker);
		}
		internal void AddChangeTracker(ChangeTracker tracker)
		{
			_changeTrackers.Add(tracker);
		}