List<Block> (ASTNode node, BlockFactory factory) { List<Block> blocks = new ArrayList<>(); for (ASTNode child : node.getChildren(null)) { if (FormatterUtil.isWhitespaceOrEmpty(child) || child.getTextLength() == 0) { continue; } Alignment alignment = myConfig.getAlignment(child); IElementType type = child.getElementType(); Indent indent = myConfig.getIndent(type); Wrap wrap = myConfig.getWrap(type); blocks.add(factory.createBlock(child, indent, alignment, wrap, factory.getFormattingMode())); } return blocks; }