Exemplo n.º 1
0
        public IEnumerable<string> Find(string text)
        {
            var htmlAttributes = new HtmlAttributeParse(_setting.XPathAttributeMap.XPath, _setting.XPathAttributeMap.Attribute);

            var attributes = htmlAttributes.Parse(text);

            var findResult = new List<string>();

            foreach (var attribute in attributes)
            {
                if (IsMatch(attribute))
                {
                    findResult.Add(Transform(attribute));
                }
            }

            return findResult;
        }
Exemplo n.º 2
0
        public IEnumerable <string> Find(string text)
        {
            var htmlAttributes = new HtmlAttributeParse(_setting.XPathAttributeMap.XPath, _setting.XPathAttributeMap.Attribute);

            var attributes = htmlAttributes.Parse(text);

            var findResult = new List <string>();

            foreach (var attribute in attributes)
            {
                if (IsMatch(attribute))
                {
                    findResult.Add(Transform(attribute));
                }
            }

            return(findResult);
        }
Exemplo n.º 3
0
        private void Parse(string text)
        {
            var htmlAttributes = new HtmlAttributeParse(_config.LookUp.XPath, _config.LookUp.Attribute);

            var attributes = htmlAttributes.Parse(text);

            foreach(var attribute in attributes)
            {
                if (_isCanceled)
                {
                    return;
                }

                if (IsMatch(attribute))
                {
                    InternalOnDiscovered(attribute);
                }
            }
        }
Exemplo n.º 4
0
        private void Parse(string text)
        {
            var htmlAttributes = new HtmlAttributeParse(_config.LookUp.XPath, _config.LookUp.Attribute);

            var attributes = htmlAttributes.Parse(text);

            foreach (var attribute in attributes)
            {
                if (_isCanceled)
                {
                    return;
                }

                if (IsMatch(attribute))
                {
                    InternalOnDiscovered(attribute);
                }
            }
        }