This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 34692

Summary: Allow getting an InputStream for the current content of the editor
Product: platform Reporter: Petr Jiricka <pjiricka>
Component: TextAssignee: David Konecny <dkonecny>
Status: RESOLVED FIXED    
Severity: blocker CC: mentlicher
Priority: P3 Keywords: API
Version: 3.x   
Hardware: All   
OS: All   
Issue Type: ENHANCEMENT Exception Reporter:

Description Petr Jiricka 2003-06-30 13:06:07 UTC
It would be useful to have a generic way of
obtaining an InputStream containing the current
(possibly modified) content  of the editor window. 

Currently this can be done if the client of such a
feature also "owns" the (subclass of) the
CloneableEditor support. 

Currently, it is possible to get the content as
String in a generic way, however, this is not what
we want, since
- the String can not be converted to InputStream,
as we don't know the encoding
- the String will not contain characteds such as
guarded section markers

Related to issue 19928.
Comment 1 Petr Jiricka 2003-06-30 13:39:47 UTC
Fixed in the trunk.

Checking in CloneableEditorSupport.java;
/cvs/openide/src/org/openide/text/CloneableEditorSupport.java,v  <-- 
CloneableEditorSupport.java
new revision: 1.90; previous revision: 1.89
done

Diff:
http://openide.netbeans.org/source/browse/openide/src/org/openide/text/CloneableEditorSupport.java.diff?r1=1.88&r2=1.90