Examples of VirtualFile


Examples of org.jboss.osgi.vfs.VirtualFile

        // Attempt to install bundle from the modules hirarchy
        modulesFile = getRepositoryEntry(modulesDir, identifier);
        if (modulesFile != null) {
            URL url = modulesFile.toURI().toURL();
            VirtualFile virtualFile = AbstractVFS.toVirtualFile(url);
            if (BundleInfo.isValidBundle(virtualFile)) {
                ROOT_LOGGER.foundOsgiBundle(modulesFile);
                return installBundleFromURL(bundleManager, url, startLevel);
            }
        }
View Full Code Here

Examples of org.jboss.vfs.VirtualFile

     
      if (top.isTopLevel() == false) {
        top = du.getTopLevel();
      }
     
      VirtualFile root=((VFSDeploymentUnit)du).getRoot();
     
      logger.debug("Deployment descriptor file="+root);

      try {
        VirtualFile parent=((VFSDeploymentUnit)du).getRoot().getParent();
       
        long lastModTime=0;
       
        if (top instanceof VFSDeploymentUnit) {
          lastModTime = ((VFSDeploymentUnit)top).getRoot().getLastModified();
        } else {
          logger.warn("Unable to determine last modified time for: "+top);
        }
       
        // TODO: Need to be a more unique name, as it is possible that more
        // than one deployment descriptor may exist in the same AS archive
        BPELDeploymentUnit unit=new BPELDeploymentUnit(top.getSimpleName(), lastModTime);

        if (m_deploymentUnits.containsKey(unit.getName())) {
          doUndeploy(du, top);
        }
                   
         
        logger.info("Deploy: "+top.getSimpleName()+" relativePath="+
            du.getRelativePath());
       
        logger.debug("Deployment unit dir="+parent);
     
        // Explore the deployment unit (in place of previous VFSUtils.explode() which no longer exists)
        java.net.URL url=VFSUtils.getPhysicalURL(parent);
        for (VirtualFile vfile : parent.getChildrenRecursively()) {
          VFSUtils.getPhysicalURL(vfile);
        }
       
        logger.debug("Deployment exploded to dir="+root+" URL="+url);
View Full Code Here

Examples of org.jboss.vfs.VirtualFile

      // Fixup the uri and get a root context with spaces
      String deployDir = System.getProperty("jbosstest.deploy.dir");
      File file = new File(deployDir);
      file = new File(file, "dir with spaces");
      URI contextName = file.toURI();
      VirtualFile contextFile = VFS.getChild(contextName);
     
      // Create the deployment
      VirtualFile vf = contextFile.getChild("spaces.ear");
      assertNotNull(vf);
      Deployment deployment = VFSDeploymentFactory.getInstance().createVFSDeployment(vf);

      // Make sure we can deploy/undeploy it
      invoke(getDeployerName(), "deploy", new Object[]{ deployment }, new String[] { Deployment.class.getName() });
View Full Code Here

Examples of org.jboss.vfs.VirtualFile

      log.debug(VFS.class.getSimpleName() + "ManifestFinder instantiated.");
   }

   protected Manifest findManifest(URL url) throws Exception
   {
      VirtualFile root = VFS.getChild(url);
      return VFSUtils.getManifest(root);
   }
View Full Code Here

Examples of org.jboss.vfs.VirtualFile

         }

         Iterable<VirtualFile> classpaths = getClassPaths(unit);
         for (VirtualFile cp : classpaths)
         {
            VirtualFile wbXml = cp.getChild("META-INF/beans.xml");
            if (wbXml.exists())
            {
               // add url
               wbFiles.add(wbXml);
               // add classes
               cpFiles.add(cp);
            }
         }

         // handle war slightly different
         VirtualFile warWbXml = unit.getFile("WEB-INF/beans.xml");
         if (warWbXml != null)
         {
            wbFiles.add(warWbXml);

            VirtualFile classes = unit.getFile("WEB-INF/classes");
            if (classes != null)
               cpFiles.add(classes);
         }

         if (wbFiles.isEmpty() == false)
View Full Code Here

Examples of org.jboss.vfs.VirtualFile

         }
        
         String repositoryName = deploymentRepository.addDeploymentContent(deploymentName, contentIS, getDeploymentID().getDeploymentOptions());
        
         // FIXME make deployment visible to management view
         VirtualFile vf = deploymentRepository.getDeploymentContent(repositoryName);
        
         // FIXME
         ProfileKey key = getProfile().getKey();
         String profileName = key.getName();
         String repoDeploymentName = createDeploymentName(vf);
View Full Code Here

Examples of org.jboss.vfs.VirtualFile

      setStage(DeploymentStages.POST_PARSE);
   }

   public void deploy(VFSDeploymentUnit unit, JBossWebMetaData deployment) throws DeploymentException
   {
      VirtualFile facesConfigXml = unit.getMetaDataFile("faces-config.xml");
      if (facesConfigXml != null)
      {
         // TODO - Pete or Stan
      }
   }
View Full Code Here

Examples of org.jboss.vfs.VirtualFile

      {
         DeploymentProgress start = distributeAndStart(NESTED_DEPLOYMENT, deploymentName, true, false);
         String deployed = start.getDeploymentID().getRepositoryNames()[0];
        
         // Delete the file manually
         VirtualFile f = VFS.getChild(new URI(deployed));
         assertTrue(deployed, f.exists());
         assertTrue("deleted " + deployed, f.delete());
        
         stopAndRemove(new String[] { deploymentName });
      }
      finally
      {
View Full Code Here

Examples of org.jboss.vfs.VirtualFile

   */
   protected VirtualFile getRoot() throws IOException, URISyntaxException
   {
      URL url = getDeployURL("jboss-seam-booking.ear");
      assertNotNull(url);
      VirtualFile vf = VFS.getChild(url);
 
      handles = recursiveMount(vf);
 
      assertTrue(vf.exists());
      return vf;
   }
View Full Code Here

Examples of org.jboss.vfs.VirtualFile

      return cp;
   }

   public void testURLClassLoader() throws Exception
   {
      VirtualFile ear = getRoot();
      testURLClassLoader(ear);
   }
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.