@Override
  public void writeFoldingState(@NotNull CodeFoldingState state, @NotNull Element element) {
    if (state instanceof DocumentFoldingInfo) {
      ((DocumentFoldingInfo)state).writeExternal(element);
    }
  }
@Override
  public void writeFoldingState(@NotNull CodeFoldingState state, @NotNull Element element)