private static @Nullable WhiteSpace getWhiteSpaceAtOffset(int offset,
                                                            @NotNull FormatProcessor formatProcessor) {
    final LeafBlockWrapper blockAfterOffset = formatProcessor.getBlockRangesMap().getBlockAtOrAfter(offset);
    if (blockAfterOffset != null) {
      if (!blockAfterOffset.contains(offset)) return blockAfterOffset.getWhiteSpace();
    }
    else {
      if (offset >= formatProcessor.getLastWhiteSpace().getStartOffset()) {
        return formatProcessor.getLastWhiteSpace();
      }
    }
    return null;
  }
private static @Nullable WhiteSpace getWhiteSpaceAtOffset(int offset,
                                                            @NotNull FormatProcessor formatProcessor)