@Override
  public @Nullable List<String> getLineIndents(final FormattingModel model,
                                               final CodeStyleSettings settings,
                                               final CommonCodeStyleSettings.IndentOptions indentOptions) {
    final FormattingDocumentModel documentModel = model.getDocumentModel();
    final Block block = model.getRootBlock();
    if (block.getTextRange().isEmpty()) return Collections.emptyList(); // handing empty document case

    Document document = model.getDocumentModel().getDocument();
    FormatProcessor processor = buildProcessorAndWrapBlocks(model, settings, indentOptions, block.getTextRange(), 0);

    int lines = document.getLineCount();
    List<String> indents = new ArrayList<>(lines);
    for (int i = 0; i < lines; i++) {
      int offset = document.getLineStartOffset(i);
      String indent = generateIndentWhitespace(processor, indentOptions, documentModel, offset);
      indents.add(indent != null ? indent : "");
    }

    return indents;
  }
@Override
  public @Nullable List<String> getLineIndents(final FormattingModel model,
                                               final CodeStyleSettings settings,
                                               final CommonCodeStyleSettings.IndentOptions indentOptions)