Interface SplittingCriterion

  • All Known Implementing Classes:
    HeadingLevelSplittingCriterion

    public interface SplittingCriterion
    An interface defining the office importer document splitting process.
    Since:
    1.9M1
    Version:
    $Id: 8943594e2fd03dda36c4719492f539ac8d6d02e3 $
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      boolean shouldIterate​(org.xwiki.rendering.block.Block block, int depth)
      Limits the recursive tree traversal performed by the DocumentSplitter.
      boolean shouldSplit​(org.xwiki.rendering.block.Block block, int depth)
      Indicates if the sub-tree rooted at the given block should be split into a separate document.
    • Method Detail

      • shouldIterate

        boolean shouldIterate​(org.xwiki.rendering.block.Block block,
                              int depth)
        Limits the recursive tree traversal performed by the DocumentSplitter.
        Parameters:
        block - current Block being traversed by the document splitter.
        depth - depth of this block w.r.t root of the main xdom being split.
        Returns:
        true if the sub-tree rooted at this block should be traversed further.
      • shouldSplit

        boolean shouldSplit​(org.xwiki.rendering.block.Block block,
                            int depth)
        Indicates if the sub-tree rooted at the given block should be split into a separate document.
        Parameters:
        block - current Block being traversed by the document splitter.
        depth - depth of this block w.r.t root of the main xdom being split.
        Returns:
        true if the sub-tree rooted at this block should be split into a separate document.