title: InstantiationException: can't instantiate class .. no empty constructor
body: <p>In the following code it shows an error at <code>run()</code>, so if I put the <code>@override</code> above the <code>run()</code> then app shows error at <code>draw()</code>. Someone help in the basic steps. Here is the code:</p>
  
  <pre class="lang-java prettyprint-override"><code>    private class MyWallpaperEngine extends Engine {
              private final Handler handler = new Handler();
              private final Runnable drawRunner = new Runnable() {
                  public void run() {
                      draw();
                  }
              };
      }
  
  12-14 00:55:24.111: W/dalvikvm(7141): threadid=1: thread exiting with uncaught exception (group=0x409961f8)
  12-14 00:55:24.181: E/AndroidRuntime(7141): FATAL EXCEPTION: main
  12-14 00:55:24.181: E/AndroidRuntime(7141): java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.sri.alinwallpaper/com.sri.alinwallpaper.MyPoint}: java.lang.InstantiationException: can't instantiate class com.sri.alinwallpaper.MyPoint; no empty constructor
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1879)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1980)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at android.app.ActivityThread.access$600(ActivityThread.java:122)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1146)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at android.os.Handler.dispatchMessage(Handler.java:99)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at android.os.Looper.loop(Looper.java:137)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at android.app.ActivityThread.main(ActivityThread.java:4340)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at java.lang.reflect.Method.invokeNative(Native Method)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at java.lang.reflect.Method.invoke(Method.java:511)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at dalvik.system.NativeStart.main(Native Method)
  12-14 00:55:24.181: E/AndroidRuntime(7141): Caused by: java.lang.InstantiationException: can't instantiate class com.sri.alinwallpaper.MyPoint; no empty constructor
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at java.lang.Class.newInstanceImpl(Native Method)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at java.lang.Class.newInstance(Class.java:1319)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at android.app.Instrumentation.newActivity(Instrumentation.java:1023)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1870)
  12-14 00:55:24.181: E/AndroidRuntime(7141):     ... 11 more
  12-14 00:55:37.751: I/Process(7141): Sending signal. PID: 7141 SIG: 9
  </code></pre>