use of org.jboss.galleon.repo.RepositoryArtifactInstaller in project galleon by wildfly.
the class LegacyGalleon1FeaturePackInstaller method install.
@Override
public void install(Universe<?> universe, FeaturePackLocation.FPID fpid, Path fpZip) throws ProvisioningException {
final LegacyGalleon1Universe mvnUni = (LegacyGalleon1Universe) universe;
final ChannelSpec channel = fpid.getChannel();
final LegacyGalleon1Producer producer = mvnUni.getProducer(channel.getProducer());
// make sure the channel exists
producer.getChannel(channel.getName());
if (!(mvnUni.artifactResolver instanceof RepositoryArtifactInstaller)) {
throw new ProvisioningException(mvnUni.artifactResolver.getClass().getName() + " is not an instance of " + LegacyGalleon1RepositoryManager.class.getName());
}
((RepositoryArtifactInstaller) mvnUni.artifactResolver).install(LegacyGalleon1Universe.toMavenCoords(fpid.getLocation()), fpZip);
}
Aggregations