Examples of GroupNode


Examples of org.apache.geronimo.gshell.layout.model.GroupNode

        if (properties.containsKey("rank")) {
            rank = Integer.parseInt((String) properties.get("rank"));
        }

        // Find or create the subshell group
        GroupNode gn = layout;
        String shell = (String) properties.get("shell");
        String[] aliases = properties.get("alias") != null ? properties.get("alias").toString().split(",") : new String[0];

        if (name.equals(shell))
        {
            Node n = gn.find(shell);
            MutableGroupNode g = new MutableGroupNode(shell);
            gn.add(g);
            register(command);
        }
        else
        {
            if (shell != null && shell.length() > 0) {
                Node n = gn.find(shell);
                if (n == null) {
                    MutableGroupNode g = new MutableGroupNode(shell);
                    gn.add(g);
                    register(new GroupCommand(shell, g));
                    gn = g;
                } else if (n instanceof GroupNode) {
                    gn = (GroupNode) n;
                } else {
                    throw new IllegalStateException("A command conflicts has been detected when registering " + command.getId());
                }
            }

            CommandNode cn = new CommandNode(name, command.getId());
            gn.add(cn);

            for (int i = 0; i < aliases.length; i++) {
                if (!name.equals(aliases[i])) {
                    AliasNode an = new AliasNode(aliases[i], ALIAS_PREFIX + command.getId());
                    gn.add(an);
                }
            }

            register(command);
        }
View Full Code Here

Examples of org.apache.geronimo.gshell.layout.model.GroupNode

        if (properties.containsKey("rank")) {
            rank = Integer.parseInt((String) properties.get("rank"));
        }

        // Find or create the subshell group
        GroupNode gn = layout;
        String shell = (String) properties.get("shell");
        String[] aliases = properties.get("alias") != null ? properties.get("alias").toString().split(",") : new String[0];

        if (name.equals(shell))
        {
            Node n = gn.find(shell);
            MutableGroupNode g = new MutableGroupNode(shell);
            gn.add(g);
            register(command);
        }
        else
        {
            if (shell != null && shell.length() > 0) {
                Node n = gn.find(shell);
                if (n == null) {
                    MutableGroupNode g = new MutableGroupNode(shell);
                    gn.add(g);
                    register(new GroupCommand(shell, g));
                    gn = g;
                } else if (n instanceof GroupNode) {
                    gn = (GroupNode) n;
                } else {
                    throw new IllegalStateException("A command conflicts has been detected when registering " + command.getId());
                }
            }

            CommandNode cn = new CommandNode(name, command.getId());
            gn.add(cn);

            for (int i = 0; i < aliases.length; i++) {
                if (!name.equals(aliases[i])) {
                    AliasNode an = new AliasNode(aliases[i], ALIAS_PREFIX + command.getId());
                    gn.add(an);
                }
            }

            register(command);
        }
View Full Code Here

Examples of org.apache.myfaces.trinidad.menu.GroupNode

    * @return Node of type GroupNode
    */
  private GroupNode _createGroupNode()
  {
    // Create the GroupNode
    GroupNode groupNode = new GroupNode();
    String idRef = _getAndRemoveAttrValue(_IDREF_ATTR);

    // Set its attributes - null is ok
    groupNode.setIdRef(idRef);

    return groupNode;
  }
View Full Code Here

Examples of org.apache.myfaces.trinidad.menu.GroupNode

    * @return Node of type GroupNode
    */
  private GroupNode _createGroupNode()
  {
    // Create the GroupNode
    GroupNode groupNode = new GroupNode();
    String idRef = _getAndRemoveAttrValue(_IDREF_ATTR);

    // Set its attributes - null is ok
    groupNode.setIdRef(idRef);

    return groupNode;
  }
View Full Code Here

Examples of org.apache.slide.structure.GroupNode

                SlideToken slidetoken = new SlideTokenImpl(new CredentialsToken(caller));

                String strUri = config.getUsersPath()+"/"+group.getName();

                // create the node in the structure
                ObjectNode object = new GroupNode();

                structure.create(slidetoken, object, strUri);

                // create a revision with the appropriate properties set
                NodeRevisionDescriptor revision = new NodeRevisionDescriptor(0);
View Full Code Here

Examples of org.apache.slide.structure.GroupNode

                SlideToken slidetoken = new SlideTokenImpl(new CredentialsToken(caller));

                String strUri = config.getUsersPath()+"/"+group.getName();

                // create the node in the structure
                ObjectNode object = new GroupNode();

                structure.create(slidetoken, object, strUri);

                // create a revision with the appropriate properties set
                NodeRevisionDescriptor revision = new NodeRevisionDescriptor(0);
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.