else if (c.localName.equals("double"))
objects.setElementAt(new Double(new String(content.getBuf(), 0, content.size())), objects.size() - 1);
- // FIXME
- /*
else if (c.localName.equals("base64"))
- objects.setElementAt(new ByteStream(Base64.decode(new String(content.getBuf(), 0, content.size()))), objects.size() - 1);
- */
+ objects.setElementAt(new Res.ByteArray(Base64.decode(new String(content.getBuf(), 0, content.size()))), objects.size() - 1);
else if (c.localName.equals("name"))
objects.addElement(new String(content.getBuf(), 0, content.size()));
sb.append(((Boolean)o).booleanValue() ? "1" : "0");
sb.append("</boolean></value>\n");
- //FIXME
- /*
- } else if (o instanceof ByteStream) {
+ } else if (o instanceof Res) {
try {
sb.append(" <value><base64>\n");
- InputStream is = ((ByteStream)o).getInputStream();
+ InputStream is = ((Res)o).getInputStream();
byte[] buf = new byte[54];
while(true) {
int numread = is.read(buf, 0, 54);
if (Log.on) Log.log(this, e);
throw new JS.Exn("caught IOException while attempting to send a ByteStream via XML-RPC");
}
- */
} else if (o instanceof String) {
sb.append(" <value><string>");
public Filter(InputStream is) { super(is); }
public int read() throws IOException {
java.lang.Thread.yield();
- while(MessageQueue.nonThreadEventsInQueue > 0) try { java.lang.Thread.sleep(100); } catch (Exception e) { };
+ while(Message.Q.nonThreadEventsInQueue > 0) try { java.lang.Thread.sleep(100); } catch (Exception e) { };
return super.read();
}
public int read(byte[] b) throws IOException {
java.lang.Thread.yield();
- while(MessageQueue.nonThreadEventsInQueue > 0) try { java.lang.Thread.sleep(100); } catch (Exception e) { };
+ while(Message.Q.nonThreadEventsInQueue > 0) try { java.lang.Thread.sleep(100); } catch (Exception e) { };
return super.read(b);
}
public int read(byte[] b, int i, int j) throws IOException {
java.lang.Thread.yield();
- while(MessageQueue.nonThreadEventsInQueue > 0) try { java.lang.Thread.sleep(100); } catch (Exception e) { };
+ while(Message.Q.nonThreadEventsInQueue > 0) try { java.lang.Thread.sleep(100); } catch (Exception e) { };
return super.read(b, i, j);
}
}