コード例 #1
0
		public void Create(string fileName, ConflictItem conflict)
		{
			NameValueCollection metadata = null;

			storage.Batch(
				accessor =>
					{
						metadata = accessor.GetFile(fileName, 0, 0).Metadata;
						accessor.SetConfig(RavenFileNameHelper.ConflictConfigNameForFile(fileName), conflict.AsConfig());
						metadata[SynchronizationConstants.RavenSynchronizationConflict] = "True";
						accessor.UpdateFileMetadata(fileName, metadata);
					});

			if (metadata != null)
				index.Index(fileName, metadata);
		}