/** * subclasses may override this method to add blocks to the Textile language. Overriding classes should call * <code>super.addBlockExtensions(blocks,paragraphBreakingBlocks)</code> if the default language extensions are * desired (glossary and table of contents). * * @param blocks * the list of blocks to which extensions may be added * @param paragraphBreakingBlocks * the list of blocks that end a paragraph */ @Override protected void addBlockExtensions(List<Block> blocks, List<Block> paragraphBreakingBlocks) { blocks.add(new TextileGlossaryBlock()); blocks.add(new TableOfContentsBlock()); super.addBlockExtensions(blocks, paragraphBreakingBlocks); }
protected final void initializeBlocks() { addStandardBlocks(blocks, paragraphBreakingBlocks); // extensions addBlockExtensions(blocks, paragraphBreakingBlocks); if (configuration != null) { configuration.addBlockExtensions(blocks, paragraphBreakingBlocks); } // ~extensions blocks.add(createParagraphBlock()); // ORDER DEPENDENCY: this must come last }