Eric Day wrote:
> Hi Stewart,
> 
> I was thinking it may be useful to keep the variable length parameter
> array under better control of the client so it could better manage
> it's memory (not require realloc()s (even if we do these reallocs in
> blocks to avoid excessive calls).
> 
> If folks prefer a function interface over a struct/array interface,
> then we can go that direction. :)

I think you'll need both.

I personally would avoid the vargs approach for most things - unless I
was perhaps writing an ORM.

> -Eric
> 
> On Tue, Oct 20, 2009 at 02:34:01PM +1100, Stewart Smith wrote:
>> On Mon, Oct 19, 2009 at 06:14:29PM -0700, Eric Day wrote:
>>> Which would folks prefer:
>>>
>>> 1: String only interface
>>>
>>> drizzle_value_st values[2];
>>> values[0].id= "name";
>>> values[0].data= "Eric";
>>> values[0].size= 4;
>>> values[1].id= "age";
>>> values[1].data= "28";
>>> values[1].size= 2;
>> What about
>>
>> drizzle_add_string_parameter(query, "name", "Eric", strlen("Eric"));
>> drizzle_add_int_parameter(query, "age", 28);
>>
>> ?
>>
>>
>> -- 
>> Stewart Smith
> 
> _______________________________________________
> Mailing list: https://launchpad.net/~drizzle-discuss
> Post to     : [email protected]
> Unsubscribe : https://launchpad.net/~drizzle-discuss
> More help   : https://help.launchpad.net/ListHelp
> 


_______________________________________________
Mailing list: https://launchpad.net/~drizzle-discuss
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~drizzle-discuss
More help   : https://help.launchpad.net/ListHelp

Reply via email to