|
-
July 23rd, 2007, 01:41 PM
#1
Split huge file during writing.
Hi.
I have freemarker template, which produce huge file.
Code:
template.procced(bean, writer);
I have to provider a writer for this function, which split result on several files.
So, as I understand, the solution is to provide some ZipWriter, which archives file and split it into several files.
This way user, which receives result files could get the result file, without knowledge about how it was produced.
The question is how to realize this strategy? Any classes, which could help me?
Or any solution how to truncate writing after it have reached size limit? Result from template is html string, so I have to terminate file writing process, but result html should remain well-formed.
Any help and ideas welcome!
-
July 24th, 2007, 08:21 AM
#2
Re: Split huge file during writing.
So, as I understand, the solution is to provide some ZipWriter, which archives file and split it into several files.
This way user, which receives result files could get the result file, without knowledge about how it was produced.
The question is how to realize this strategy? Any classes, which could help me?
Java has the ability to write .zip files but not to split the zip file so there are no standard classes that will do what you want, but there are free splitters available such as HJSplit for Java (which I've never used so can't vouch for) which may do what you want.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|