• Post Reply Bookmark Topic Watch Topic
  • New Topic

On using Standard Input/Ouput for different purposes.

Fred Hamilton
Ranch Hand
Posts: 684
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have written a lttle Java chess program, it works nicely but plays poorly.

The program consists of two main components, a GUI and an engine (computer brain that makes moves). In order that I can use my GUI with other engines. I need to have my GUI exist independantly of my engine, and furthermore they should communicate according to a standard protocol, which is described here...


This where Java comes in. according to the protocol, the two components communicate via Standard input/output.

I've had a look at http://java.sun.com/docs/books/tutorial/essential/io/cl.html , and I quote the following paragraph:

Standard Streams are a feature of many operating systems. By default, they read input from the keyboard and write output to the display. They also support I/O on files and between programs, but that feature is controlled by the command line interpreter, not the program.

I'm pretty sure I can figure out what I need to do, but I have one question before I start.

Standard Input/Output also refers to keyboard and monitor. With that in mind, what sort of questions have to be dealt with concerning whether standard output needs to be shared between my program and keyboard/monitor.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!