I am trying to get myself up and running with RoboGuice 2 and I have added guice-3.0-no_aop, roboguice-2.0 and jsr305-1.3.9 jars into the projects classpath but I am getting following exception when I try the code given below:
E/AndroidRuntime(1143): java.lang.RuntimeException: Unable to instantiate activity
ComponentInfo{com.wickedlynotsmart.myfirstapp/com.wickedlynotsmart.myfirstapp.acti
vity.MainActivity}: java.lang.ClassNotFoundException: Didn't find class
"com.wickedlynotsmart.myfirstapp.activity.MainActivity" on path:
/data/app/com.wickedlynotsmart.myfirstapp-2.apk
MainActivity.java
public class MainActivity extends RoboActivity {
@InjectView(R.id.helloTextView)
private TextView helloTextView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
helloTextView.setText("Hello, My First App!");
}
//...
}
MyFirstAppModule.java
public class MyFirstAppModule extends AbstractModule{
@Override
protected void configure() {
// TODO Auto-generated method stub
}
}
roboguice.xml
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string-array name="roboguice_modules">
<item>com.wickedlynotsmart.myfirstapp.module.MyFirstAppModule</item>
</string-array>
</resources>
Could someone help me understand with it?
Thanks.
EDIT: I am using Android API 17 with Android Development Tool.