public class CounterBlockMatcher extends Object implements BlockMatcher
BlockMatcher
which match any Block
with the provided class.Constructor and Description |
---|
CounterBlockMatcher()
Count all blocks.
|
CounterBlockMatcher(Block stopBlock)
Find the index of the passed block.
|
Modifier and Type | Method and Description |
---|---|
long |
getCount() |
boolean |
match(Block block)
True if the provided block is matched.
|
public CounterBlockMatcher()
public CounterBlockMatcher(Block stopBlock)
stopBlock
- the block where to stop countingpublic boolean match(Block block)
BlockMatcher
match
in interface BlockMatcher
block
- the block to matchpublic long getCount()
Copyright © 2004–2021 XWiki. All rights reserved.