Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Cascading Streams(Cipher,GZip,FileInput,ProgressMonitor)  RSS feed

 
Lefty Gomez
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How do I put all these filter streams in cascade so I have to only make a read(byte[]) call on the input stream?
 
Valentin Crettaz
Gold Digger
Sheriff
Posts: 7610
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A way to do it is the following:

HIH
------------------
Valentin Crettaz
Sun Certified Programmer for Java 2 Platform
[This message has been edited by Valentin Crettaz (edited November 16, 2001).]
[This message has been edited by Valentin Crettaz (edited November 16, 2001).]
 
Lefty Gomez
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And what I do to write the file?
Originally posted by Valentin Crettaz:
[B]A way to do it is the following:

HIH
[/B]

 
Valentin Crettaz
Gold Digger
Sheriff
Posts: 7610
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Note that there is no ProgressMonitorOutputStream... So I don't know if you want to monitor the progress of the writing process too... Otherwise, if the progress monitoring is not mandatory, you use almost the same code by replacing "Input" by "Output" and use write instead of read. You may have to adapt some parameter list of the constructors, check the API ...
HIH
------------------
Valentin Crettaz
Sun Certified Programmer for Java 2 Platform
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!