Package org.jboss.shrinkwrap.api.asset

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


      }
   };
  
   public static void addCDIManifest(JavaArchive archive)
   {
      archive.addManifestResource(new ByteArrayAsset("<web-beans></web-beans>".getBytes()),
               ArchivePaths.create("beans.xml"));
   }
View Full Code Here


               ArchivePaths.create("beans.xml"));
   }
  
   public static void addCDIManifest(WebArchive archive)
   {
      archive.add(new ByteArrayAsset("<beans/>".getBytes()),
               ArchivePaths.create("WEB-INF/beans.xml"));
   }
View Full Code Here

               ArchivePaths.create("WEB-INF/beans.xml"));
   }
  
   public static void addManifest(JavaArchive archive)
   {
      archive.addManifestResource(new ByteArrayAsset("<ejb-jar/>".getBytes()),
               ArchivePaths.create("ejb-jar.xml"));
   }
View Full Code Here

      }
   }
  
   public static void addManifest(WebArchive archive)
   {
      archive.add(new ByteArrayAsset("<web/>".getBytes()), ArchivePaths.create("WEB-INF/web.xml"));
   }
View Full Code Here

         // remove leading '/' char
         String path = archivePath.get().substring(1);
         appProperties.append(path.replace('.', '_')).append("-module=").append(path);
         appProperties.append('\n');
      }
      archive.addManifestResource(new ByteArrayAsset(appProperties.toString().getBytes()),
               "application.properties");
   }
View Full Code Here

                final ByteArrayOutputStream bytes = new ByteArrayOutputStream();
                ObjectOutputStream out = new ObjectOutputStream(bytes);
                out.writeObject(props.get("managementPort"));
                out.writeObject(NetworkUtils.formatPossibleIpv6Address(props.get("managementAddress")));
                out.close();
                serviceArchive.addAsManifestResource(new ByteArrayAsset(bytes.toByteArray()), "org.jboss.as.managementConnectionProps");

                DeployableContainer<?> deployableContainer = container.getDeployableContainer();
                deployableContainer.deploy(serviceArchive);
                serviceArchiveDeployed.add(container.getName());
            } catch (Throwable th) {
View Full Code Here

    for (String[] replacement : replacements) {
      string = string.replaceAll(replacement[0], replacement[1]);
    }

    return new ByteArrayAsset(string.getBytes());

  }
View Full Code Here

   
    JavaArchive foxPlatformClientJar = DeploymentHelper.getEjbClient();
   
    WebArchive testJar = ShrinkWrap.create(WebArchive.class, "client-test.war")
      .addAsWebInfResource(EmptyAsset.INSTANCE, "beans.xml")
      .setManifest(new ByteArrayAsset(("Class-Path: " + foxPlatformClientJar.getName()+"\n").getBytes()))
      .addClass(AbstractFoxPlatformIntegrationTest.class)
      .addClass(TestFoxPlatformClientAsEjbModule_twoPasAsLib.class);

    return ShrinkWrap.create(EnterpriseArchive.class, "twoPasAsLib.ear")           
      .addAsLibrary(processArchive1Jar)
View Full Code Here

   
    JavaArchive foxPlatformClientJar = DeploymentHelper.getEjbClient();
   
    WebArchive testJar = ShrinkWrap.create(WebArchive.class, "test.war")
      .addAsWebInfResource(EmptyAsset.INSTANCE, "beans.xml")
      .setManifest(new ByteArrayAsset(("Class-Path: " + foxPlatformClientJar.getName()+"\n").getBytes()))
      .addClass(AbstractFoxPlatformIntegrationTest.class)
      .addClass(TestFoxPlatformClientAsEjbModule_onePaAsLib.class);

    return ShrinkWrap.create(EnterpriseArchive.class, "onePaAsLib.ear")           
      .addAsLibrary(processArchiveJar)
View Full Code Here

      JavaArchive archive = ShrinkWrap.create(JavaArchive.class, "test.jar")
               .addPackages(true, Root.class.getPackage())
               .addPackages(true, RenderRoot.class.getPackage())
               .addPackages(true, SolderRoot.class.getPackage())
               .addAsManifestResource(new ByteArrayAsset("<beans/>".getBytes()), ArchivePaths.create("beans.xml"));

      return archive;
   }
View Full Code Here

TOP

Related Classes of org.jboss.shrinkwrap.api.asset.ByteArrayAsset

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.