起步软件技术论坛-X3

 找回密码
 立即注册
搜索
12
返回列表 发新帖
楼主: xjc

【结贴】二进制流问题**

[复制链接]
发表于 2008-8-25 14:53:53 | 显示全部楼层
好,等楼主找到好办法了,共享一下.
先贴了,有问题发新贴.
回复 支持 反对

使用道具 举报

 楼主| 发表于 2008-8-26 08:51:04 | 显示全部楼层
找到解决方法了.
InputStream in = rs.getBinaryStream("fcontent");

                                String body = null;
                                DefaultStyledDocument styled = new DefaultStyledDocument();

                                new RTFEditorKit().read(in, styled, 0);
                                body = new String(styled.getText(0, styled.getLength()).getBytes(
                                                "ISO8859_1"));
                                System.out.println("body--------" + body);
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

小黑屋|手机版|Justep Inc.

GMT+8, 2025-7-20 22:54 , Processed in 0.040006 second(s), 12 queries .

Powered by Discuz! X3.4

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表