//
// openzwave provides a thin Go wrapper around the openzwave library.
//
// The following shows a simple use of the API which will log every notification received.
//
//        var loop = func(api openzwave.API) {
//                fmt.Printf("event loop starts\n")
//                for {
//                        select {
//                        case notification := <-api.Notifications():
//                                fmt.Printf("notification received - %v", notification)
//                                api.FreeNotification(notification)
//                        case quitNow := <-api.QuitSignal():
//                                _ = quitNow
//                                fmt.Printf("event loop ends\n")
//                                return
//                        }
//                }
//        }
//
//        os.Exit(openzwave.
//                BuildAPI("../go-openzwave/openzwave/config", "", "").
//                AddIntOption("SaveLogLevel", LOG_LEVEL.NONE).
//                AddIntOption("QueueLogLevel", LOG_LEVEL.NONE).
//                AddIntOption("DumpTrigger", LOG_LEVEL.NONE).
//                AddIntOption("PollInterval", 500).
//                AddBoolOption("IntervalBetweenPolls", true).
//                AddBoolOption("ValidateValueChanges", true).
//                Run(loop))
package openzwave

//
// openzwave provides a thin Go wrapper around the openzwave library.
//
// The following shows a simple use of the API which will log every notification received.
//
//        var loop = func(api openzwave.API) {
//                fmt.Printf("event loop starts\n")
//                for {
//                        select {
//                        case quitNow := <-api.QuitSignal():
//                                _ = quitNow
//                                fmt.Printf("event loop ends\n")
//                                return
//                        }
//                }
//        }
//
//        os.Exit(openzwave.
//                BuildAPI("../go-openzwave/openzwave/config", "", "").
//                AddIntOption("SaveLogLevel", LOG_LEVEL.NONE).
//                AddIntOption("QueueLogLevel", LOG_LEVEL.NONE).
//                AddIntOption("DumpTrigger", LOG_LEVEL.NONE).
//                AddIntOption("PollInterval", 500).
//                AddBoolOption("IntervalBetweenPolls", true).
//                AddBoolOption("ValidateValueChanges", true).
//                Run(loop))
package openzwave

Remove misleading example - api.Notifications() was removed from the API in favour of a callback.
Remove misleading example - api.Notifications() was removed from the API in favour of a callback.

(We need processing associated with the callback to be complete by the time the callback completes.
Use of a channel would require that we copy the C notification into the Go heap on every notification and
I didn't want to require that cost)

Signed-off-by: Jon Seymour <44f878afe53efc66b76772bd845eb65944ed8232@ninjablocks.com>
