title: iOS AppDelegate equivalent in Android
body: <p>I have a simple Android app with one Activity. This Activity downloads a small XML file and displays the contents to the user. Currently I kick-off the download in the Activity's <code>onStart</code> method.</p>
  
  <p>It's my understanding that Activities are destroyed and re-created when the device orientation changes. So when users rotate my app the XML file is downloaded again. I'd like the app to download the file just once as it doesn't change more than a few times per day. Hence I'd like some object to retain the downloaded data so the local data can be re-used when the device orientation changes. <strong>What's the ideal object in Android to retain the data?</strong></p>
  
  <p>On iOS I'd use the <code>AppDelegate</code> to download the data once and retain it. Then the viewController that displays the data can just re-use the local data should it be destroyed and re-created.</p>