You can't do that. If you need the Context
, you can pass it with constructor:
public class DBAdapter{
private Context mContext;
public DBAdapter(Context mContext) {
this.mContext = mContext;
}
}
But anyway you won't have a chance to use it at the gradeTypes
initialization. Why do you need to declare it as final
? If you want to use this array at inner classes, you can do it without final
modifier.