how to acces a database from a broadcastreciever (ReceiverRestrictedContext)?
===

I am trying to get some values from my app's sqlite database using the alarm manager.
now as we all know the DB class which extends SQLiteOpenHelper  requires a context, and the broadcastreciever gets a context like this:

    @Override 
	public void onReceive(Context context, Intent intent) {

the problem is that when i call the DB class with this context i get the following exception:

> Unable to start receiver com.ayham.mycar.AlarmBroadcastReceiver: java.lang.ClassCastException: android.app.ReceiverRestrictedContext

the full code is like this:

    public class AlarmBroadcastReceiver extends BroadcastReceiver {
	NotificationManager nm; 
	@Override 
	public void onReceive(Context context, Intent intent) {
		//get the values from the DB:
		DBhelper mDBGet=new DBhelper(context);
		Cursor mCursor=mDBGet.allProperties((Activity) context);}}

i know i'm not supposed to cast the context into an Activity but if i don't the compiler gives me an error.
how can i get this done?
