//----------------------------------------------------------------------------------------------- private static void ParseSubtasksForMethod(XmlNode subtasksNode, Method method, Domain domain) { XmlNodeList subtaskList = subtasksNode.ChildNodes; foreach (XmlNode subtaskNode in subtaskList) { string taskName = ""; if (!TryLoadRequiredAttributeFromXmlNode(subtaskNode, "name", ref taskName)) { throw new ArgumentNullException("Subtask missing name!"); } Task registeredTask = domain.GetTaskByName(taskName); Task.eModifier[] mods = ParseModifiersForTask(subtaskNode); method.AddSubTask(registeredTask, mods); } }