Search code examples
javaandroidcapiapplication-settings

Manage Android application settings from C rather than Java?


Could I manage Android application settings from C rather than Java?

I mean the settings that I could manage:

  • for Android, in Java - through android.content.SharedPreferences interface;
  • for iOS, in C - through utilities from CoreFoundation/CFPreferences.h;
  • for Windows, in C - through WinAPI for Registry management;
  • for Android, in C - ?

Solution

  • Yes, but it will be messy. In Android, you can use the NDK to access the sharedPreferences via JNI. See:

    Access android context in ndk application