RFR: JDK-8167648: java.io.PrintWriter should have PrintWriter((String|File), Charset) constructors (original) (raw)
Patrick Reinhart patrick at reini.net
Wed Nov 23 13:45:59 UTC 2016
- Previous message: RFR: JDK-8167648: java.io.PrintWriter should have PrintWriter((String|File), Charset) constructors
- Next message: RFR: 8169993: Class::desiredAssertionStatus should call getClassLoader0
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 2016-11-23 14:35, Jonathan Bluett-Duncan wrote:
Hi Patrick,
Have you considered making
withAutoFlush()
return thePrintWriter
itself, allowing fluent code snippets like the following?_ _PrintWriter writer = new PrintWriter(new File("path/to/file.txt"),_ _StandardCharsets.UTF8).withAutoFlush();_ _
Good point. I taught about it, but it somehow got lost on the way of re-wiring the constructors... :-)
Just updated the webrev
-Patrick
- Previous message: RFR: JDK-8167648: java.io.PrintWriter should have PrintWriter((String|File), Charset) constructors
- Next message: RFR: 8169993: Class::desiredAssertionStatus should call getClassLoader0
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]