Hi, On Mon, Mar 17, 2008 at 11:35:05PM +0000, place wrote:
I made a dStr_dstrcat().
What's the main advantage of it, over dStr_append_l() ? I see the convenience and clarity of passing two parameters instead of three, but on the other hand, keeping APIs reduced to a functional minimum, helps to remember and to choose the right function call. There may be a point I don't yet see... -- Cheers Jorge.-
On Mon, Mar 17, 2008 at 11:35:05PM +0000, place wrote:
I made a dStr_dstrcat().
What's the main advantage of it, over dStr_append_l() ?
I see the convenience and clarity of passing two parameters instead of three, but on the other hand, keeping APIs reduced to a functional minimum, helps to remember and to choose the right function call.
There may be a point I don't yet see...
Nope, that's all there was to it. And I don't have a strong opinion about it, so that's fine.
On Tue, Mar 18, 2008 at 02:14:06PM +0000, place wrote:
On Mon, Mar 17, 2008 at 11:35:05PM +0000, place wrote:
I made a dStr_dstrcat().
What's the main advantage of it, over dStr_append_l() ?
I see the convenience and clarity of passing two parameters instead of three, but on the other hand, keeping APIs reduced to a functional minimum, helps to remember and to choose the right function call.
There may be a point I don't yet see...
Nope, that's all there was to it. And I don't have a strong opinion about it, so that's fine.
Does anybody else have some experience/theory/article/knowledge on API design that can enlighten us? ;) -- Cheers Jorge.-
On Tue, Mar 18, 2008 at 07:48:00PM +0000, place wrote:
Jorge wrote:
Does anybody else have some experience/theory/article/knowledge on API design that can enlighten us?
;)
I just meant "okay, never mind".
Understood. My point is there're other places in dillo where a more formal API definition is needed, and I'd like to know whether there's some theory or guiding experience that could help. -- Cheers Jorge.-
On Tue, Mar 18, 2008 at 07:48:00PM +0000, place wrote:
Jorge wrote:
Does anybody else have some experience/theory/article/knowledge on API design that can enlighten us?
;)
I just meant "okay, never mind".
After some investigation I chose to honor "minimal" in this case and committed the equivalent using Dstr_append_l(). With regard to entry_status()/is_cached(), I'm trying to find a good trade off between "minimal set" and "obvious meaning from first code read". ;-) BTW, I found good summary advice on API design here: http://blog.isnotworking.com/2007/05/api-design-guidelines.html -- Cheers Jorge.-
participants (2)
-
jcid@dillo.org
-
place@gobigwest.com