Android - use ant to create build configurations that change configuration values

前端 未结 4 1450
春和景丽
春和景丽 2020-12-05 01:19

What I want is a way to have settings that are dependent on build configuration. To give a specific example, my android application connects to a web service. In developme

4条回答
  •  长情又很酷
    2020-12-05 01:52

    I would start by placing the urls into a properties file that you can then place onto the classpath. Make a test and a production properties file. Then depending on the build place the correct file onto the classpath and pull the properties at runtime.

提交回复
热议问题