title: Android AsyncTask error, attempting to assign weaker access privileges.
body: <p>I'm stuck with this problem, I continue to receive the following error:</p>
  
  <blockquote>
    <p>'processFinish(Boolean)' in 'Anonymous class derived from
    MainActivity.AsyncGETRequestProcess.AsyncResponse' clashes with
    'processFinish(Boolean)' in
    MainActivity.AsyncGETRequestProcess.AsyncResponse'; attempting to
    assign weaker access privileges ('packageLocal'); was public.</p>
  </blockquote>
  
  <p>What I'm trying to accomplish is, run AsyncTask from inside <code>MainActivity</code> after I receive the data from an Intent.</p>
  
  <p>Here is the onResume code where I receive the error, and where the Asynctask gets called:</p>
  
  <pre><code> @Override
      protected void onResume(){
          super.onResume();
  
          IntentFilter intentFilter = new IntentFilter("cb.MainActivity.WebServiceReceiver.ReturnedReceivedDataFilePath");
          receiver = new BroadcastReceiver() {
              @Override
              public void onReceive(Context context, Intent intent) {
                  //Get message from WebServiceReceiver Intent
                  String ReceivedDataFilePath = intent.getStringExtra("WebServiceReceiver_ReturnedReceivedDataFilePath");
  
  
                  new AsyncGETRequestProcess(new AsyncGETRequestProcess.AsyncResponse(){
                        //THE ABOVE ERROR HAPPENS HERE... processFinish
                        @Override
                        void processFinish(boolean success){
                          if(success){
                              MainActivity.getInstance().txtStatus.setText("Loading screen...");
                              Intent RouteScreenActivityIntent = new Intent(MainActivity.getInstance(), RouteScreenActivity.class);
                              MainActivity.getInstance().startActivity(RouteScreenActivityIntent);
                          }else{
                              //ERROR MSG
                          }
                          //Stop the spinner in MainActivity
                          MainActivity.getInstance().MainActSpinner.setVisibility(View.GONE);
                          MainActivity.getInstance().txtStatus.setText("");
                      }
                  }).execute(ReceivedDataFilePath).get();
  
              }
          };
  </code></pre>
  
  <p>Here is my <code>AsyncGETRequestProcess Class</code> which extends AsyncTask:</p>
  
  <pre><code> //THE FOLLOWING CLASS RESIDES WITHIN MainActivity Class...
   public static class AsyncGETRequestProcess extends AsyncTask&lt;String, Void, Void&gt; {
  
          public interface AsyncResponse {
              void processFinish(boolean success);
          }
  
          public AsyncResponse delegate = null;
  
          public AsyncGETRequestProcess(AsyncResponse delegate){
              this.delegate = delegate;
          }
  
          @Override
          protected Void doInBackground(String... strings) {
              //Read the temp file location and create model of 'GET' Data Received.
              GetRequestRoot getRequestRootModel = Core.Helper.GetRootObjFromGetRequestTempFile(strings[0]);
  
              Boolean responseResult = ServerResponse.ProcessGetRequestResultModel(getRequestRootModel);
  
              if(responseResult)
              {
                  Core.Data.ObjModel = Core.Helper.GetInputFileAsObject();
                  if(Core.Data.ObjModel == null){
                      delegate.processFinish(false);
                  }
                  else{
                      delegate.processFinish(true);
                  }
              }else{
                  delegate.processFinish(false);
              }
  
              return null;
          }
  
          @Override
          protected void onPreExecute(){
  
          }
  
          @Override
          protected void onPostExecute(Void result){
  
          }
  
      }
  </code></pre>
  
  <p>I'm also getting the following compile time error..</p>
  
  <blockquote>
    <p>Error:(108, 28) error: processFinish(boolean) in  cannot implement processFinish(boolean) in
    AsyncResponse attempting to assign weaker access privileges; was
    public</p>
  </blockquote>
  
  <p>How can I fix this? I don't understand why its happening.</p>