Elias takes us on a quick tour of Go Mobile to see just how much of your mobile app can be in Go.

View the slides

For quite a while, Go programmers have been able to export their Go package to mobile iOS and Android apps through Go Mobile. With recent additions to Go Mobile, the reverse is now possible: importing and using the platform Java or Objective C API directly from Go, as well as declaring custom Java or Objective C classes that are implemented in Go. For Android, the Go Mobile gradle plugin is now tightly integrated with the Android gradle build system. Project resources, Java code, libraries and even the databinding classes are now all available from Go.

More information:

The golang.org/x/mobile/example/reverse/reverse example is a Android app in 100% Go using the new Java bindings described in the talk. The Gradle plugin is described in godoc.org/golang.org/x/mobile/cmd/gomobile.

An overview of using Java or Objective C from Go is described in godoc.org/golang.org/x/mobile/cmd/gobind.

For even more detail about writing native language bindings, these original proposals are a good start:


About the speaker

Elias Naur
Elias Naur
Contributor to Gomobile

About the conference

dotGo 2016
The European Go conference

Liked this talk? Share it!

Comments

comments powered by Disqus