public IList <IDomElement <TDependencyObject> > QuerySelectorAllWithSelf(StyleSheet styleSheet, ISelector selector) { // var selector = cachedSelectorProvider.GetOrAdd(selectors); var check = "StyleInfo check".Measure(() => { if (StyleInfo.CurrentStyleSheet != styleSheet || StyleInfo.DoMatchCheck == SelectorType.None) { return(new List <IDomElement <TDependencyObject> >()); } return(null); }); if (check != null) { return(check); } var res = "ROOT QuerySelectorAll".Measure(() => ChildNodes.QuerySelectorAll(styleSheet, selector)); "match this".Measure(() => { var match = Matches(styleSheet, selector); if (match.IsSuccess) { res.Add(this); } }); return(res); }
public IHtmlCollection <IElement> QuerySelectorAll(string selectors) { if (selectors.Contains("|")) { selectors = selectors.Replace("|", "\\:"); } return(CreateCollection(ChildNodes.QuerySelectorAll(selectors, Parser))); }
public IHtmlCollection <IElement> QuerySelectorAllWithSelf(string selectors) { var selector = cachedSelectorProvider.GetOrAdd(selectors, parser.ParseSelector); var res = ChildNodes.QuerySelectorAll(selector); if (this.Matches(selectors)) { res.Add(this); } return(CreateCollection(res)); }
public IHtmlCollection <IElement> QuerySelectorAllWithSelf(string selectors) { if (selectors.Contains("|")) { selectors = selectors.Replace("|", "\\:"); } var res = ChildNodes.QuerySelectorAll(selectors, Parser); if (this.Matches(selectors)) { res.Add(this); } return(CreateCollection(res)); }
/// <summary> /// Returns a list of the elements within the document (using /// depth-first pre-order traversal of the document's nodes) that match /// the specified group of selectors. /// </summary> /// <param name="selectors"> /// A string containing one or more CSS selectors separated by commas. /// </param> /// <returns>A collection of HTML elements.</returns> public IHtmlCollection <IElement> QuerySelectorAll(String selectors) { return(ChildNodes.QuerySelectorAll(selectors)); }
public IHtmlCollection <IElement> QuerySelectorAll(string selectors) { var selector = cachedSelectorProvider.GetOrAdd(selectors, parser.ParseSelector); return(CreateCollection(ChildNodes.QuerySelectorAll(selector))); }
public IHtmlCollection <IElement> QuerySelectorAll(String selectors) => ChildNodes.QuerySelectorAll(selectors, null);
public IList <IDomElement <TDependencyObject> > QuerySelectorAll(StyleSheet styleSheet, ISelector selector) { // var selector = cachedSelectorProvider.GetOrAdd(selectors); return(ChildNodes.QuerySelectorAll(styleSheet, selector)); }