Ivan Zhakov wrote:
>On 7/25/05, SteveKing <steveking@gmx.ch> wrote:
>
>
>>Ok, I guess this will be my last try:
>>
>>Also, I've added a function to enable/disable the UI part after the dll
>>was loaded. That way, the svn client could enable the UI part later on
>>when the command line params are read (I don't know enough to add such a
>>param myself, I have to leave that to someone else).
>>
>>
>Sorry, I am not subversion developer, but I have one small question:
>why you add two functions to enable/disable the UI instead add one
>function with parameter? SetUIState(BOOL enable) for example.
>
>
I can't answer for Stefan, but peronally I prefer his approach over the
parametrized one. If you have functions called EnableFoo and DisableFoo,
and see those used in the code, you immediately understand what it's
doing. On the other hand, when you encounter DoFoo(bool), you have to
look for the documentation of DoFoo in order to be certain what the
parameter means.
Another issue is sheer API aesthetics: a function that does two (or
more) completely different things is ugly. (And yes, MS screwed this up
several times in the Windows API.)
-- Brane
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Jul 27 14:37:44 2005