-
- All Implemented Interfaces:
-
org.gradle.api.Named
,org.gradle.api.attributes.HasAttributes
,org.jetbrains.kotlin.gradle.plugin.KotlinTarget
public abstract class KotlinAndroidTarget extends AbstractKotlinTarget
-
-
Field Summary
Fields Modifier and Type Field Description private final String
disambiguationClassifier
private final KotlinPlatformType
platformType
private final NamedDomainObjectContainer<out KotlinJvmAndroidCompilation>
compilations
private List<String>
publishLibraryVariants
private Boolean
publishLibraryVariantsGroupedByFlavor
private final String
targetName
private final String
defaultConfigurationName
private final Boolean
useDisambiguationClassifierAsSourceSetNamePrefix
private final String
overrideDisambiguationClassifierOnIdeImport
private final String
apiElementsConfigurationName
private final String
runtimeElementsConfigurationName
private final String
artifactsTaskName
private final Boolean
publishable
private final Set<SoftwareComponent>
components
private final KotlinTargetPreset<out KotlinTarget>
preset
private final Project
project
-
Constructor Summary
Constructors Constructor Description KotlinAndroidTarget(String targetName, Project project)
-
Method Summary
Modifier and Type Method Description final String
getDisambiguationClassifier()
KotlinPlatformType
getPlatformType()
NamedDomainObjectContainer<out KotlinJvmAndroidCompilation>
getCompilations()
final List<String>
getPublishLibraryVariants()
Names of the Android library variants that should be published from the target's project within the default publications which are set up if the maven-publish
Gradle plugin is applied.final Unit
setPublishLibraryVariants(List<String> publishLibraryVariants)
final Boolean
getPublishLibraryVariantsGroupedByFlavor()
If true, a publication will be created per merged product flavor, with the build types used as classifiers for the artifacts published within each publication. final Unit
setPublishLibraryVariantsGroupedByFlavor(Boolean publishLibraryVariantsGroupedByFlavor)
If true, a publication will be created per merged product flavor, with the build types used as classifiers for the artifacts published within each publication. final String
getTargetName()
final Unit
publishLibraryVariants(String names)
Add Android library variant names to publishLibraryVariants. final Unit
publishAllLibraryVariants()
Set up all of the Android library variants to be published from this target's project within the default publications, which are set up if the maven-publish
Gradle plugin is applied.-
Methods inherited from class org.jetbrains.kotlin.gradle.plugin.mpp.AbstractKotlinTarget
getApiElementsConfigurationName, getArtifactsTaskName, getAttributes, getComponents, getDefaultConfigurationName, getOverrideDisambiguationClassifierOnIdeImport, getPreset, getProject, getPublishable, getRuntimeElementsConfigurationName, getUseDisambiguationClassifierAsSourceSetNamePrefix, mavenPublication, toString
-
Methods inherited from class org.jetbrains.kotlin.gradle.plugin.KotlinTarget
attributes, attributes, getName, mavenPublication
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
KotlinAndroidTarget
KotlinAndroidTarget(String targetName, Project project)
-
-
Method Detail
-
getDisambiguationClassifier
final String getDisambiguationClassifier()
-
getPlatformType
KotlinPlatformType getPlatformType()
-
getCompilations
NamedDomainObjectContainer<out KotlinJvmAndroidCompilation> getCompilations()
-
getPublishLibraryVariants
final List<String> getPublishLibraryVariants()
Names of the Android library variants that should be published from the target's project within the default publications which are set up if the
maven-publish
Gradle plugin is applied.Item examples:
'release' (in case no product flavors were defined)
'fooRelease' (for the release build type of a flavor 'foo')
'fooBarRelease' (for the release build type multi-dimensional flavors 'foo' and 'bar').
If set to null, which can also be done with publishAllLibraryVariants, all library variants will be published, but not test or application variants.
-
setPublishLibraryVariants
final Unit setPublishLibraryVariants(List<String> publishLibraryVariants)
-
getPublishLibraryVariantsGroupedByFlavor
final Boolean getPublishLibraryVariantsGroupedByFlavor()
If true, a publication will be created per merged product flavor, with the build types used as classifiers for the artifacts published within each publication. If set to false, each Android variant will have a separate publication.
-
setPublishLibraryVariantsGroupedByFlavor
final Unit setPublishLibraryVariantsGroupedByFlavor(Boolean publishLibraryVariantsGroupedByFlavor)
If true, a publication will be created per merged product flavor, with the build types used as classifiers for the artifacts published within each publication. If set to false, each Android variant will have a separate publication.
-
getTargetName
final String getTargetName()
-
publishLibraryVariants
final Unit publishLibraryVariants(String names)
Add Android library variant names to publishLibraryVariants.
-
publishAllLibraryVariants
final Unit publishAllLibraryVariants()
Set up all of the Android library variants to be published from this target's project within the default publications, which are set up if the
maven-publish
Gradle plugin is applied. This overrides the variants chosen with publishLibraryVariants
-
-
-
-