commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stephen Colebourne <scolebou...@btopenworld.com>
Subject Re: Looking for a string to file appending function
Date Thu, 06 Apr 2006 23:08:13 GMT
Kenneth Love wrote:
> org.apache.commons.io.FileUtils.writeStringToFile(file, msg, encoding)
> 
> I need to append to an already existing file.  Unfortunately, the
> function call above overwrites the contents of the file.
> 
> Does a function with the functionality I need already exist somewhere
> in the Jakarta Commons libraries?

At present there is no such method in [io] or any other commons library. 
I recommend that you open a bugzilla enhancemnet request (following the 
instructions on the website). If possible, you could write the code and 
unit test and add them to the call.

BTW, we try to avoid boolean flag parameters, as they represent a bit of 
a code smell. Thus we would favour an appendStringToFile() method

Stephen


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message