So I’ve noticed that there seem to be two ways to get the same data, and I’m not sure if there are guidelines to when you should use either (other than, bypassing the getResources could be memory saving if you don’t actually want to use the object more than once). But other than that I would like to know if there are guidelines or reasons to use
Context.getText(id) vs Context.getResources.getText(id)
Can anyone help?
There is no difference. The source for getText(id) is:
You can see for yourself at Context.java on netmite which has a version of the Android source.