Package org.jboss.virtual

Examples of org.jboss.virtual.VirtualFile.toURI()


   {
      URL rootURL = getResource("/vfs/test");
      VFS vfs = VFS.getVFS(rootURL);
      VirtualFile tstjar = vfs.findChild("path with spaces/unpacked-tst.jar");
      assertNotNull("tstjar != null", tstjar);
      URI uri = tstjar.toURI();
      URI expectedURI = new URI("vfs" + rootURL.toString()+"/path%20with%20spaces/unpacked-tst.jar/");
      assertEquals(uri, expectedURI);
   }

   public void testPathWithPluses() throws Exception
View Full Code Here


      throws Exception
   {
      URL rootURL = getClass().getProtectionDomain().getCodeSource().getLocation();
      VFS rootVFS0 = VFS.getVFS(rootURL.toURI());
      VirtualFile root0 = rootVFS0.getRoot();
      VFS rootVFS1 = VFS.getVFS(root0.toURI());
      VirtualFile root1 = rootVFS1.getRoot();
      assertEquals(root0, root1);
   }

   /**
 
View Full Code Here

      VFS vfs = VFS.getVFS(root.toURI());
      File archive = generateArchive(deployDir);
      VirtualFile archiveVF = vfs.getChild("deploy/"+archive.getName());     
      VFSDeployment vfsd = VFSDeploymentFactory.getInstance().createVFSDeployment(archiveVF);
      repository.addDeployment(archiveVF.toURI().toString(), vfsd, DeploymentPhase.APPLICATION);

      getLog().debug("Waiting for 10 scans...");
      scanner.start();
      while(scanner.getScanCount() < 10)
      {
View Full Code Here

      assertNotNull(nestedChild);

      assertTempFiles(1);

      nestedChild.cleanup();
      assertRegistryEntryExists(nestedChild.toURI());

      root.cleanup();

      assertTempFiles(0);
      assertNoRegistryEntry(root.toURI());
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.