congrats Icon
New! Announcing our next generation AI code completions
Read here
Tabnine Logo
NodeSelector.createCSSelly
Code IndexAdd Tabnine to your IDE (free)

How to use
createCSSelly
method
in
jodd.lagarto.dom.NodeSelector

Best Java code snippets using jodd.lagarto.dom.NodeSelector.createCSSelly (Showing top 1 results out of 315)

origin: org.jodd/jodd-wot

/**
 * Selects nodes using CSS3 selector query.
 */
public LinkedList<Node> select(String query) {
  String[] singleQueries = StringUtil.splitc(query, ',');
  
  LinkedList<Node> results = new LinkedList<Node>();
  for (String singleQuery : singleQueries) {
    CSSelly csselly = createCSSelly(singleQuery);
    List<CssSelector> selectors = csselly.parse();
    List<Node> selectedNodes = select(rootNode, selectors);
    for (Node selectedNode : selectedNodes) {
      if (results.contains(selectedNode) == false) {
        results.add(selectedNode);
      }
    }
  }
  return results;
}
jodd.lagarto.domNodeSelectorcreateCSSelly

Javadoc

Creates CSSelly instance for parsing files.

Popular methods of NodeSelector

  • <init>
  • select
    Selects nodes using NodeFilter.
  • filter
    Filter nodes.
  • selectAndAdd
    Selects single node for single selector and appends it to the results.
  • walk
  • walkDescendantsIteratively
    Walks over the child notes, maintaining the tree order and not using recursion.
  • processSelectors
    Process selectors and keep adding results.
  • selectFirst
    Selects nodes using NodeFilter and return the very first one.

Popular in Java

  • Parsing JSON documents to java classes using gson
  • notifyDataSetChanged (ArrayAdapter)
  • getContentResolver (Context)
  • setRequestProperty (URLConnection)
  • BufferedReader (java.io)
    Wraps an existing Reader and buffers the input. Expensive interaction with the underlying reader is
  • URLConnection (java.net)
    A connection to a URL for reading or writing. For HTTP connections, see HttpURLConnection for docume
  • Format (java.text)
    The base class for all formats. This is an abstract base class which specifies the protocol for clas
  • Annotation (javassist.bytecode.annotation)
    The annotation structure.An instance of this class is returned bygetAnnotations() in AnnotationsAttr
  • JPanel (javax.swing)
  • Runner (org.openjdk.jmh.runner)
  • Top 15 Vim Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now