public void endTask() {if (!isMainThread())throw new IllegalStateException();pm.endTask();}

public void endTask ( ) { if ( ! isMainThread ( ) ) throw new IllegalStateException ( ) ; pm . endTask ( ) ; }
public override void EndTask(){if (!IsMainThread()){throw new InvalidOperationException();}pm.EndTask();}
