This is the mail archive of the kawa@sourceware.org mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Error with super class android.database.sqlite.SQLiteOpenHelper does not have a default constructor




On 11/15/2014 04:52 PM, john janecek wrote:
The class android.database.sqlite.SQLiteOpenHelper does not have a
default constructor. When I attempt to compile this example it fails.

The call to the superclass constructor has to be the very first thing
in the constructor, just as in Java.  (This is a JVM requirement.)

So try this:

define-simple-class MyDbHelper (SQLiteOpenHelper)
  (posts init: '())
  ((*init* (context ::Context))
   (invoke-special SQLiteOpenHelper
                     (this) '*init*
                     context
                     "prayers.db"
                     #!null
                     1)
     )
  )

--
	--Per Bothner
per@bothner.com   http://per.bothner.com/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]