ComponentFactory.Krypton.Docking.DockingElement.LoadChildDockingElement C# (CSharp) 메소드

LoadChildDockingElement() 보호된 메소드

Perform docking element specific actions for loading a child xml.
protected LoadChildDockingElement ( XmlReader xmlReader, KryptonPageCollection pages, IDockingElement child ) : void
xmlReader XmlReader Xml reader object.
pages KryptonPageCollection Collection of available pages.
child IDockingElement Optional reference to existing child docking element.
리턴 void
        protected virtual void LoadChildDockingElement(XmlReader xmlReader, 
                                                       KryptonPageCollection pages, 
                                                       IDockingElement child)
        {
            if (child != null)
                child.LoadElementFromXml(xmlReader, pages);
            else
            {
                string nodeName = xmlReader.Name;

                do
                {
                    // Read past this element
                    if (!xmlReader.Read())
                        throw new ArgumentException("An element was expected but could not be read in.");

                    // Finished when we hit the end element matching the incoming one
                    if ((xmlReader.NodeType == XmlNodeType.EndElement) && (xmlReader.Name == nodeName))
                        break;

                } while (true);
            }
        }