VCS Interfaces, round 3
Andreas Pakulat
apaku at gmx.de
Sat May 5 09:16:39 UTC 2007
On 04.05.07 18:46:53, Matthew Woehlke wrote:
> Andreas Pakulat wrote:
> > As I said to have a nice flow and a common point to cleanup point in
> > user-code we should emit 3 signals when the job is done, that is:
> >
> > a) finished(VcsJob*) - the job has finished sucessfully and all results
> > are available (resultsReady signals haven been emitted accordingly).
> > b) error(VcsJob*) - an error occured
> > c) cancelled(VcsJob*) - the job was cancelled and is done with any
> > cleanup it had to do due to the cancelling
>
> Say, since finished() no longer has a data payload, what about having
> *only* finished() with a status code (success, fail, canceled)? That way
> clean-up can be done in one slot rather than needing to connect to three.
I wasn't completely sure which is nicer API-wise, 3 different signals is
a bit more work to use but communicates really really clearly what has
happened. OTOH an status in the signal is also pretty clear. So I agree.
Andreas
--
Change your thoughts and you change your world.
More information about the KDevelop-devel
mailing list