title: "No enclosing instance of type" error while calling method from another class in Android
body: <p>Colleagues, I have the such question:
  1. In my first class I have the </p>
  
  <pre><code>public class parseYouTubeAndYahoo extends AsyncTask&lt;String, Void, List&lt;VideoDataDescription&gt;&gt;
  </code></pre>
  
  <p>to parse data from internet. But I need to call execute() method of this class from another class. While trying to right such code:</p>
  
  <pre><code>new MainActivity.parseYouTubeAndYahoo().execute("someURL"); 
  </code></pre>
  
  <p>I have the next error message from Eclipse </p>
  
  <p><i>No enclosing instance of type MainActivity is accessible. Must qualify the allocation   with an enclosing instance of type MainActivity (e.g. x.new A() where x is an instance of MainActivity). </i></p>
  
  <p>and really this problem is shrouded in fog for me. So, how to call this method from another class?</p>