Examples of ArchiveAsset


Examples of org.jboss.shrinkwrap.api.asset.ArchiveAsset

                                    + "Agent-Class: org.jboss.byteman.agent.Main\n"
                                    + "Can-Redefine-Classes: true\n"
                                    + "Can-Retransform-Classes: true\n"));

            // add byteman archive as a resource in the jar, needed to install
            jar.add(new ArchiveAsset(agentJar, ZipExporter.class), BytemanConfiguration.BYTEMAN_JAR);
        }
        return jar;
    }
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.ArchiveAsset

      {
         if( !(nestedArchiveEntry.getValue().getAsset() instanceof ArchiveAsset))
         {
            continue;
         }
         ArchiveAsset nestedArchive = (ArchiveAsset)nestedArchiveEntry.getValue().getAsset();
         Map<ArchivePath, Node> classes = nestedArchive.getArchive().getContent(Filters.include(".*/beans.xml"));
         for(final Map.Entry<ArchivePath, Node> entry : classes.entrySet())
         {
            try
            {
               beansXmls.add(
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.ArchiveAsset

         {
            if( !(nestedArchiveEntry.getValue().getAsset() instanceof ArchiveAsset))
            {
               continue;
            }
            ArchiveAsset nestedArchive = (ArchiveAsset)nestedArchiveEntry.getValue().getAsset();
            Map<ArchivePath, Node> classes = nestedArchive.getArchive().getContent(Filters.include(".*\\.class"));
            for(Map.Entry<ArchivePath, Node> classEntry : classes.entrySet())
            {
               Class<?> loadedClass = classLoader.loadClass(
                     findClassName(classEntry.getKey()));
  
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.ArchiveAsset

      final Collection<Node> nodes = new LinkedList<Node>(getPersistenceDescriptors(archive));
      for (Node node : collectSubArchives(archive))
      {
         if (node.getAsset() instanceof ArchiveAsset)
         {
            final ArchiveAsset archiveAsset = (ArchiveAsset) node.getAsset();
            nodes.addAll(collectPersistenceXml(archiveAsset.getArchive()));
         }
      }
      return nodes;
   }
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.ArchiveAsset

      {
         if( !(nestedArchiveEntry.getValue().getAsset() instanceof ArchiveAsset))
         {
            continue;
         }
         ArchiveAsset nestedArchive = (ArchiveAsset)nestedArchiveEntry.getValue().getAsset();
         Map<ArchivePath, Node> classes = nestedArchive.getArchive().getContent(Filters.include(".*/beans.xml"));
         for(final Map.Entry<ArchivePath, Node> entry : classes.entrySet())
         {
            try
            {
               beansXmls.add(
                     new URL(null, "archive://" + nestedArchive.getArchive().getName() +  entry.getKey().get(), new URLStreamHandler()
                     {
                        @Override
                        protected java.net.URLConnection openConnection(URL u) throws java.io.IOException
                        {
                           return new URLConnection(u)
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.ArchiveAsset

         {
            if( !(nestedArchiveEntry.getValue().getAsset() instanceof ArchiveAsset))
            {
               continue;
            }
            ArchiveAsset nestedArchive = (ArchiveAsset)nestedArchiveEntry.getValue().getAsset();
            Map<ArchivePath, Node> classes = nestedArchive.getArchive().getContent(Filters.include(".*\\.class"));
            for(Map.Entry<ArchivePath, Node> classEntry : classes.entrySet())
            {
               Class<?> loadedClass = classLoader.loadClass(
                     findClassName(classEntry.getKey()));
  
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.ArchiveAsset

        // and now scan all the jars in the WAR
        Map<ArchivePath, Node> jars = archive.getContent(Filters.include("/WEB-INF/lib/.*\\.jar"));
        for (Map.Entry<ArchivePath, Node> jarEntry : jars.entrySet())
        {
            ArchiveAsset archiveAsset = (ArchiveAsset) jarEntry.getValue().getAsset();
            JavaArchive jarArchive = (JavaArchive) archiveAsset.getArchive();
            scanJarArchive(jarArchive);
        }

    }
View Full Code Here

Examples of org.jboss.shrinkwrap.impl.base.asset.ArchiveAsset

      {
         // TODO: fix, relies on internal SW details, find web archive and attach our self to it, SHRINKWRAP-192        
         Asset warAsset = applicationArchiveWars.values().iterator().next().getAsset();
         if (warAsset instanceof ArchiveAsset)
         {
            ArchiveAsset warArchiveAsset = (ArchiveAsset) warAsset;
            handleArchive(
                  warArchiveAsset.getArchive().as(WebArchive.class),
                  new ArrayList<Archive<?>>(), // reuse the War handling, but Auxiliary Archives should be added to the EAR, not the WAR
                  protocol,
                  processor);
         }
      }
View Full Code Here

Examples of org.jboss.shrinkwrap.impl.base.asset.ArchiveAsset

      {
         // TODO: fix, relies on internal SW details, find web archive and attach our self to it, SHRINKWRAP-192        
         Asset warAsset = applicationArchiveWars.values().iterator().next().getAsset();
         if (warAsset instanceof ArchiveAsset)
         {
            ArchiveAsset warArchiveAsset = (ArchiveAsset) warAsset;
            handleArchive(
                  warArchiveAsset.getArchive().as(WebArchive.class),
                  new ArrayList<Archive<?>>(), // reuse the War handling, but Auxiliary Archives should be added to the EAR, not the WAR
                  protocol,
                  processor);
         }
      }
View Full Code Here

Examples of org.jboss.shrinkwrap.impl.base.asset.ArchiveAsset

      {
         // TODO: fix, relies on internal SW details, find web archive and attach our self to it, SHRINKWRAP-192        
         Asset warAsset = applicationArchiveWars.values().iterator().next().getAsset();
         if (warAsset instanceof ArchiveAsset)
         {
            ArchiveAsset warArchiveAsset = (ArchiveAsset) warAsset;
            handleArchive(
                  warArchiveAsset.getArchive().as(WebArchive.class),
                  new ArrayList<Archive<?>>(), // reuse the War handling, but Auxiliary Archives should be added to the EAR, not the WAR
                  protocol,
                  processor);
         }
      }
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.