Package org.gradle.api.artifacts
Interface ModuleVersionSelector
-
- All Known Subinterfaces:
ClientModule,DependencyConstraint,ExternalDependency,ExternalModuleDependency,MinimalExternalModuleDependency
public interface ModuleVersionSelectorSelects a module version. If you need to change this interface, you're probably doing it wrong: it is superseded byModuleComponentSelector, so check this first, and only add methods here if it's for bridging.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.StringgetGroup()The group of the module.ModuleIdentifiergetModule()The module identifier of the component.java.lang.StringgetName()The name of the module.java.lang.StringgetVersion()The version of the module.booleanmatchesStrictly(ModuleVersionIdentifier identifier)To match strictly means that the given identifier needs to have equal group, module name and version.
-
-
-
Method Detail
-
getGroup
java.lang.String getGroup()
The group of the module.- Returns:
- module group
-
getName
java.lang.String getName()
The name of the module.- Returns:
- module name
-
getVersion
@Nullable java.lang.String getVersion()
The version of the module. May be null.- Returns:
- module version
-
matchesStrictly
boolean matchesStrictly(ModuleVersionIdentifier identifier)
To match strictly means that the given identifier needs to have equal group, module name and version. It does not smartly match dynamic versions, e.g. '1.+' selector does not strictly match '1.2' identifier.- Returns:
- if this selector matches exactly the given identifier.
-
getModule
ModuleIdentifier getModule()
The module identifier of the component. Returns the same information asgetGroup()andgetName().- Returns:
- the module identifier
- Since:
- 4.9
-
-