My real concern was the name of the tag

<@define local$name type=array cols=5 rows=1>
local$name is an array

something like <@hasdata> or <@thisdarnarrayexistsandhasdata> ;)

Ben



On Mar 31, 2008, at 4:08 PM, William M Conlon wrote:

Well, maybe I shouldn't be trying to enforce types in method calls, but I do. I have a tag <@ISINT> which takes a string and returns a boolean based on whether the string represents an integer.

Maybe I should have written the tag to accept an array in addition to a string, and process accordingly, but I didn't. It's easy enough to loop through the array and pass each element as a string for testing.

But the problem occurs when I have a null array (zero rows by 1 column). I typically was testing for an array be counting rows, but the null array throws an exception with a bad reference. Hence, I need to test both rows and columns. No big deal, but it is self- documenting to have an <@ISARRAY> meta tag than an expression.

Bill

William M. Conlon, P.E., Ph.D.
To the Point
2330 Bryant Street
Palo Alto, CA 94301
  vox:  650.327.2175 (direct)
  fax:  650.329.8335
mobile:  650.906.9929
e-mail:  mailto:[EMAIL PROTECTED]
  web:  http://www.tothept.com


On Mar 31, 2008, at 3:49 PM, Ben Johansen wrote:
All Witango vars are arrays
when you do <@var local$name> it is the same as <@var local $name[1,1]>

And isarray doesnt imply having data just would mean that it is an array.

and since you need the name of the array, and you get that with @numrows

Just makes me wonder if this is really needed

just my view point

Ben

On Mar 31, 2008, at 3:39 PM, William M Conlon wrote:

I would like to have a metatag <@ISARRAY SCOPE=scope NAME=name>.

Current workaround: ("<@NUMROWS ARRAY=name> >0" AND "<@NUMCOLS ARRAY=name> > 0")

Bill

William M. Conlon, P.E., Ph.D.
To the Point
2330 Bryant Street
Palo Alto, CA 94301
 vox:  650.327.2175 (direct)
 fax:  650.329.8335
mobile:  650.906.9929
e-mail:  mailto:[EMAIL PROTECTED]
 web:  http://www.tothept.com

________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

Reply via email to