public class ConstraintBasedAndroidNativeTargetConfigurationMatcher extends Object implements AndroidNativeTargetConfigurationMatcher
It keeps a mapping that provides a list of constraint values for a given CPU type. When a request is made, it uses the constraints for the given CPU and checks whether the platform of the target matches the constraints.
Constructor and Description |
---|
ConstraintBasedAndroidNativeTargetConfigurationMatcher(ConfigurationRuleRegistry configurationRuleRegistry,
com.google.common.collect.ImmutableMap<TargetCpuType,NamedPlatform> targetCpuTypeToConstraints) |
Modifier and Type | Method and Description |
---|---|
ConfigurationRuleRegistry |
getConfigurationRuleRegistry() |
boolean |
nativeTargetConfigurationMatchesCpuType(BuildTarget buildTarget,
TargetCpuType targetCpuType) |
public ConstraintBasedAndroidNativeTargetConfigurationMatcher(ConfigurationRuleRegistry configurationRuleRegistry, com.google.common.collect.ImmutableMap<TargetCpuType,NamedPlatform> targetCpuTypeToConstraints)
public boolean nativeTargetConfigurationMatchesCpuType(BuildTarget buildTarget, TargetCpuType targetCpuType)
nativeTargetConfigurationMatchesCpuType
in interface AndroidNativeTargetConfigurationMatcher
true
when platform in configuration of the target matches the given CPU type.public ConfigurationRuleRegistry getConfigurationRuleRegistry()