@NotNull
  protected List<T> getElement(@NotNull Editor editor, @NotNull PsiFile file) {
    final SelectionModel selectionModel = editor.getSelectionModel();
    if (selectionModel.hasSelection()) {
      return Collections.singletonList(getElementFromSelection(file, selectionModel));
    }
    return getElementAtOffset(editor, file);
  }
@NotNull
  protected List<T> getElement(@NotNull Editor editor, @NotNull PsiFile file)