public async Task <CompletionContext> GetAttributeCompletionDataAsync(IAsyncCompletionSource source, string tagName, CancellationToken token)
        {
            await EnsureLoadedAsync();

            var list    = new XmlSchemaCompletionBuilder(source);
            var element = FindElement(tagName);

            if (element != null)
            {
                prohibitedAttributes.Clear();
                GetAttributeCompletionData(list, element);
            }
            return(new CompletionContext(list.GetItems()));
        }
        public CompletionDataList GetAttributeCompletionData(string tagName)
        {
            EnsureLoaded();

            var list    = new XmlCompletionDataList();
            var element = FindElement(tagName);

            if (element != null)
            {
                prohibitedAttributes.Clear();
                GetAttributeCompletionData(list, element);
            }
            return(list);
        }
Ejemplo n.º 3
0
        public async Task <CompletionDataList> GetAttributeCompletionData(string tagName, CancellationToken token)
        {
            await EnsureLoadedAsync();

            var list    = new XmlCompletionDataList();
            var element = FindElement(tagName);

            if (element != null)
            {
                prohibitedAttributes.Clear();
                GetAttributeCompletionData(list, element);
            }
            return(list);
        }