use of org.gradle.api.internal.file.collections.FileCollectionAdapter in project gradle by gradle.
the class NativeSpecVisualStudioTargetBinary method getHeaderFiles.
@Override
public FileCollection getHeaderFiles() {
Spec<LanguageSourceSet> filter = new Spec<LanguageSourceSet>() {
@Override
public boolean isSatisfiedBy(LanguageSourceSet sourceSet) {
return sourceSet instanceof HeaderExportingSourceSet;
}
};
Transformer<FileCollection, LanguageSourceSet> transform = new Transformer<FileCollection, LanguageSourceSet>() {
@Override
public FileCollection transform(LanguageSourceSet sourceSet) {
HeaderExportingSourceSet exportingSourceSet = (HeaderExportingSourceSet) sourceSet;
return exportingSourceSet.getExportedHeaders().plus(exportingSourceSet.getImplicitHeaders());
}
};
return new FileCollectionAdapter(new LanguageSourceSetCollectionAdapter(getComponentName() + " header files", binary.getInputs(), filter, transform));
}
Aggregations