@Override
  public FoldingDescriptor @NotNull [] buildFoldRegions(@NotNull ASTNode node, @NotNull Document document) {

    final ArrayList<FoldingDescriptor> regions = new ArrayList<>();
    process(node, document, regions);

    return regions.size() > 0
           ? regions.toArray(FoldingDescriptor.EMPTY_ARRAY)
           : FoldingDescriptor.EMPTY_ARRAY;
  }
@Override
  public FoldingDescriptor @NotNull [] buildFoldRegions(@NotNull ASTNode node, @NotNull Document document)