Package org.neo4j.gds.doc
Class QueryConsumingTreeProcessor
- java.lang.Object
-
- org.asciidoctor.extension.BaseProcessor
-
- org.asciidoctor.extension.Treeprocessor
-
- org.neo4j.gds.doc.QueryConsumingTreeProcessor
-
- All Implemented Interfaces:
org.asciidoctor.extension.Processor
public class QueryConsumingTreeProcessor extends org.asciidoctor.extension.TreeprocessorExtension for Asciidoctor. It looks for two kinds of blocks in the AsciiDoc source: 1) Blocks with the role `setup-query`. The content is passed to a SetupQueryConsumer. A doc test can use this by making the SetupQueryConsumer run the content as a setup query before running tests. 2) Blocks with the role `query-example`. The content is expected to contain exactly two blocks: 2.1) First, a block containing a Cypher query example. 2.2) Second, a table containing a Cypher query result. The query, the table header, and all the rows, are passed to the QueryExampleConsumer. A doc test can use this by making the QueryExampleConsumer run the queries and assert that the result on each row matches the result
-
-
Constructor Summary
Constructors Constructor Description QueryConsumingTreeProcessor(org.neo4j.gds.doc.QueryConsumingTreeProcessor.SetupQueryConsumer setupQueryConsumer, org.neo4j.gds.doc.QueryConsumingTreeProcessor.QueryExampleConsumer queryExampleConsumer, org.neo4j.gds.doc.QueryConsumingTreeProcessor.QueryExampleNoResultConsumer queryExampleNoResultConsumer, java.lang.Runnable cleanup)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.asciidoctor.ast.Documentprocess(org.asciidoctor.ast.Document document)-
Methods inherited from class org.asciidoctor.extension.BaseProcessor
createBlock, createBlock, createBlock, createBlock, createBlock, createBlock, createBlock, createDocument, createList, createList, createList, createListItem, createListItem, createPhraseNode, createPhraseNode, createPhraseNode, createPhraseNode, createPhraseNode, createPhraseNode, createSection, createSection, createSection, createSection, createSection, createTable, createTable, createTableCell, createTableCell, createTableCell, createTableCell, createTableColumn, createTableColumn, createTableRow, getConfig, log, parseContent, setConfig, unwrap, updateConfig
-
-
-
-
Constructor Detail
-
QueryConsumingTreeProcessor
public QueryConsumingTreeProcessor(org.neo4j.gds.doc.QueryConsumingTreeProcessor.SetupQueryConsumer setupQueryConsumer, org.neo4j.gds.doc.QueryConsumingTreeProcessor.QueryExampleConsumer queryExampleConsumer, org.neo4j.gds.doc.QueryConsumingTreeProcessor.QueryExampleNoResultConsumer queryExampleNoResultConsumer, java.lang.Runnable cleanup)
-
-