- public static void traverse(Content content, BiConsumer<Content, Integer> doIt, int currentDepth) {
+ public static void traverse(Content content, BiConsumer<Content, Integer> doIt, Integer maxDepth) {
+ doTraverse(content, doIt, 0, maxDepth);
+ }
+
+ private static void doTraverse(Content content, BiConsumer<Content, Integer> doIt, int currentDepth,
+ Integer maxDepth) {