Add listener in AsyncTask when called postExecute
<p>I have a AsyncTask class.</p>

<p>here is code.</p>

<pre><code>private class WaitSec extends AsyncTask&lt;Void, Void, Boolean&gt;{
    @Override
    protected Boolean doInBackground(Void... params) {
        try {
            Thread.sleep(2000);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }

        if(CheckSomeUtil.isItOk()) {
            return true;
        } else {
            return false;
        }
    }
    @Override
    protected void onPostExecute(Boolean aBoolean) {
        if(aBoolean)
            // in this line. is i want to set listener.
        super.onPostExecute(aBoolean);
    }
}
</code></pre>

<p>When called onPostExecute method, i'd like to get boolean value in activity.</p>

<p>Thanks.</p>