private static @Nullable Collection<Pair<PsiElement, BreadcrumbsProvider>> getLineElements(Document document,
                                                                                             int offset,
                                                                                             VirtualFile file,
                                                                                             Project project,
                                                                                             BreadcrumbsProvider defaultInfoProvider,
                                                                                             boolean checkSettings) {
    PsiElement element = findStartElement(document, offset, file, project, defaultInfoProvider, checkSettings, false);
    if (element == null) return null;

    LinkedList<Pair<PsiElement, BreadcrumbsProvider>> result = new LinkedList<>();
    while (element != null) {
      BreadcrumbsProvider provider = findProviderForElement(element, defaultInfoProvider, checkSettings);

      if (provider != null && provider.acceptElement(element)) {
        result.addFirst(Pair.create(element, provider));
      }

      element = getParent(element, provider);
      if (element instanceof PsiDirectory) break;
    }
    return result;
  }
private static @Nullable Collection<Pair<PsiElement, BreadcrumbsProvider>> getLineElements(Document document,
                                                                                             int offset,
                                                                                             VirtualFile file,
                                                                                             Project project,
                                                                                             BreadcrumbsProvider defaultInfoProvider,
                                                                                             boolean checkSettings)