aspose file tools*
The moose likes Beginning Java and the fly likes String to InputStream ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "String to InputStream ?" Watch "String to InputStream ?" New topic
Author

String to InputStream ?

justin wall
Greenhorn

Joined: Jul 30, 2001
Posts: 8
I'm using a package call Zql to parse an SQL statement and derive the tables, columns, etc. from it. The parser in Zql is expecting an InputStream and my SQL is in a String variable. Is there a way to convert a String to an InputStream in order to use this package?
Thanks,
Justin Wall
Aaron Webb
Greenhorn

Joined: Aug 16, 2001
Posts: 17
String test = "This is a test";
InputStream is = new ByteArrayInputStream(test.getBytes());
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: String to InputStream ?