Interface IvyArtifactSet
- All Superinterfaces:
Collection<IvyArtifact>, DomainObjectCollection<IvyArtifact>, DomainObjectSet<IvyArtifact>, Iterable<IvyArtifact>, Set<IvyArtifact>
A Collection of
IvyArtifacts to be included in an IvyPublication.
Being a DomainObjectSet, a IvyArtifactSet provides convenient methods for querying, filtering, and applying actions to the set of IvyArtifacts.
apply plugin: 'ivy-publish'
def publication = publishing.publications.create("my-pub", IvyPublication)
def artifacts = publication.artifacts
artifacts.matching({
it.type == "source"
}).all({
it.extension = "src.jar"
})
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionCreates and adds aIvyArtifactto the set.artifact(Object source, Action<? super IvyArtifact> config) Creates and adds aIvyArtifactto the set, which is configured by the associated action.Methods inherited from interface Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface DomainObjectCollection
all, all, whenObjectAdded, whenObjectAdded, whenObjectRemoved, whenObjectRemoved, withType, withTypeMethods inherited from interface DomainObjectSet
findAll, matching, matching, withType
-
Method Details
-
artifact
Creates and adds aIvyArtifactto the set. The semantics of this method are the same asIvyPublication.artifact(Object).- Parameters:
source- The source of the artifact content.
-
artifact
Creates and adds aIvyArtifactto the set, which is configured by the associated action. The semantics of this method are the same asIvyPublication.artifact(Object, Action).- Parameters:
source- The source of the artifact.config- An action to configure the values of the constructedIvyArtifact.
-