Re: [xwt-users] Passing arrays in xmlrpc calls
Brian Alliet <[email protected]>
| Newsgroups | gmane.comp.java.xwt.users |
|---|---|
| Message-ID | <[email protected]> |
On Monday, August 4, 2003, at 12:12 PM, Charles Goodwin wrote: > Thanks Stuart, knowing this works I can answer this question: > http://devedge.netscape.com/library/manuals/2000/javascript/1.5/ > reference/array.html#1193889 > > "function( array.toSource() )" should do it. No. This is certainly not what he wants. (from that page) "For instances of Array, toSource returns a string representing the source code". This will return a string containing "[ 1.0, 2.0, 3.0, 4.0]". XWT would send this as a string and the server probably wouldn't know what to do with it. Also, the toSource() function isn't part of ecma-262 and therefor isn't in Nitrogen. I wouldn't recommend using it. If there is sufficient demand for it it could be added, but I really don't see where it would be needed. > Basically, you need to pass the array _literal_ which is provided by > the > toSource() function. If you pass an array _reference_ then > sub-programitically-logically (ie in the mind of an assembly > programmer) > the function does not receive the array but rather the reference, > which is > useless remotely. No. Just passing an array reference should do it. XWT knows to send the actual data contained in the array. -Brian