Package org.jboss.deployers.client.spi

Examples of org.jboss.deployers.client.spi.DeploymentFactory


      Deployment deployment = createDeployment();
      StructureMetaData structure = StructureMetaDataFactory.createStructureMetaData();
      MutableAttachments attachments = (MutableAttachments) deployment.getPredeterminedManagedObjects();
      attachments.addAttachment(StructureMetaData.class, structure);

      DeploymentFactory factory = getDeploymentFactory();
      factory.addContext(deployment, "");
      return deployment;
   }
View Full Code Here


      StructureMetaData structure = StructureMetaDataFactory.createStructureMetaData();
      MutableAttachments attachments = (MutableAttachments) deployment.getPredeterminedManagedObjects();
      attachments.addAttachment(StructureMetaData.class, structure);
      attachments.addAttachment("test", "hello");

      DeploymentFactory factory = getDeploymentFactory();
      factory.addContext(deployment, "");
      return deployment;
   }
View Full Code Here

      checkDeployment(context, deployment);
   }

   protected Deployment createOneChild() throws Exception
   {
      DeploymentFactory factory = getDeploymentFactory();
      Deployment deployment = createDeployment(factory);
      factory.addContext(deployment, "child1");
      return deployment;
   }
View Full Code Here

      checkDeployment(context, deployment);
   }

   protected Deployment createManyChildren() throws Exception
   {
      DeploymentFactory factory = getDeploymentFactory();
      Deployment deployment = createDeployment(factory);
      factory.addContext(deployment, "child1");
      factory.addContext(deployment, "child2");
      factory.addContext(deployment, "child3");
      return deployment;
   }
View Full Code Here

      checkDeployment(context, deployment);
   }

   protected Deployment createMetaDataLocation() throws Exception
   {
      DeploymentFactory factory = getDeploymentFactory();
      Deployment deployment = createDeployment();
      factory.addContext(deployment, "", ContextInfo.DEFAULT_METADATA_PATH, DeploymentFactory.createClassPath(""));
      return deployment;
   }
View Full Code Here

      checkDeployment(context, deployment);
   }

   protected Deployment createClasspathEntries() throws Exception
   {
      DeploymentFactory factory = getDeploymentFactory();
      Deployment deployment = createDeployment();
      ContextInfo contextInfo = factory.addContext(deployment, "");
      contextInfo.addClassPathEntry(DeploymentFactory.createClassPathEntry("cp1.txt"));
      contextInfo.addClassPathEntry(DeploymentFactory.createClassPathEntry("cp2.txt"));
      return deployment;
   }
View Full Code Here

   protected VFSDeployment createDeployment(String name) throws Exception
   {
      URL url = getClass().getProtectionDomain().getCodeSource().getLocation();
      VirtualFile file = VFS.getRoot(url);
      VFSDeployment deployment = VFSDeploymentFactory.getInstance().createVFSDeployment(file);
      DeploymentFactory factory = new DeploymentFactory();
      factory.addContext(deployment, "");
      ((AbstractDeployment) deployment).setName(name);
      return deployment;
   }
View Full Code Here

  
   protected abstract Deployment createDeployment();
  
   public void testCreateClassPathEntryPath()
   {
      DeploymentFactory factory = createDeploymentFactory();
      ClassPathEntry entry = factory.createClassPathEntry("path");
      assertEquals("path", entry.getPath());
      assertNull(entry.getSuffixes());
   }
View Full Code Here

      assertNull(entry.getSuffixes());
   }
  
   public void testCreateClassPathEntryPathErrors()
   {
      DeploymentFactory factory = createDeploymentFactory();
      try
      {
         factory.createClassPathEntry(null);
         fail("Should not be here!");
      }
      catch (Exception e)
      {
         checkThrowable(IllegalArgumentException.class, e);
View Full Code Here

      }
   }
  
   public void testCreateClassPathEntryPathAndSuffixes()
   {
      DeploymentFactory factory = createDeploymentFactory();
      ClassPathEntry entry = factory.createClassPathEntry("path", "suffixes");
      assertEquals("path", entry.getPath());
      assertEquals("suffixes", entry.getSuffixes());

      entry = factory.createClassPathEntry("path", null);
      assertEquals("path", entry.getPath());
      assertNull(entry.getSuffixes());
   }
View Full Code Here

TOP

Related Classes of org.jboss.deployers.client.spi.DeploymentFactory

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.