public void CreateNode(int size, ConfigNodeSubType subType, ConfigNodeType nType, int terminal, [MarshalAs(UnmanagedType.LPWStr)] string text, int textLength, int prefixLength) { if (nType == ConfigNodeType.Element) { this.lastProcessed = "<" + text + ">"; if ((this.parsing || (this.bNoSearchPath && (string.Compare(text, this.treeRootPath[0], StringComparison.OrdinalIgnoreCase) == 0))) || (((this.depth == this.searchDepth) && (this.searchDepth == this.pathDepth)) && (string.Compare(text, this.treeRootPath[this.pathDepth], StringComparison.OrdinalIgnoreCase) == 0))) { this.parsing = true; ConfigNode currentNode = this.currentNode; this.currentNode = new ConfigNode(text, currentNode); if (this.rootNode == null) { this.rootNode = this.currentNode; } else { currentNode.AddChild(this.currentNode); } } else { this.depth++; } } else if ((nType == ConfigNodeType.PCData) && (this.currentNode != null)) { this.currentNode.Value = text; } }
public override void CreateNode(int size, ConfigNodeSubType subType, ConfigNodeType nType, int terminal, [MarshalAs(UnmanagedType.LPWStr)] string text, int textLength, int prefixLength) { if (nType == ConfigNodeType.Element) { this.lastProcessed = "<" + text + ">"; if ((this.parsing || (this.bNoSearchPath && (string.Compare(text, this.treeRootPath[0], StringComparison.OrdinalIgnoreCase) == 0))) || (((this.depth == this.searchDepth) && (this.searchDepth == this.pathDepth)) && (string.Compare(text, this.treeRootPath[this.pathDepth], StringComparison.OrdinalIgnoreCase) == 0))) { this.parsing = true; ConfigNode currentNode = this.currentNode; this.currentNode = new ConfigNode(text, currentNode); if (this.rootNode == null) { this.rootNode = this.currentNode; } else { currentNode.AddChild(this.currentNode); } } else { this.depth++; } } else if ((nType == ConfigNodeType.PCData) && (this.currentNode != null)) { this.currentNode.Value = text; } }
public override void CreateNode(int size, ConfigNodeSubType subType, ConfigNodeType nType, int terminal, [MarshalAs(UnmanagedType.LPWStr)] string text, int textLength, int prefixLength) { if (nType == ConfigNodeType.Element) { this.lastProcessed = text; this.lastProcessedEndElement = false; if (this.parsing || this.bNoSearchPath && string.Compare(text, this.treeRootPath[0], StringComparison.OrdinalIgnoreCase) == 0 || this.depth == this.searchDepth && this.searchDepth == this.pathDepth && string.Compare(text, this.treeRootPath[this.pathDepth], StringComparison.OrdinalIgnoreCase) == 0) { this.parsing = true; ConfigNode parent = this.currentNode; this.currentNode = new ConfigNode(text, parent); if (this.rootNode == null) { this.rootNode = this.currentNode; } else { parent.AddChild(this.currentNode); } } else { this.depth = this.depth + 1; } } else { if (nType != ConfigNodeType.PCData || this.currentNode == null) { return; } this.currentNode.Value = text; } }
public override void CreateNode(int size, ConfigNodeSubType subType, ConfigNodeType nType, int terminal, [MarshalAs(UnmanagedType.LPWStr)] String text, int textLength, int prefixLength) { //Trace("CreateNode",size,subType,nType,terminal,text,textLength,prefixLength,0); if (nType == ConfigNodeType.Element) { // New Node lastProcessed = text; lastProcessedEndElement = false; if (parsing || (bNoSearchPath && String.Compare(text, treeRootPath[0], StringComparison.OrdinalIgnoreCase) == 0) || (depth == searchDepth && searchDepth == pathDepth && String.Compare(text, treeRootPath[pathDepth], StringComparison.OrdinalIgnoreCase) == 0)) { parsing = true; ConfigNode parentNode = currentNode; currentNode = new ConfigNode(text, parentNode); if (rootNode == null) { rootNode = currentNode; } else { parentNode.AddChild(currentNode); } } else { depth++; } } else if (nType == ConfigNodeType.PCData) { // Data node if (currentNode != null) { currentNode.Value = text; } } }
public void CreateNode(int size, ConfigNodeSubType subType, ConfigNodeType nType, int terminal, [MarshalAs(UnmanagedType.LPWStr)] String text, int textLength, int prefixLength) { //Trace("CreateNode",size,subType,nType,terminal,text,textLength,prefixLength,0); if (nType == ConfigNodeType.Element) { // New Node lastProcessed = "<" + text + ">"; if (parsing || (bNoSearchPath && String.Compare(text, treeRootPath[0], true, CultureInfo.InvariantCulture) == 0) || (depth == searchDepth && searchDepth == pathDepth && String.Compare(text, treeRootPath[pathDepth], true, CultureInfo.InvariantCulture) == 0)) { parsing = true; ConfigNode parentNode = currentNode; currentNode = new ConfigNode(text, parentNode); if (rootNode == null) { rootNode = currentNode; } else { parentNode.AddChild(currentNode); } } else if (nType == ConfigNodeType.PCData) { // Data node currentNode.Value = text; } else { depth++; } } }