views:

390

answers:

2

On normal JVMs you can use META-INF/MANIFEST.MF to declare application properties, in J2ME you can use the .jad-Files but what can you do on Android?

I need a way to declare properties which I can access using System.getProperties() on Android. It would be best if I could use the same file format as MANIFEST.MF-like property files use.

+3  A: 

It looks like Resources would do what you need.

jsight
+1  A: 

I usually put them in (for example) "res/values/props.xml" Your build scripts can get at them, and then you just need to call: activityName.getString(R.props.propertyName); to pull out the value as a string.

haseman