class cast exception in Android Application
<p>I am getting class cast exception in the below line of code. I have attached the stack trace below and the line below is 339 as mentioned in stack trace.</p>

<p><code>com.unique.may.utility.GlobalStateData gs = (com.unique.may.utility.GlobalStateData) 
getApplication();</code></p>

<p>In global state data the code is </p>

<pre><code>public class GlobalStateData extends Application {

private String findUsBranchEMailId;

public void setFindUsBranchEMailId(String findUsBranchEMailId) {
    this.findUsBranchEMailId = findUsBranchEMailId;
}

public String getFindUsBranchEMailId() {
    return findUsBranchEMailId;
}


}
</code></pre>

<p>Stack Trace </p>

<pre><code>java.lang.ClassCastException: android.app.Application
at com.style.IntlLayout.Find.onChildClick(Find.java:339)
at android.widget.ExpandableListView.handleItemClick(ExpandableListView.java:588)
at android.widget.ExpandableListView.performItemClick(ExpandableListView.java:527)
</code></pre>

<p>below is my manifest file</p>

<pre><code>&lt;manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.styling.Layout"
android:versionCode="1"
android:versionName="1.0" &gt;
&lt;uses-sdk android:minSdkVersion="8" /&gt;
 &lt;uses-permission android:name="android.permission.INTERNET" /&gt;
 &lt;uses-permission android:name="android.permission.CALL_PHONE" /&gt;
 &lt;uses-permission android:name="android.permission.CAMERA" /&gt;
 &lt;uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" /&gt;

 &lt;uses-permission android:name="android.permission.MOUNT_UNMOUNT_FILESYSTEMS"/&gt;
 &lt;uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /&gt;
 &lt;uses-permission android:name="android.permission.SET_DEBUG_APP"&gt;&lt;/uses-permission&gt;
 &lt;support-screens
  android:largeScreens="true"
  android:normalScreens="true"
  android:smallScreens="true"
  android:anyDensity="true"/&gt;

 &lt;uses-library android:name="com.google.android.maps" /&gt;
 &lt;application android:icon="@drawable/launcher"
    android:label="@string/app_name" 
    android:debuggable="true"&gt;

 &lt;activity android:name=".Catalog" android:configChanges="orientation|keyboardHidden"&gt;    &lt;/activity&gt;

     &lt;activity android:name=".Feedback"    android:configChanges="orientation|keyboardHidden"&gt;&lt;/activity&gt;

     &lt;activity
        android:label="@string/app_name"
        android:name=".MainActivity"
        android:configChanges="orientation|keyboardHidden"  &gt;
        &lt;intent-filter &gt;
            &lt;action android:name="android.intent.action.MAIN" /&gt;

            &lt;category android:name="android.intent.category.LAUNCHER" /&gt;
        &lt;/intent-filter&gt;
       &lt;/activity&gt;
   &lt;/application&gt;


 &lt;/manifest&gt;
</code></pre>

<p>Looking forward to your reply.
thanks.</p>
