本文整理了Java中org.jboss.shrinkwrap.api.Archive.merge()
方法的一些代码示例,展示了Archive.merge()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Archive.merge()
方法的具体详情如下:
包路径:org.jboss.shrinkwrap.api.Archive
类名称:Archive
方法名:merge
[英]Merge the contents from an existing archive without maintaining the archive name in the context path.
[中]合并现有存档中的内容,而不在上下文路径中维护存档名称。
代码示例来源:origin: wildfly/wildfly-arquillian
@Override
public T merge(final Archive<?> source, final ArchivePath path) throws IllegalArgumentException {
return delegate.merge(source, path);
}
代码示例来源:origin: wildfly/wildfly-arquillian
@Override
public T merge(final Archive<?> source, final String path, final Filter<ArchivePath> filter) throws IllegalArgumentException {
return delegate.merge(source, path, filter);
}
代码示例来源:origin: org.jboss.arquillian.extension/arquillian-persistence-core
private void addResources(Archive<?> applicationArchive, final JavaArchive dataArchive)
{
if (JavaArchive.class.isInstance(applicationArchive))
{
applicationArchive.merge(dataArchive);
}
else
{
final LibraryContainer<?> libraryContainer = (LibraryContainer<?>) applicationArchive;
libraryContainer.addAsLibrary(dataArchive);
}
}
代码示例来源:origin: org.jboss.arquillian.extension/arquillian-persistence-dbunit
private void addResources(Archive<?> applicationArchive, final JavaArchive dataArchive)
{
if (JavaArchive.class.isInstance(applicationArchive))
{
applicationArchive.merge(dataArchive);
}
else
{
final LibraryContainer<?> libraryContainer = (LibraryContainer<?>) applicationArchive;
libraryContainer.addAsLibrary(dataArchive);
}
}
代码示例来源:origin: org.jboss.arquillian.extension/arquillian-persistence-impl
private void addResources(Archive<?> applicationArchive, final JavaArchive dataArchive)
{
if (JavaArchive.class.isInstance(applicationArchive))
{
applicationArchive.merge(dataArchive);
}
else
{
final LibraryContainer<?> libraryContainer = (LibraryContainer<?>) applicationArchive;
libraryContainer.addAsLibrary(dataArchive);
}
}
代码示例来源:origin: org.jboss.shrinkwrap/shrinkwrap-impl-base
/**
* {@inheritDoc}
*
* @see org.jboss.shrinkwrap.api.Archive#merge(org.jboss.shrinkwrap.api.Archive, org.jboss.shrinkwrap.api.Filter)
*/
@Override
public T merge(Archive<?> source, Filter<ArchivePath> filter) throws IllegalArgumentException {
this.getArchive().merge(source, filter);
return covarientReturn();
}
代码示例来源:origin: org.jboss.shrinkwrap/shrinkwrap-impl-base
/**
* {@inheritDoc}
*
* @see org.jboss.shrinkwrap.api.Archive#merge(org.jboss.shrinkwrap.api.Archive, java.lang.String,
* org.jboss.shrinkwrap.api.Filter)
*/
@Override
public T merge(final Archive<?> source, final String path, final Filter<ArchivePath> filter)
throws IllegalArgumentException {
this.getArchive().merge(source, path, filter);
return covarientReturn();
}
代码示例来源:origin: org.jboss.shrinkwrap/shrinkwrap-impl-base
/**
* {@inheritDoc}
*
* @see org.jboss.shrinkwrap.api.Archive#merge(org.jboss.shrinkwrap.api.Archive,
* org.jboss.shrinkwrap.api.ArchivePath, org.jboss.shrinkwrap.api.Filter)
*/
@Override
public T merge(Archive<?> source, ArchivePath path, Filter<ArchivePath> filter) throws IllegalArgumentException {
this.getArchive().merge(source, path, filter);
return covarientReturn();
}
代码示例来源:origin: shrinkwrap/shrinkwrap
/**
* {@inheritDoc}
*
* @see org.jboss.shrinkwrap.api.Archive#merge(org.jboss.shrinkwrap.api.Archive,
* org.jboss.shrinkwrap.api.ArchivePath)
*/
@Override
public T merge(Archive<?> source, ArchivePath path) throws IllegalArgumentException {
this.getArchive().merge(source, path);
return covarientReturn();
}
代码示例来源:origin: org.jboss.shrinkwrap/shrinkwrap-impl-base
/**
* {@inheritDoc}
*
* @see org.jboss.shrinkwrap.api.Archive#merge(org.jboss.shrinkwrap.api.Archive)
*/
@Override
public T merge(Archive<?> source) throws IllegalArgumentException {
this.getArchive().merge(source);
return covarientReturn();
}
代码示例来源:origin: org.jboss.shrinkwrap/shrinkwrap-impl-base
/**
* {@inheritDoc}
*
* @see org.jboss.shrinkwrap.api.Archive#merge(org.jboss.shrinkwrap.api.Archive,
* org.jboss.shrinkwrap.api.ArchivePath)
*/
@Override
public T merge(Archive<?> source, ArchivePath path) throws IllegalArgumentException {
this.getArchive().merge(source, path);
return covarientReturn();
}
代码示例来源:origin: org.jboss.shrinkwrap/shrinkwrap-impl-base
/**
* {@inheritDoc}
*
* @see org.jboss.shrinkwrap.api.Archive#merge(org.jboss.shrinkwrap.api.Archive, java.lang.String)
*/
@Override
public T merge(final Archive<?> source, final String path) throws IllegalArgumentException {
this.getArchive().merge(source, path);
return covarientReturn();
}
代码示例来源:origin: shrinkwrap/shrinkwrap
/**
* {@inheritDoc}
*
* @see org.jboss.shrinkwrap.api.Archive#merge(org.jboss.shrinkwrap.api.Archive)
*/
@Override
public T merge(Archive<?> source) throws IllegalArgumentException {
this.getArchive().merge(source);
return covarientReturn();
}
代码示例来源:origin: shrinkwrap/shrinkwrap
/**
* {@inheritDoc}
*
* @see org.jboss.shrinkwrap.api.Archive#merge(org.jboss.shrinkwrap.api.Archive, org.jboss.shrinkwrap.api.Filter)
*/
@Override
public T merge(Archive<?> source, Filter<ArchivePath> filter) throws IllegalArgumentException {
this.getArchive().merge(source, filter);
return covarientReturn();
}
代码示例来源:origin: shrinkwrap/shrinkwrap
/**
* {@inheritDoc}
*
* @see org.jboss.shrinkwrap.api.Archive#merge(org.jboss.shrinkwrap.api.Archive, java.lang.String,
* org.jboss.shrinkwrap.api.Filter)
*/
@Override
public T merge(final Archive<?> source, final String path, final Filter<ArchivePath> filter)
throws IllegalArgumentException {
this.getArchive().merge(source, path, filter);
return covarientReturn();
}
代码示例来源:origin: com.kumuluz.ee.testing/kumuluzee-arquillian-container
private static void moveDir(Archive<?> archive, String source, String target) {
if (archive.contains(source)) {
Archive<?> tmp = ShrinkWrap.create(JavaArchive.class);
copyDir(archive, tmp, source, target);
archive.merge(tmp);
archive.delete(source);
}
}
代码示例来源:origin: io.thorntail/arquillian-daemon
private void mergeAuxAsClasses(final Archive<?> archive, final TestDeployment testDeployment) {
final Map<ArchivePath, List<Node>> serviceDescriptors = new HashMap<>();
findServiceDescriptors(archive, serviceDescriptors);
testDeployment.getAuxiliaryArchives().forEach(aux -> {
findServiceDescriptors(aux, serviceDescriptors);
archive.merge(aux);
});
mergeServiceDescriptors(serviceDescriptors)
.forEach((path, asset) -> archive.add(asset, path));
}
代码示例来源:origin: wildfly-swarm-archive/ARCHIVE-wildfly-swarm
private void mergeAuxAsClasses(final Archive<?> archive, final TestDeployment testDeployment) {
final Map<ArchivePath, List<Node>> serviceDescriptors = new HashMap<>();
findServiceDescriptors(archive, serviceDescriptors);
testDeployment.getAuxiliaryArchives().forEach(aux -> {
findServiceDescriptors(aux, serviceDescriptors);
archive.merge(aux);
});
mergeServiceDescriptors(serviceDescriptors)
.forEach((path, asset) -> archive.add(asset, path));
}
代码示例来源:origin: org.apache.openejb/ziplock
private Builder add(final Archive<?> webArchive, final File dir, final String root) {
if (dir == null || !dir.exists()) {
return this;
}
final KnownResourcesFilter filter = new KnownResourcesFilter(dir, root, this.filter);
filter.update(
webArchive.merge(
ShrinkWrap.create(GenericArchive.class).as(ExplodedImporter.class)
.importDirectory(dir).as(GenericArchive.class), root, filter));
return this;
}
}
代码示例来源:origin: org.apache.tomee/ziplock
private Builder add(final Archive<?> webArchive, final File dir, final String root) {
if (dir == null || !dir.exists()) {
return this;
}
final KnownResourcesFilter filter = new KnownResourcesFilter(dir, root, this.filter);
filter.update(
webArchive.merge(
ShrinkWrap.create(GenericArchive.class).as(ExplodedImporter.class)
.importDirectory(dir).as(GenericArchive.class), root, filter));
return this;
}
}
内容来源于网络,如有侵权,请联系作者删除!