/// <summary> /// Handles the Hierarchy element child elements /// </summary> /// <param name="parent"> /// The parent IHierarchyMutableObject object /// </param> /// <param name="localName"> /// The name of the current xml element /// </param> /// <returns> /// The <see cref="StructureReaderBaseV20.ElementActions"/>. /// </returns> private ElementActions HandleChildElements(IHierarchyMutableObject parent, object localName) { ElementActions actions = null; if (NameTableCache.IsElement(localName, ElementNameTable.CodeRef)) { ICodeRefMutableObject cr = new CodeRefMutableCore(); ParseAttributes(cr, this.Attributes); parent.AddHierarchicalCode(cr); actions = this.BuildElementActions(cr, HandleChildElements, this.HandleTextChildElement); } else if (NameTableCache.IsElement(localName, ElementNameTable.Level)) { ILevelMutableObject level = new LevelMutableCore(); ParseAttributes(level, this.Attributes); actions = this.AddNameableAction(level, HandleChildElements, this.HandleTextChildElement); } return actions; }
/// <summary> /// Handles the CodeRef type element child elements /// </summary> /// <param name="parent"> /// The parent ICodeRefMutableObject object /// </param> /// <param name="localName"> /// The name of the current xml element /// </param> /// <returns> /// The <see cref="StructureReaderBaseV20.ElementActions"/>. /// </returns> private ElementActions HandleChildElements(ICodeRefMutableObject parent, object localName) { ElementActions actions = null; if (NameTableCache.IsElement(localName, ElementNameTable.CodeRef)) { var cr = new CodeRefMutableCore(); ParseAttributes(cr, this.Attributes); parent.AddCodeRef(cr); actions = this.BuildElementActions(cr, HandleChildElements, this.HandleTextChildElement); } return actions; }