Examples of ClResultCode


Examples of net.citrusleaf.CitrusleafClient.ClResultCode

        mylist.add(new ClBin("lastName", "Milne"));
        mylist.add(new ClBin("eyeColour", "swamp"));
        mylist.add(new ClBin("height", 177));
        mylist.add(new ClBin("weight", 75));
        String key = mylist.get(0).value.toString() + mylist.get(1).value.toString();
        ClResultCode rc = cc.set("test","people",key, mylist, null, null);
        long stop = System.currentTimeMillis();
        if (rc == ClResultCode.OK)
          System.out.println("Completed write a person in "+ (stop-start) + " milliseconds");
        else
          System.out.println("Failure write a person with " + rc + "  in "+ (stop-start) + " milliseconds");
View Full Code Here

Examples of net.citrusleaf.CitrusleafClient.ClResultCode

                  if (set_name.equalsIgnoreCase("Holding")){
                      set_name = customerName + "Holding";
                  }
                  System.out.println("Set: " + set_name + " key: " + key + " bins: " + bins);
                  if (this.clClient != null) {
                    ClResultCode rc = this.clClient.set(DBClient.NAME_SPACE, set_name, key, bins, null, null);
                    long stop = System.currentTimeMillis();
                    if (rc == ClResultCode.OK)
                        System.out.println("Completed write");
                    else
                        System.out.println("Failed write " + rc );
View Full Code Here

Examples of net.citrusleaf.CitrusleafClient.ClResultCode

  @Override
  public int nextOrderID() {
    //Map<String, Object> bins = new HashMap<String, Object>();
    //bins.put("nextID", 1);
    //ClResult result = DBClient.getInstance().addAndGet(DBClient.NAME_SPACE, "IDtable", "Order", bins, null, null);
    ClResultCode resultCode = DBClient.getInstance().add(DBClient.NAME_SPACE, "IDtable", "Order", "nextID", 1, null, null);
    if (resultCode != ClResultCode.OK)
      return -2;
    ClResult result = DBClient.getInstance().get(DBClient.NAME_SPACE, "IDtable", "Order", "nextID", null);
    if (result.resultCode == ClResultCode.OK) {
      int nextID = (Integer) result.result;
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.