I'm writing a parser and I have a class tokenize which creates tokens given an input stream. In class tokenize I want to have an istream and ostream that reference the file passed to the constructor, so that I don't need to pass these files on each call to the tokenizer object. I want to be able to open the files independently of the tokenizer object, so I can't just open the files in the constructor. I've thought maybe if I make i/o stream pointers in the class declaration, then do *in = inFile, *out = outFile (inFile and outFile being the files passed by reference to the contructor and in and out being the i/o stream pointers.) The only problem is that in >> <some variable> and out << <whatever> won't really work, maybe *in >> <some variable> and *out << <whatever> will....I guess I don't thoroughly know how streams work. Anyways, any help would be appreciated.