@Override
   public Element generateDataElement(LauncherAction action) {
      
      JavaAppDesc desc = (JavaAppDesc)action.getLaunchDesc();
      org.w3c.dom.Element e = createInitialElement(desc);
      
      //Main Class
      e.setAttribute("main-class", desc.getMainClass());
      
      //Arguments
      String[] args = desc.getMainArgs();
      StringBuffer argLine = new StringBuffer();
      if(args != null) {
         for(int i=0;i<args.length;i++) {
            argLine.append(args[i] + " ");
         }
      }
      e.setAttribute("args", argLine.toString().trim());
      
      //Permissions
      if(desc.getPermissions() != null) {
         e.setAttribute("permissions", "all-permissions");
      }
      else {
         e.setAttribute("permissions", "restricted-permissions");
      }
      
      //Use WebStart
      if(desc.useWebStart()) {
         e.setAttribute("use-webstart", "true");
      }
      else {
         e.setAttribute("use-webstart", "false");
      }
      
      //Use Separate VM
      if(desc.useSeperateVM()) {
         e.setAttribute("separate-vm", "true");
      }
      else {
         e.setAttribute("separate-vm", "false");
      }
      
      //Use Separate VM
      if(desc.useSharedClassLoader()) {
         e.setAttribute("shared-classloader", "true");
      }
      else {
         e.setAttribute("shared-classloader", "false");
      }
      
      //Java Archives
      org.w3c.dom.Element resources = e.getOwnerDocument().createElement("resources");
      e.appendChild(resources);
      Iterator it = desc.getJavaArchives().iterator();
      while(it.hasNext()) {
         URL javaResource = (URL)it.next();
         org.w3c.dom.Element jarElement = e.getOwnerDocument().createElement("jar");
         jarElement.setAttribute("href", javaResource.toString());
         resources.appendChild(jarElement);
      }
      
      //Native Archives
      it = desc.getNativeArchives().iterator();
      while(it.hasNext()) {
         NativeLibDesc nativeLib = (NativeLibDesc)it.next();
         org.w3c.dom.Element nativeElement = e.getOwnerDocument().createElement("nativelib");
         nativeElement.setAttribute("href", nativeLib.getPath().toString());
         nativeElement.setAttribute("os", nativeLib.getOS());
         resources.appendChild(nativeElement);
      }
      
      return e;
   }