/** * Reads a fault. */ private HashMap readFault() throws IOException { HashMap map = new HashMap(); int code = read(); for (; code > 0 && code != 'z'; code = read()) { _peek = code; Object key = readObject(); Object value = readObject(); if (key != null && value != null) map.put(key, value); } if (code != 'z') throw expect("fault", code); return map; }
/** * Starts reading the call, including the headers. * <p> * <p>The call expects the following protocol data * <p> * <pre> * c major minor * m b16 b8 method * </pre> */ @Override public void startCall() throws IOException { readCall(); while (readHeader() != null) { readObject(); } readMethod(); }
/** * Reads a reply as an object. * If the reply has a fault, throws the exception. */ @Override public Object readReply(Class expectedClass) throws Throwable { int tag = read(); if (tag != 'r') error("expected hessian reply at " + codeName(tag)); int major = read(); int minor = read(); tag = read(); if (tag == 'f') throw prepareFault(); else { _peek = tag; Object value = readObject(expectedClass); completeValueReply(); return value; } }
throws IOException { if (cl == null || cl == Object.class) return readObject();
/** * Reads an object from the input stream with an expected type. */ @Override public Object readObject(Class cl) throws IOException { return readObject(cl, null, null); }
/** * Reads an arbitrary object from the input stream when the type * is unknown. */ @Override public Object readObject() throws IOException { return readObject((List<Class<?>>) null); }
/** * Reads a fault. */ private HashMap readFault() throws IOException { HashMap map = new HashMap(); int code = read(); for (; code > 0 && code != 'z'; code = read()) { _peek = code; Object key = readObject(); Object value = readObject(); if (key != null && value != null) map.put(key, value); } if (code != 'z') throw expect("fault", code); return map; }
/** * Reads a fault. */ private HashMap readFault() throws IOException { HashMap map = new HashMap(); int code = read(); for (; code > 0 && code != 'z'; code = read()) { _peek = code; Object key = readObject(); Object value = readObject(); if (key != null && value != null) map.put(key, value); } if (code != 'z') throw expect("fault", code); return map; }
/** * Reads a fault. */ private HashMap readFault() throws IOException { HashMap map = new HashMap(); int code = read(); for (; code > 0 && code != 'z'; code = read()) { _peek = code; Object key = readObject(); Object value = readObject(); if (key != null && value != null) map.put(key, value); } if (code != 'z') throw expect("fault", code); return map; }
/** * Reads a fault. */ private HashMap readFault() throws IOException { HashMap map = new HashMap(); int code = read(); for (; code > 0 && code != 'z'; code = read()) { _peek = code; Object key = readObject(); Object value = readObject(); if (key != null && value != null) map.put(key, value); } if (code != 'z') throw expect("fault", code); return map; }
/** * Reads a fault. */ private HashMap readFault() throws IOException { HashMap map = new HashMap(); int code = read(); for (; code > 0 && code != 'z'; code = read()) { _peek = code; Object key = readObject(); Object value = readObject(); if (key != null && value != null) map.put(key, value); } if (code != 'z') throw expect("fault", code); return map; }
/** * Starts reading the call, including the headers. * <p> * <p>The call expects the following protocol data * <p> * <pre> * c major minor * m b16 b8 method * </pre> */ @Override public void startCall() throws IOException { readCall(); while (readHeader() != null) { readObject(); } readMethod(); }
/** * Starts reading the call, including the headers. * <p> * <p>The call expects the following protocol data * <p> * <pre> * c major minor * m b16 b8 method * </pre> */ @Override public void startCall() throws IOException { readCall(); while (readHeader() != null) { readObject(); } readMethod(); }
/** * Starts reading the call, including the headers. * * <p>The call expects the following protocol data * * <pre> * c major minor * m b16 b8 method * </pre> */ public void startCall() throws IOException { readCall(); while (readHeader() != null) { readObject(); } readMethod(); }
/** * Starts reading the call, including the headers. * * <p>The call expects the following protocol data * * <pre> * c major minor * m b16 b8 method * </pre> */ public void startCall() throws IOException { readCall(); while (readHeader() != null) { readObject(); } readMethod(); }
/** * Starts reading the call, including the headers. * * <p>The call expects the following protocol data * * <pre> * c major minor * m b16 b8 method * </pre> */ public void startCall() throws IOException { readCall(); while (readHeader() != null) { readObject(); } readMethod(); }
/** * Reads a reply as an object. * If the reply has a fault, throws the exception. */ @Override public Object readReply(Class expectedClass) throws Throwable { int tag = read(); if (tag != 'r') error("expected hessian reply at " + codeName(tag)); int major = read(); int minor = read(); tag = read(); if (tag == 'f') throw prepareFault(); else { _peek = tag; Object value = readObject(expectedClass); completeValueReply(); return value; } }
/** * Reads a reply as an object. * If the reply has a fault, throws the exception. */ public Object readReply(Class expectedClass) throws Throwable { int tag = read(); if (tag != 'r') error("expected hessian reply at " + codeName(tag)); int major = read(); int minor = read(); tag = read(); if (tag == 'f') throw prepareFault(); else { _peek = tag; Object value = readObject(expectedClass); completeValueReply(); return value; } }
/** * Reads a reply as an object. * If the reply has a fault, throws the exception. */ @Override public Object readReply(Class expectedClass) throws Throwable { int tag = read(); if (tag != 'r') error("expected hessian reply at " + codeName(tag)); int major = read(); int minor = read(); tag = read(); if (tag == 'f') throw prepareFault(); else { _peek = tag; Object value = readObject(expectedClass); completeValueReply(); return value; } }
/** * Reads a reply as an object. * If the reply has a fault, throws the exception. */ public Object readReply(Class expectedClass) throws Throwable { int tag = read(); if (tag != 'r') error("expected hessian reply at " + codeName(tag)); int major = read(); int minor = read(); tag = read(); if (tag == 'f') throw prepareFault(); else { _peek = tag; Object value = readObject(expectedClass); completeValueReply(); return value; } }