Made AsyncTask::onCompletion() implementation optional

This commit is contained in:
Shoghi Cervantes 2014-08-10 18:15:06 +02:00
parent 76cd164aa4
commit fee7f5060b

View File

@ -32,6 +32,7 @@ abstract class AsyncTask extends \Threaded{
protected $complete = null;
protected $finished = null;
protected $result = null;
protected $taskId = null;
public function run(){
$this->finished = false;
@ -100,11 +101,14 @@ abstract class AsyncTask extends \Threaded{
/**
* Actions to execute when completed (on main thread)
* Implement this if you want to handle the data in your AsyncTask after it has been processed
*
* @param Server $server
*
* @return void
*/
public abstract function onCompletion(Server $server);
public function onCompletion(Server $server){
}
}