public @NonNls String dumpString() {
    final @NonNls String[] data = new String[myElements.size()];

    int i = 0;

    for (final PsiElement element : myElements) {
      data[i++] = Util.getType(element).getCanonicalText() + "\\n" + elementString(element);
    }

    return StreamEx.of(data).sorted().map(aData -> aData + "\n").joining();
  }
public @NonNls String dumpString()