Package org.coweb.oe

Examples of org.coweb.oe.Operation


      String type, int position) {

    /* Construct op, send it, then process it in the op engine. */
    String jsonValue = JSON.toString(value);
    ContextVector cv = null;
    Operation op = null;
    if (null != type) {
      try {
        op = this.engine.createOp(true, topic, jsonValue, type,
            position, -1, null, -1);
        cv = op.getContextVector();
      } catch (OperationEngineException e) {
        log.warning("Bad type: " + type + ", using null type instead.");
        type = null;
      }
    }
View Full Code Here


    int order = 0;
    if (ord != null)
      order = ord.intValue();

    //push the operation onto the op engine.
    Operation op = null;
    if (sites != null && type != null) {
      try {
        op = this.engine.push(false, topic, value, type, position,
            site, sites, order);
      } catch (OperationEngineException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
        return null;
      }

      if (op == null)
        return null;

      value = op.getValue();
      position = op.getPosition();
    } else if (site == this.engine.getSiteId()) {
      // op was echo'ed from server for op engine, but type null means
      // op engine doesn't care about this message anyway so drop it
      return null;
    }
View Full Code Here

TOP

Related Classes of org.coweb.oe.Operation

Copyright © 2018 www.massapicom. 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.