*
* If an <array> tag is encountered, a null is pushed onto the
* stack. When a </data> is encountered, we search back on the
- * stack to the last null, replace it with a NativeArray, and
+ * stack to the last null, replace it with a NativeJS.Array, and
* insert into it all elements above it on the stack.
*
* If a <struct> tag is encountered, a JSObject is pushed
} else if (c.localName.equals("data")) {
int i;
for(i=objects.size() - 1; objects.elementAt(i) != null; i--);
- Array arr = new Array();
+ JS.Array arr = new JS.Array();
for(int j = i + 1; j<objects.size(); j++) arr.put(new Integer(j - i - 1), objects.elementAt(j));
objects.setElementAt(arr, i);
objects.setSize(i + 1);
sb.append("</dateTime.iso8601></value>\n");
*/
- } else if (o instanceof Array) {
+ } else if (o instanceof JS.Array) {
if (tracker.get(o) != null) throw new JS.Exn("attempted to send multi-ref data structure via XML-RPC");
tracker.put(o, Boolean.TRUE);
sb.append(" <value><array><data>\n");
- Array a = (Array)o;
+ JS.Array a = (JS.Array)o;
for(int i=0; i<a.length(); i++) appendObject(a.elementAt(i), sb);
sb.append(" </data></array></value>\n");
// this is synchronized in case multiple threads try to make a call on the same object... in the future, change this
// behavior to use pipelining.
- public synchronized Object call2(Array args) throws JS.Exn, IOException {
+ public synchronized Object call2(JS.Array args) throws JS.Exn, IOException {
if (Log.verbose) Log.log(this, "call to " + url + " : " + methodname);
if (tracker == null) tracker = new Hash();
}
}
- protected String send(Array args, HTTP http) throws JS.Exn, IOException {
+ protected String send(JS.Array args, HTTP http) throws JS.Exn, IOException {
StringBuffer content = new StringBuffer();
content.append("\r\n");
content.append("<?xml version=\"1.0\"?>\n");
return objects.elementAt(0);
}
- public final Object call(Array args) throws JS.Exn {
+ public final Object call(JS.Array args) throws JS.Exn {
if (!ThreadMessage.suspendThread()) return null;