I have previously questioned the what seem like weird method names in Java’s newish ProcessBuilder API. It turns out that its not-newish-at-all close personal friend Process is little strange too: it has getOutputStream and getInputStream which respectively get you pipes to the process’ standard input and output. Data comes out of the Process and you want an InputStream, so it has to be getInputStream. But how can getOutput get you the input while getError gets you the error? OK, call me anal, I can take it. But I’m writing a class right now kinda like Process, and I simply absolutely can’t bring myself to call the input the output and vice versa. So I have getTaskInput, getTaskOutput, and getTaskError, which produce output, input, and input streams respectively. We all have to deal with the confusing nature of reality in our own ways.


ongoing
software · G & M · Dad author · colophon · rights
picture of the day
Around September 19, 2005: New England Town Meeting · GAIM & Adium, Good Stuff · Yellow Rose · Apple File Formats · The Important Things in Life

What?
· Technology (61 fragments)
· · Coding (73 fragments)
· · · Java (23 more)


Serif · Sans-Serif
I work at Sun Microsystems. The opinions expressed here are my own, and neither Sun nor any other party necessarily agrees with them.