RFR: 8191441: (Process) add Readers and Writer access to java.lang.Process streams [v4]

Roger Riggs rriggs at openjdk.java.net
Wed May 26 18:01:23 UTC 2021


On Tue, 25 May 2021 16:53:28 GMT, Roger Riggs <rriggs at openjdk.org> wrote:

>> Methods are added to java.lang.Process to read and write characters and lines from and to a spawned Process.
>> The Charset used to encode and decode characters to bytes can be specified or use the
>> operating system native encoding as is available from the "native.encoding" system property.
>
> Roger Riggs has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Described charset mapping of malformed chars in outputWriter
>   Repeated calls to  inputReader, errorReader, and outputWriter now return the same instance
>   and check for inconsistent charset argument
>   Added warnings about concurrently use of input/output streams and readers/writers.

Process is abstract. Is there any use for these new methods to be overridden?
Perhaps they should be final.  The suggestion in the CSR was to document them
using @ implSpec, to acknowledge that the subclass can do something different.

-------------

PR: https://git.openjdk.java.net/jdk/pull/4134


More information about the core-libs-dev mailing list