Error Instantiating an Inner Class in Parent's Constructor...
- by stormin986
In my application's main class (subclass of Application), I have a public inner class that simply contains 3 public string objects. In the parent class I declare an object of that inner class.
public class MainApplication extends Application {
public class Data {
public String x;
public String y;
public String z;
}
private Data data;
MainApplication() {
data = new Data()
data.x = "String";
}
}
After I instantiate the object in the constructor, I get a runtime error when I try to assign any of the inner class object's variables.
Any idea what's up here??