private void recursiveLogResult(StringBuilder buf, Hierarchy<Result> hier, Result result, int depth) {
    if(result == null) {
      buf.append("null");
      LOG.warning("null result!");
      return;
    }
    if(depth > 50) {
      LOG.warning("Probably infinitely nested results, aborting!");
      return;
    }
    for(int i = 0; i < depth; i++) {
      buf.append(' ');
    }
    buf.append(result.getClass().getSimpleName()).append(": ").append(result.getLongName()) //
        .append(" (").append(result.getShortName()).append(")\n");
    if(hier.numChildren(result) > 0) {
      for(It<Result> iter = hier.iterChildren(result); iter.valid(); iter.advance()) {
        recursiveLogResult(buf, hier, iter.get(), depth + 1);
      }
    }
  }
private void recursiveLogResult ( StringBuilder buf , Hierarchy < Result > hier , Result result , int depth ) { if ( result == null ) { buf . append ( "null" ) ; LOG . warning ( "null result!" ) ; return ; } if ( depth > 50 ) { LOG . warning ( "Probably infinitely nested results, aborting!" ) ; return ; } for ( int i = 0 ; i < depth ; i ++ ) { buf . append ( ' ' ) ; } buf . append ( result . getClass ( ) . getSimpleName ( ) ) . append ( ": " ) . append ( result . getLongName ( ) ) . append ( " (" ) . append ( result . getShortName ( ) ) . append ( ")\n" ) ; if ( hier . numChildren ( result ) > 0 ) { for ( It < Result > iter = hier . iterChildren ( result ) ; iter . valid ( ) ; iter . advance ( ) ) { recursiveLogResult ( buf , hier , iter . get ( ) , depth + 1 ) ; } } }
Recursively walk through the result tree.

@param buf Output buffer
@param result Current result
@param depth Depth