package com.backfire.utils;

import android.os.AsyncTask;

/**
 * @author wf
 *
 */
public final class MyAsyncTask extends AsyncTask<Void, Void, Void> {

	private MyTaskWrap thread;

	public MyAsyncTask(MyTaskWrap thread)
	{
		this.thread = thread;
	}

	@Override
	protected Void doInBackground(Void... params) {
		if (this.thread != null) {
			this.thread.onTaskStart();
		}
		return null;
	}
	
	
	@Override
	protected void onPostExecute( Void val )
	{
		if (this.thread != null) {
			this.thread.onTaskFinish();
		}
	}
}
