void replaceElement(@Nullable PsiElement element, PlaceholderCount count, boolean preferOriginal, TemplateBuilder builder, int shift) {
    if (element == null) {
      return;
    }
    String placeholder = count.getPlaceholder();
    String originalText = element.getText();
    LookupElement[] elements = {LookupElementBuilder.create(placeholder), LookupElementBuilder.create(originalText)};
    builder.replaceRange(element.getTextRange().shiftLeft(shift),
                         new ConstantNode(preferOriginal ? originalText : placeholder)
                           .withLookupItems(preferOriginal ? ArrayUtil.reverseArray(elements) : elements));
  }
void replaceElement(@Nullable PsiElement element, PlaceholderCount count, boolean preferOriginal, TemplateBuilder builder, int shift)