title: What's the difference between TypedArray.getInteger() and TypedArray.getInt()?
body: <p>Looking at the source code for TypedArray (<a href="https://github.com/android/platform_frameworks_base/blob/master/core/java/android/content/res/TypedArray.java" rel="noreferrer">link</a>), I cannot seem to figure out what the difference between these two methods is. <code>getInt()</code> is basically the same as <code>getInteger()</code>, but with a small addition at the end that I don't understand. Can someone explain it to me?</p>
  
  <p>The reason I need to know the difference is I am implementing a custom Preference subclass, and to get the default value I need to override <code>onGetDefaultValue()</code>, which grabs an integer from a TypedArray. Example:</p>
  
  <pre><code>@Override
  protected Object onGetDefaultValue(TypedArray a, int index)
  {
      return a.getInteger(index, DEFAULT_VALUE);
  }
  </code></pre>
  
  <p>Here I'm using <code>getInteger()</code>, but if <code>getInt()</code> is better, then I will use that.</p>