this.manifestMerger = manifestMerger;
}
public ManifestContents generate(ManifestContents manifestTemplate, ClassPath... classPaths) {
ReadablePartialManifest partialManifest = this.contributors.getReadablePartialManifest();
ManifestContents existingManifest = getExistingManifest(classPaths);
for (ManifestReader manifestReader : this.contributors.getManifestReaders()) {
manifestReader.readJarManifest(existingManifest);
manifestReader.readManifestTemplate(manifestTemplate);
}
for (ManifestModifier manifestModifier : this.contributors.getManifestModifiers()) {
manifestModifier.modify(existingManifest);
}
for (ManifestTemplateModifier manifestTemplateModifier : this.contributors.getManifestTemplateModifiers()) {
manifestTemplateModifier.modify(manifestTemplate);
}
analyzeEntries(classPaths, partialManifest);
for (PartialManifestModifier partialManifestModifier : this.contributors.getPartialManifestModifiers()) {
partialManifestModifier.modify(partialManifest);
}
ManifestContents contributedManifest = new SimpleManifestContents();
for (ManifestContributor manifestContributor : this.contributors.getManifestContributors()) {
manifestContributor.contribute(contributedManifest);
}
List<String> templateOnlyHeaderNames = new ArrayList<String>();