title: how to use Java PushbackInputStream to read a number
body: <p>I need to read off a number (could be integer, double, positive, negative, etc.) from <code>PushbackInputStream</code>. Does I have to read byte by byte and testing whether they are between <code>0-9</code> and also testing the delimiting space?</p>
  
  <p>Or how to read the rest in the stream into a String array using spaces as separation?</p>
  
  <p><strong>Edit</strong></p>
  
  <p>Let me make myself a bit more clear. I want to do some parsing of expressions involving operators and numbers. I probably (what is your good way if not?) need to use <code>PushbackInputStream</code> whenever I encounter the part of a number instead an operator, since in this case I will unread/pushback the part for the number I just mistakenly read. For example, I want to parse "10+20*30", I read <code>1</code>, which is not in the <code>enum</code> of my operators, I put it back, try to read a number off the <code>PushbackInputStream</code>. So how to do it here?</p>