func CreateFoo(create func(NextFoo, Error, Complete, Canceled)) ObservableFoo {
	observable := func(observe FooObserver, scheduler Scheduler, subscriber Subscriber) {
		runner := scheduler.Schedule(func() {
			if !subscriber.Subscribed() {
				return
			}
			n := func(next foo) {
				if subscriber.Subscribed() {
					observe(next, nil, false)
				}
			}
			e := func(err error) {
				if subscriber.Subscribed() {
					var zero foo
					observe(zero, err, true)
				}
			}
			c := func() {
				if subscriber.Subscribed() {
					var zero foo
					observe(zero, nil, true)
				}
			}
			x := func() bool {
				return !subscriber.Subscribed()
			}
			create(n, e, c, x)
		})
		subscriber.OnUnsubscribe(runner.Cancel)
	}
	return observable
}
jig:template Create<Foo>
jig:needs Error, Complete, Canceled, Next<Foo>, Observable<Foo>
CreateFoo provides a way of creating an ObservableFoo from
scratch by calling observer methods programmatically.

The create function provided to CreateFoo will be called once
to implement the observable. It is provided with a NextFoo, Error,
Complete and Canceled function that can be called by the code that
implements the Observable.
package rx
import "time"
type Error func(error)
type Complete func()
type Canceled func() bool
type NextFoo func(foo)