Examples of Hessian2Output


Examples of com.caucho.hessian.io.Hessian2Output

                           BamError error)
    throws IOException
  {
    init(os);
   
    Hessian2Output out = _out;
   
    if (out == null)
      return;

    if (log.isLoggable(Level.FINEST)) {
      log.finest(this + " messageError " + value
                 + " {to:" + to + ", from:" + from + "}");
    }

    out.writeInt(HmtpPacketType.MESSAGE_ERROR.ordinal());
    writeAddress(out, to);
    writeAddress(out, from);
    out.writeObject(value);
    out.writeObject(error);
   
    out.flushBuffer();
  }
View Full Code Here

Examples of com.caucho.hessian.io.Hessian2Output

                    Serializable value)
    throws IOException
  {
    init(os);
   
    Hessian2Output out = _out;

    if (out == null)
      return;

    if (log.isLoggable(Level.FINEST)) {
      log.finest(this + " query " + value
                + " {id: " + id + ", to:" + to + ", from:" + from + "}");
    }

    out.writeInt(HmtpPacketType.QUERY.ordinal());
    writeAddress(out, to);
    writeAddress(out, from);
    out.writeLong(id);
    out.writeObject(value);

    out.flushBuffer();
  }
View Full Code Here

Examples of com.caucho.hessian.io.Hessian2Output

                          Serializable value)
    throws IOException
  {
    init(os);
   
    Hessian2Output out = _out;

    if (out == null)
      return;

    if (log.isLoggable(Level.FINEST)) {
      log.finest(this + " queryResult " + value
                + " {id: " + id + ", to:" + to + ", from:" + from + "}");
    }

    out.writeInt(HmtpPacketType.QUERY_RESULT.ordinal());
    writeAddress(out, to);
    writeAddress(out, from);
    out.writeLong(id);
    out.writeObject(value);
   
    out.flushBuffer();
  }
View Full Code Here

Examples of com.caucho.hessian.io.Hessian2Output

                         BamError error)
    throws IOException
  {
    init(os);

    Hessian2Output out = _out;

    if (out == null)
      return;

    if (log.isLoggable(Level.FINEST)) {
      log.finest(this + " queryError " + error + " " + value
                + " {id: " + id + ", to:" + to + ", from:" + from + "}");
    }

    out.writeInt(HmtpPacketType.QUERY_ERROR.ordinal());
    writeAddress(out, to);
    writeAddress(out, from);
    out.writeLong(id);
    out.writeObject(value);
    out.writeObject(error);
   
    out.flushBuffer();
  }
View Full Code Here

Examples of com.caucho.hessian.io.Hessian2Output

  }

  public void flush()
    throws IOException
  {
    Hessian2Output out = _out;

    if (out != null) {
      out.flush();
    }
  }
View Full Code Here

Examples of com.caucho.hessian.io.Hessian2Output

  {
    if (log.isLoggable(Level.FINER))
      log.finer(this + " close");

    try {
      Hessian2Output out = _out;
      _out = null;

      if (out != null) {
        out.close();
      }
    } catch (Exception e) {
      log.log(Level.WARNING, e.toString(), e);
    }
  }
View Full Code Here

Examples of com.caucho.hessian.io.Hessian2Output

                           ServletResponse res)
    throws IOException
  {
    res.setContentType("application/x-caucho-jsf-developer-aid");

    Hessian2Output out = new Hessian2Output(res.getOutputStream());

    out.writeObject(aidMap);

    out.flush();
  }
View Full Code Here

Examples of com.caucho.hessian.io.Hessian2Output

    throws IOException
  {
    if (log.isLoggable(Level.FINEST))
      os = new HessianDebugOutputStream(os, log, Level.FINEST);

    Hessian2Output hOut = new Hessian2Output(os);

    hOut.writeObject(value);

    hOut.close();
  }
View Full Code Here

Examples of com.caucho.hessian.io.Hessian2Output

    is.read();
    is.read();

    Hessian2Input in = new Hessian2Input(is);
    Hessian2Output out = new Hessian2Output(os);

    in.startCall();

    String method = in.getMethod();
    Object []args = in.readArguments();
    in.completeCall();

    try {
      if (method.equals("lookup") ||
          method.equals("lookup_string") ||
          method.equals("lookup_1"))
        executeLookup(args, in, out);
      else if (method.equals("list"))
        executeList(args, in, out);
      else
        executeUnknown(method, args, in, out);
    } catch (HessianProtocolException e) {
      throw e;
    } catch (Throwable e) {
      log.log(Level.WARNING, e.toString(), e);

      out.startReply();
      out.writeFault("ServiceException", e.getMessage(), e);
      out.completeReply();
    }
   
    out.flush();
  }
View Full Code Here

Examples of com.caucho.hessian.io.Hessian2Output

     
      SelfEncryptedCookie cookieObj
        = new SelfEncryptedCookie(cookie, createTime);

      TempOutputStream tos = new TempOutputStream();
      Hessian2Output hOut = new Hessian2Output(tos);

      hOut.writeObject(cookieObj);

      hOut.close();

      TempOutputStream cipherOut = new TempOutputStream();
      CipherOutputStream cOut
        = new CipherOutputStream(cipherOut, cipher);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.