: + input instanceof CharStream ? : + (CharStream)input : : + new CharReader(input)
this seems like it might be a useful idiom to put in a static method of
the CharStream class...
public static CharStream get(Reader input) {
return (input instanceof CharStream) ?
(CharStream)input :
new CharReader(input);
}
-Hoss
