Extract WaitForStream function

The wait code from the example app is quite helpful. This give users of
the library an opportunity to leverage it without duplication.

* Add short-circuit on CreateStream if it already exists
* Extract WaitForStream function