Storage File System access + URL Scheme

96 views
Skip to first unread message

Guilherme Sousa

unread,
Apr 3, 2014, 6:49:20 AM4/3/14
to rob...@googlegroups.com
Hi,

I have two simple questions to deal with some iOS issues:

- What's the Java instruction that allow me to access the external storage to, for example, store or read a file?
Usually is something like: Environment.getExternalStorage().. In RoboVM how do I access it?

- The other question is: how do I define my app URL Scheme to open it from the browser when the URL scheme matches?

I'm sorry if you already answered to those questions, but I searched and got nothing.

Best regards.

Guilherme Sousa

unread,
Apr 3, 2014, 9:56:10 AM4/3/14
to rob...@googlegroups.com
I've found out that the String that returns the file system path is System.getenv("HOME").

On the other hand, I continue not to know how to define the app URL Scheme.. Can you help me, please? Where do I define such a thing?

Niklas Therning

unread,
Apr 3, 2014, 10:44:40 AM4/3/14
to Guilherme Sousa, rob...@googlegroups.com


On Thu, Apr 3, 2014 at 3:56 PM, Guilherme Sousa <fgu...@gmail.com> wrote:
I've found out that the String that returns the file system path is System.getenv("HOME").

On the other hand, I continue not to know how to define the app URL Scheme.. Can you help me, please? Where do I define such a thing?

--
You received this message because you are subscribed to the Google Groups "RoboVM" group.
To unsubscribe from this group and stop receiving emails from it, send an email to robovm+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Guilherme Sousa

unread,
Apr 3, 2014, 12:52:26 PM4/3/14
to rob...@googlegroups.com

Guilherme Sousa

unread,
Apr 3, 2014, 12:55:53 PM4/3/14
to rob...@googlegroups.com
Thank you, I already defined the Info.plist.xml but now I want to get the parameters that came in the URL that launched the app. I know it is with NSDictionary, but what is the right method? For instance, abc://def.com?link="aaa", how do I get the link value with NSDictionary?

Thank you once again.

Niklas Therning

unread,
Apr 7, 2014, 4:28:35 PM4/7/14
to Guilherme Sousa, rob...@googlegroups.com
In your implementation of UIApplicationDelegate.didFinishLaunching() you can retrieve the URL using something like this:

    public boolean didFinishLaunching(UIApplication application, NSDictionary<NSString, ?> launchOptions) {
        NSURL url = (NSURL) launchOptions.get(UIApplication.LaunchOptionsURLKey);
        ...
    }



On Thu, Apr 3, 2014 at 6:55 PM, Guilherme Sousa <fgu...@gmail.com> wrote:
Thank you, I already defined the Info.plist.xml but now I want to get the parameters that came in the URL that launched the app. I know it is with NSDictionary, but what is the right method? For instance, abc://def.com?link="aaa", how do I get the link value with NSDictionary?

Thank you once again.

--
Reply all
Reply to author
Forward
0 new messages