/// <summary> /// Gets the child element completion data for the xml element that exists /// at the end of the specified path. /// </summary> public ICompletionData[] GetChildElementCompletionData(XmlElementPath path) { _namespaces = path.Namespaces; XmlCompletionDataCollection data = new XmlCompletionDataCollection(); // Locate matching element. XmlSchemaElement element = FindElement(path); // Get completion data. if (element != null) { data = GetChildElementCompletionData(element, path.Elements.LastPrefix); } return data.ToArray(); }
/// <summary> /// Gets the autocomplete data for the specified attribute value. /// </summary> public ICompletionData[] GetAttributeValueCompletionData(XmlElementPath path, string name) { _namespaces = path.Namespaces; XmlCompletionDataCollection data = new XmlCompletionDataCollection(); // Locate matching element. XmlSchemaElement element = FindElement(path); // Get completion data. if (element != null) { data = GetAttributeValueCompletionData(element, name); } return data.ToArray(); }
/// <summary> /// Gets the attribute completion data for the xml element that exists /// at the end of the specified path. /// </summary> public ICompletionData[] GetAttributeCompletionData(XmlElementPath path) { XmlCompletionDataCollection data = new XmlCompletionDataCollection(); // Locate matching element. XmlSchemaElement element = FindElement(path); // Get completion data. if (element != null) { prohibitedAttributes.Clear(); data = GetAttributeCompletionData(element); } return data.ToArray(); }