syncbase/bridge/cgo: Two changes to the C API for handling callbacks

The first change is to switch the handle from 'int' to 'void*'. This
will help interfacing with language where is easier to pass a pointer
to a struct instead of explicitly managing the mapping to it. Both
Java and Swift manage memory in a way that makes is hard/impossible
to use pointers so the 'void*' will be used as a larger 'int'.

The second change is to use a single handle instead of two for both
watching and scanning. This makes the C API simpler and is more inline
with what the Java/Swift need to do (namely, keeping a struct that
describes both callbacks).

Note: the author of the Swift code is Aaron Zinman <aaron@azinman.com>.

MultiPart: 1/2
Change-Id: I6aa1f300a7d97aa1c9ef0f20b08cde7ac29cd5fa
2 files changed
tree: 584356f384627204c2d5144b3b8fb055b8d5028e
  1. cmd/
  2. examples/
  3. internal/
  4. lib/
  5. runtime/
  6. services/
  7. test/
  8. .gitignore
  9. AUTHORS
  10. CONTRIBUTING.md
  11. CONTRIBUTORS
  12. envvar.go
  13. envvar_test.go
  14. LICENSE
  15. PATENTS
  16. README.md
  17. VERSION
README.md

Vanadium

This repository contains a reference implementation of the Vanadium APIs.

Unlike the APIs in https://github.com/vanadium/go.v23, which promises to provide backward compatibility this repository makes no such promises.