0

I'm looking at being able to set some configuration variables for my android Library from the app.

The library I work with is basically serving data from a REST Api. I have a staging and production server and I would like to give the guys who are going to use the lib the ability to switch environment easily.

On iOS i have used the info.plist of the iOS app that hosts the library. I have put a ApiEnvironement variable inside and the plist in which you can specify your working environment, and then any framework linked can use this variable.

Any idea on how I could achieve this kind of behavior for Android ?

Thank you.

bottus
  • 883
  • 2
  • 13
  • 32
  • Have you have a look at build flavors? – Naveen Dissanayake Mar 07 '17 at 09:16
  • Yes I have, but it doesn't look like the developer who is going to to integrate the SDK will be able to change that build flavor from his app. The idea is that he wouldn't need to rebuild the SDK to change the endpoint. – bottus Mar 07 '17 at 09:38

0 Answers0