private static EditStudyWorkQueueData ParseOldXml(XmlElement element) { var data = new EditStudyWorkQueueData(); var compiler = new WebEditStudyCommandCompiler(); List <BaseImageLevelUpdateCommand> updateCommands = compiler.Compile(element); foreach (BaseImageLevelUpdateCommand command in updateCommands) { if (data.EditRequest.UpdateEntries == null) { data.EditRequest.UpdateEntries = new List <UpdateItem>(); } // convert BaseImageLevelUpdateCommand to UpdateItem string value = command.UpdateEntry.Value != null?command.UpdateEntry.Value.ToString() : null; data.EditRequest.UpdateEntries.Add(new UpdateItem(command.UpdateEntry.TagPath.Tag.TagValue, command.UpdateEntry.OriginalValue, value)); } return(data); }
private static EditStudyWorkQueueData ParseOldXml(XmlElement element) { EditStudyWorkQueueData data = new EditStudyWorkQueueData(); WebEditStudyCommandCompiler compiler = new WebEditStudyCommandCompiler(); List<BaseImageLevelUpdateCommand> updateCommands = compiler.Compile(element); foreach (BaseImageLevelUpdateCommand command in updateCommands) { if (data.EditRequest.UpdateEntries==null) data.EditRequest.UpdateEntries = new List<UpdateItem>(); // convert BaseImageLevelUpdateCommand to UpdateItem string value = command.UpdateEntry.Value != null ? command.UpdateEntry.Value.ToString() : null; data.EditRequest.UpdateEntries.Add(new UpdateItem(command.UpdateEntry.TagPath.Tag.TagValue, command.UpdateEntry.OriginalValue, value)); } return data; }