Package org.springframework.integration.aws

Examples of org.springframework.integration.aws.Permission


      NodeList permNodes = permissionsElement.getChildNodes();
      for (int i = 0; i < permNodes.getLength(); i++) {
        Node permNode = permNodes.item(i);
        if (Node.ELEMENT_NODE == permNode.getNodeType()) {
          Element permissionElement = (Element) permNode;
          Permission permission = new Permission(
              permissionElement.getAttribute("label"),
              new HashSet<String>(), new HashSet<String>());

          Element actionsElement = DomUtils.getChildElementByTagName(
              permissionElement, "actions");
          NodeList actionNodes = actionsElement.getChildNodes();
          for (int j = 0; j < actionNodes.getLength(); j++) {
            Node actionNode = actionNodes.item(j);
            if (Node.ELEMENT_NODE == actionNode.getNodeType()) {
              Element actionElement = (Element) actionNode;
              permission.getActions().add(
                  actionElement.getTextContent());
            }
          }

          Element accountsElement = DomUtils
              .getChildElementByTagName(permissionElement,
                  "aws-accounts");
          NodeList accountNodes = accountsElement.getChildNodes();
          for (int j = 0; j < accountNodes.getLength(); j++) {
            Node accountNode = accountNodes.item(j);
            if (Node.ELEMENT_NODE == accountNode.getNodeType()) {
              Element accountElement = (Element) accountNode;
              permission.getAwsAccountIds().add(
                  accountElement.getTextContent());
            }
          }

          permissions.add(permission);
View Full Code Here

TOP

Related Classes of org.springframework.integration.aws.Permission

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.