Package org.jboss.forge.parser.xml

Examples of org.jboss.forge.parser.xml.Node.attribute()


      moduleXml.delete();
      moduleXml.createNewFile();

      // <resource-root path="maven-dependency.jar" />
      Node module = XMLParser.parse(getClass().getResourceAsStream("/org/jboss/forge/modules/module.xml"));
      module.attribute("name", pluginName);
      module.attribute("slot", pluginSlot);
      Node resources = module.getSingle("resources");

      resources.createChild("resource-root").attribute("path", dep.getArtifactId() + ".jar");
View Full Code Here


      moduleXml.createNewFile();

      // <resource-root path="maven-dependency.jar" />
      Node module = XMLParser.parse(getClass().getResourceAsStream("/org/jboss/forge/modules/module.xml"));
      module.attribute("name", pluginName);
      module.attribute("slot", pluginSlot);
      Node resources = module.getSingle("resources");

      resources.createChild("resource-root").attribute("path", dep.getArtifactId() + ".jar");

      // Copy the compiled JAR into the module directory
View Full Code Here

      moduleXml.delete();
      moduleXml.createNewFile();

      // <resource-root path="maven-dependency.jar" />
      Node module = XMLParser.parse(getClass().getResourceAsStream("/org/jboss/forge/modules/module.xml"));
      module.attribute("name", pluginName + ".dependencies");
      module.attribute("slot", pluginSlot);
      Node resources = module.getSingle("resources");

      // <module name="org.jboss.forge:main" />
      Node dependencies = module.getSingle("dependencies");
View Full Code Here

      moduleXml.createNewFile();

      // <resource-root path="maven-dependency.jar" />
      Node module = XMLParser.parse(getClass().getResourceAsStream("/org/jboss/forge/modules/module.xml"));
      module.attribute("name", pluginName + ".dependencies");
      module.attribute("slot", pluginSlot);
      Node resources = module.getSingle("resources");

      // <module name="org.jboss.forge:main" />
      Node dependencies = module.getSingle("dependencies");
      dependencies.createChild("module").attribute("name", "javax.api");
View Full Code Here

      Node plugin = module.attribute("name", "org.jboss.forge.plugins")
               .getSingle("dependencies")
               .getOrCreate("module@name=" + pluginName);

      plugin.attribute("slot", pluginSlot)
               .attribute("export", true).attribute("services", "export")
               .attribute("optional", "true");

      Node imports = plugin.getOrCreate("imports");
      imports.getOrCreate("include@path=**");
 
View Full Code Here

   {
      Node root = new Node("connection-profiles");
      for (ConnectionProfile descriptor : connectionProfiles)
      {
         Node child = root.createChild("connection-profile");
         child.attribute(CONFIG_KEY_NAME, descriptor.getName());
         child.attribute(CONFIG_KEY_DIALECT, descriptor.getDialect());
         child.attribute(CONFIG_KEY_DRIVER, descriptor.getDriver());
         child.attribute(CONFIG_KEY_PATH_TO_DRIVER, descriptor.getPath());
         child.attribute(CONFIG_KEY_URL, descriptor.getUrl());
         child.attribute(CONFIG_KEY_USER, descriptor.getUser());
View Full Code Here

      Node root = new Node("connection-profiles");
      for (ConnectionProfile descriptor : connectionProfiles)
      {
         Node child = root.createChild("connection-profile");
         child.attribute(CONFIG_KEY_NAME, descriptor.getName());
         child.attribute(CONFIG_KEY_DIALECT, descriptor.getDialect());
         child.attribute(CONFIG_KEY_DRIVER, descriptor.getDriver());
         child.attribute(CONFIG_KEY_PATH_TO_DRIVER, descriptor.getPath());
         child.attribute(CONFIG_KEY_URL, descriptor.getUrl());
         child.attribute(CONFIG_KEY_USER, descriptor.getUser());
      }
View Full Code Here

      for (ConnectionProfile descriptor : connectionProfiles)
      {
         Node child = root.createChild("connection-profile");
         child.attribute(CONFIG_KEY_NAME, descriptor.getName());
         child.attribute(CONFIG_KEY_DIALECT, descriptor.getDialect());
         child.attribute(CONFIG_KEY_DRIVER, descriptor.getDriver());
         child.attribute(CONFIG_KEY_PATH_TO_DRIVER, descriptor.getPath());
         child.attribute(CONFIG_KEY_URL, descriptor.getUrl());
         child.attribute(CONFIG_KEY_USER, descriptor.getUser());
      }
      if (root.getChildren().isEmpty())
View Full Code Here

      {
         Node child = root.createChild("connection-profile");
         child.attribute(CONFIG_KEY_NAME, descriptor.getName());
         child.attribute(CONFIG_KEY_DIALECT, descriptor.getDialect());
         child.attribute(CONFIG_KEY_DRIVER, descriptor.getDriver());
         child.attribute(CONFIG_KEY_PATH_TO_DRIVER, descriptor.getPath());
         child.attribute(CONFIG_KEY_URL, descriptor.getUrl());
         child.attribute(CONFIG_KEY_USER, descriptor.getUser());
      }
      if (root.getChildren().isEmpty())
      {
View Full Code Here

         Node child = root.createChild("connection-profile");
         child.attribute(CONFIG_KEY_NAME, descriptor.getName());
         child.attribute(CONFIG_KEY_DIALECT, descriptor.getDialect());
         child.attribute(CONFIG_KEY_DRIVER, descriptor.getDriver());
         child.attribute(CONFIG_KEY_PATH_TO_DRIVER, descriptor.getPath());
         child.attribute(CONFIG_KEY_URL, descriptor.getUrl());
         child.attribute(CONFIG_KEY_USER, descriptor.getUser());
      }
      if (root.getChildren().isEmpty())
      {
         config.clearProperty("connection-profiles");
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.