从我的应用程序生成的 graphml 无法在 yEd 图形编辑器上打开

发布于 2024-12-28 06:58:23 字数 2213 浏览 3 评论 0原文

我从用 Delphi7 编写的应用程序生成 graphml 文件。一切都很好,除了当我使用 yEd 图形编辑器打开一些 graphml 文件时它会引发这样的错误。

test.graphml.
    at B.A.A.I.A.ā(Unknown Source)
    at B.A.A.I.D.ā(Unknown Source)
    at B.A.A.I.D.ă(Unknown Source)
    at B.A.A.B$4.run(Unknown Source)
    at B.A.A.U.Ċ(Unknown Source)
    at B.A.A.U$1.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
Caused by: D.H.B.B.a: IOException :Invalid byte 1 of 1-byte UTF-8 sequence.
    at D.H.B.B._.ā(Unknown Source)
    at D.H.B.A$13.ā(Unknown Source)
    at D.H.B.A.ā(Unknown Source)
    at D.H.B.A.ā(Unknown Source)
    at D.H.S.ā(Unknown Source)
    at B.A.A.I.A.A.ā(Unknown Source)
    at B.A.A.B.I.O.Ă(Unknown Source)
    at B.A.A.B.I.O.ā(Unknown Source)
    at B.A.A.O.E.ā(Unknown Source)
    ... 7 more
Caused by: com.sun.org.apache.xerces.internal.impl.io.MalformedByteSequenceException: Invalid byte 1 of 1-byte UTF-8 sequence.
    at com.sun.org.apache.xerces.internal.impl.io.UTF8Reader.invalidByte(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.io.UTF8Reader.read(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLEntityScanner.load(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLEntityScanner.peekChar(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(Unknown Source)
    at javax.xml.parsers.DocumentBuilder.parse(Unknown Source)
    ... 16 more

我是如何解决这个问题的?先感谢您。

I generate graphml file from my application writing in Delphi7. Every thing is fine except when I open some my graphml file using yEd Graph Editor It raise Error like this.

test.graphml.
    at B.A.A.I.A.ā(Unknown Source)
    at B.A.A.I.D.ā(Unknown Source)
    at B.A.A.I.D.ă(Unknown Source)
    at B.A.A.B$4.run(Unknown Source)
    at B.A.A.U.Ċ(Unknown Source)
    at B.A.A.U$1.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
Caused by: D.H.B.B.a: IOException :Invalid byte 1 of 1-byte UTF-8 sequence.
    at D.H.B.B._.ā(Unknown Source)
    at D.H.B.A$13.ā(Unknown Source)
    at D.H.B.A.ā(Unknown Source)
    at D.H.B.A.ā(Unknown Source)
    at D.H.S.ā(Unknown Source)
    at B.A.A.I.A.A.ā(Unknown Source)
    at B.A.A.B.I.O.Ă(Unknown Source)
    at B.A.A.B.I.O.ā(Unknown Source)
    at B.A.A.O.E.ā(Unknown Source)
    ... 7 more
Caused by: com.sun.org.apache.xerces.internal.impl.io.MalformedByteSequenceException: Invalid byte 1 of 1-byte UTF-8 sequence.
    at com.sun.org.apache.xerces.internal.impl.io.UTF8Reader.invalidByte(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.io.UTF8Reader.read(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLEntityScanner.load(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLEntityScanner.peekChar(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(Unknown Source)
    at javax.xml.parsers.DocumentBuilder.parse(Unknown Source)
    ... 16 more

How I solved this problem? Thank you in advance.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

呆° 2025-01-04 06:58:23

我认为问题应该来自 Unicode 无效的字节序列问题,但没有你的文件我只能猜测。

我认为您可以从非 Unicode 编码文件加载字符串并直接使用它,而无需转换为 Unicode 编码。请尝试通过查看 这篇文章

I think problem should come from Unicode invalid bytes sequence problem but without your file I can only guess.

I think you may load string from non-Unicode encoding file and use it directly without convert to Unicode encoding. Please try convert these strings to Unicode by see this post.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文