api / org.gradle.api.publish.maven / MavenArtifact

MavenArtifact

interface MavenArtifact : PublicationArtifact

An artifact published as part of a MavenPublication.

Functions

getClassifier

abstract fun getClassifier(): String

The classifier used to publish the artifact file. A null value (the default) indicates that this artifact will be published without a classifier.

getExtension

abstract fun getExtension(): String

The extension used to publish the artifact file, never null. For an artifact without an extension, this value will be an empty String.

setClassifier

abstract fun setClassifier(classifier: String): Unit

Sets the classifier used to publish the artifact file.

setExtension

abstract fun setExtension(extension: String): Unit

Sets the extension used to publish the artifact file.

Inherited Functions

builtBy

abstract fun builtBy(vararg tasks: Any): Unit

Registers some tasks which build this artifact.

getFile

abstract fun getFile(): File

The actual file contents to publish.