Examples of ClassLoadingMetaData


Examples of org.jboss.classloading.spi.metadata.ClassLoadingMetaData

   }

   @Override
   public void deploy(VFSDeploymentUnit unit, T metaData) throws DeploymentException
   {
      ClassLoadingMetaData clmd = unit.getAttachment(ClassLoadingMetaData.class);
      RequirementsMetaData requirements = clmd.getRequirements();
      AbstractRequirement integrationModule = hasIntegrationModuleRequirement(requirements);
      // If we are importing integration core then import the jboss integration at the same version
      if (integrationModule != null)
      {
         ClassLoadingMetaDataFactory factory = ClassLoadingMetaDataFactory.getInstance();
View Full Code Here

Examples of org.jboss.classloading.spi.metadata.ClassLoadingMetaData

   @Override
   public void deploy(DeploymentUnit unit, ClassLoadingMetaData deployment) throws DeploymentException
   {
      if (deployment == null)
      {
         ClassLoadingMetaData cloned = defaultMetaData.clone();
         cloned.setName(unit.getSimpleName());
         unit.addAttachment(ClassLoadingMetaData.class, cloned);
      }
      else if ("<unknown>".equals(deployment.getName()))
      {
         deployment.setName(unit.getSimpleName());
View Full Code Here

Examples of org.jboss.classloading.spi.metadata.ClassLoadingMetaData

   }

   @Override
   public void deploy(DeploymentUnit unit, ServiceDeployment metaData) throws DeploymentException
   {
      ClassLoadingMetaData classLoadingMetaData = unit.getAttachment(ClassLoadingMetaData.class);
      if (classLoadingMetaData != null)
         return;

      LoaderRepositoryConfig config = metaData.getLoaderRepositoryConfig();
      if (config != null)
View Full Code Here

Examples of org.jboss.classloading.spi.metadata.ClassLoadingMetaData

   public static ClassLoadingMetaData create(DeploymentUnit unit, LoaderRepositoryConfig loaderConfig, boolean parentDelegation) throws DeploymentException
   {
      if (unit == null)
         throw new IllegalArgumentException("Null unit");
     
      ClassLoadingMetaData clmd = unit.getAttachment(ClassLoadingMetaData.class);
      if (clmd != null)
         return clmd;
     
      clmd = create(unit.getName(), loaderConfig, parentDelegation);
      if (clmd != null)
View Full Code Here

Examples of org.jboss.classloading.spi.metadata.ClassLoadingMetaData

      if (name == null)
         return null;
      String domain = name.getCanonicalName().trim();
      if (domain.length() == 0)
         return null;
      ClassLoadingMetaData metaData = new ClassLoadingMetaData();
      metaData.setName(deploymentName);
      metaData.setDomain(domain);
      metaData.setExportAll(ExportAll.NON_EMPTY);
      metaData.setImportAll(true);
      metaData.setVersion(Version.DEFAULT_VERSION);

      Properties props = new Properties();
      String config = loaderConfig.repositoryConfig;
      try
      {
         if (config != null)
         {
            ByteArrayInputStream bais = new ByteArrayInputStream(config.getBytes());
            props.load(bais);
         }
      }
      catch (Exception e)
      {
         throw DeploymentException.rethrowAsDeploymentException("Error parsing repository config " + config, e);
      }
      String java2ParentDelegation = props.getProperty("java2ParentDelegation");
      // Check for previous mis-spelled property name
      if( java2ParentDelegation == null )
         java2ParentDelegation = props.getProperty("java2ParentDelegaton");
      boolean useParentFirst = parentDelegation;
      if (java2ParentDelegation != null)
         useParentFirst = Boolean.valueOf(java2ParentDelegation);
      metaData.setJ2seClassLoadingCompliance(useParentFirst);
      return metaData;
   }
View Full Code Here

Examples of org.jboss.classloading.spi.metadata.ClassLoadingMetaData

      assertNull(result.getRequirements().getRequirements());
   }

   public void testModuleVersion() throws Exception
   {
      ClassLoadingMetaData result = unmarshal();
      assertEquals(Version.parseVersion("1.0.0"), result.getVersion());
   }
View Full Code Here

Examples of org.jboss.classloading.spi.metadata.ClassLoadingMetaData

      assertEquals(Version.parseVersion("1.0.0"), result.getVersion());
   }

   public void testModuleDomain() throws Exception
   {
      ClassLoadingMetaData result = unmarshal();
      assertEquals("testDomain", result.getDomain());
   }
View Full Code Here

Examples of org.jboss.classloading.spi.metadata.ClassLoadingMetaData

      assertEquals("testDomain", result.getDomain());
   }

   public void testModuleParentDomain() throws Exception
   {
      ClassLoadingMetaData result = unmarshal();
      assertEquals("testParentDomain", result.getParentDomain());
   }
View Full Code Here

Examples of org.jboss.classloading.spi.metadata.ClassLoadingMetaData

      assertEquals("testParentDomain", result.getParentDomain());
   }

   public void testModuleExportAll() throws Exception
   {
      ClassLoadingMetaData result = unmarshal();
      assertEquals(ExportAll.ALL, result.getExportAll());
   }
View Full Code Here

Examples of org.jboss.classloading.spi.metadata.ClassLoadingMetaData

      assertEquals(ExportAll.ALL, result.getExportAll());
   }

   public void testModuleIncluded() throws Exception
   {
      ClassLoadingMetaData result = unmarshal();
      assertEquals("Included", result.getIncludedPackages());
   }
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.