Libgdx: iOS SDK and RoboVM

I have an application project using libgdx 1.2. I want to add alerts for my iOS and Android. No problem with the regular java interface that allows the underlying application to access native platform methods, but I have quite a few problems understanding how to call SDK methods from RoboVM Java code, for example, assuming NativeMethods was my interface for Access to public methods and IOS innovations: iOS RoboVM implementation:

public class IOSNatives implements NativeMethods
  public void pushNotifications()
    // how do I write the java code equivalent to this example?
    // step 5 here:


I mean, step 5 is here : and then I need some hints about steps 1-4 too ...

I already searched SO for similar questions, but the only thing I could find was this

Is there a way for push notifications in libGDX (Android and iOS projects)?

which doesn't really say what I need.


source to share

1 answer

To work with IOS sdk written in Objective C you must use bindings. Binding is a wrapper that allows you to call object C code from java. Fortunately, you don't need to write your own parse because there is one here: RoboVM parse binding .

You can look at for example implementation.

You can get more information on bindings and how to add them to your project here



All Articles