[Php-tuxedo-development] Recent changes
Status: Pre-Alpha
Brought to you by:
cdog1977
From: Brian F. <bf...@mn...> - 2002-01-07 05:54:13
|
Well I decided to go with the overloaded argument approach. The Field ID argument in the functions tux_fdelall, tux_foccur, tux_fdel, tux_flen, tux_fpres, tux_fadd and tux_fget can be passed as either an Integer, hence taken as the Tuxedo Field ID, or as a string, taken as the Tuxedo Field Name and hence calling fldid on it. I think this will give us the best mix. I decided against just changing to only Field Name because Field Names are optional, while highly recommended, still optional. But I did agree with CMLees point that it makes for extra & ugly code to have to nest the tux_fldid call for each usage. Also, I made a small about face with tux_fml2array. Earlier I checked in changes that removed the flag argument in favor of just creating indexes by Field Number and Field Name always for each item. After looking at it more and trying it in some examples, I didn't like it because the very common array combination list/each would find both keys for the same value, making it appear like twice as many values existed in the array, even tho they really didn't. So I put the flag back in, but enhanced it a bit also. Now instead of a simple 0 or 1, its 3 bit flags, so you can have the indexes returned as either 0 or 1 = Field IDs 2 = Field Numbers 4 = Field Names or any combination of these will give multiple indexes ie: 5 = Field Names and Field IDs. All this code is checked in, and some testing has been done. I want to run some more tests before I'm done, but I think we are getting close to a new release point. Brian Foddy |