Package org.jboss.bpm.console.client.util

Examples of org.jboss.bpm.console.client.util.JSONWalk$JSONWrapper


    if (root instanceof JSONArray) {
        JSONArray array = (JSONArray) root;
       
        for (int i = 0; i < array.size(); i++) {
            JSONWalk walk = JSONWalk.on(array.get(i));
            JSONWrapper wrapper = walk.next("activeNode");
            JSONObject activeNode = wrapper.asObject();
       
            int x = JSONWalk.on(activeNode).next("x").asInt();
            int y = JSONWalk.on(activeNode).next("y").asInt();
       
            int width = JSONWalk.on(activeNode).next("width").asInt();
            int height = JSONWalk.on(activeNode).next("height").asInt();
            String name = JSONWalk.on(activeNode).next("name").asString();
                       
            activeNodeInfos.add(
                new ActiveNodeInfo(
                    -1, -1,
                    new DiagramNodeInfo(name, x, y, width, height)
                )
            );
            wrapper = walk.next("activeNode");
        }
      }
    return activeNodeInfos;
  }
View Full Code Here


    if (root instanceof JSONArray) {
        JSONArray array = (JSONArray) root;
       
        for (int i = 0; i < array.size(); i++) {
            JSONWalk walk = JSONWalk.on(array.get(i));
            JSONWrapper wrapper = walk.next("activeNode");
            JSONObject activeNode = wrapper.asObject();
       
            int x = JSONWalk.on(activeNode).next("x").asInt();
            int y = JSONWalk.on(activeNode).next("y").asInt();
       
            int width = JSONWalk.on(activeNode).next("width").asInt();
            int height = JSONWalk.on(activeNode).next("height").asInt();
            String name = JSONWalk.on(activeNode).next("name").asString();
                       
            activeNodeInfos.add(
                new ActiveNodeInfo(
                    -1, -1,
                    new DiagramNodeInfo(name, x, y, width, height)
                )
            );
            wrapper = walk.next("activeNode");
        }
      }
    return activeNodeInfos;
  }
View Full Code Here

    if (root instanceof JSONArray) {
      JSONArray array = (JSONArray) root;
      List<ActiveNodeInfo> activeNodeInfos = new ArrayList<ActiveNodeInfo>();
      for (int i = 0; i < array.size(); i++) {
        JSONWalk walk = JSONWalk.on(array.get(i));
        JSONWrapper wrapper = walk.next("activeNode");
        JSONObject activeNode = wrapper.asObject();
   
        int x = JSONWalk.on(activeNode).next("x").asInt();
        int y = JSONWalk.on(activeNode).next("y").asInt();
   
        int width = JSONWalk.on(activeNode).next("width").asInt();
        int height = JSONWalk.on(activeNode).next("height").asInt();
        String name = JSONWalk.on(activeNode).next("name").asString();
           
        activeNodeInfos.add(
            new ActiveNodeInfo(
                -1, -1,
                new DiagramNodeInfo(name, x, y, width, height)
            )
          );
        wrapper = walk.next("activeNode");
      }
 
      // update view
      ActivityDiagramView view = (ActivityDiagramView) controller.getView(ActivityDiagramView.ID);
      view.update(
View Full Code Here

TOP

Related Classes of org.jboss.bpm.console.client.util.JSONWalk$JSONWrapper

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.