Skip to content

Instantly share code, notes, and snippets.

@jetztgradnet
Created January 18, 2011 09:58
Show Gist options
  • Save jetztgradnet/784239 to your computer and use it in GitHub Desktop.
Save jetztgradnet/784239 to your computer and use it in GitHub Desktop.
Accessing a OSGi service from Groovy
import org.osgi.framework.BundleContext
def results = bundleContext.findServices(MyService).withEachService() { MyService srv ->
srv.doSomething()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment