Package org.robolectric.plugins
Class DefaultSdkPicker
java.lang.Object
org.robolectric.plugins.DefaultSdkPicker
- All Implemented Interfaces:
SdkPicker
- Direct Known Subclasses:
SdkPicker
@AutoService(SdkPicker.class) @Priority(-2147483648) public class DefaultSdkPicker extends Object implements SdkPicker
Robolectric's default
SdkPicker
.-
Constructor Summary
Constructors Modifier Constructor Description protected
DefaultSdkPicker(SdkCollection sdkCollection, String enabledSdks)
DefaultSdkPicker(SdkCollection sdkCollection, Properties systemProperties)
-
Method Summary
Modifier and Type Method Description protected Set<Sdk>
configuredSdks(Config config, UsesSdk usesSdk)
protected int
decodeSdk(int value, int defaultSdk, int appMinSdk, int appTargetSdk, int appMaxSdk)
protected static Set<Sdk>
enumerateEnabledSdks(SdkCollection sdkCollection, String enabledSdksString)
protected Set<Sdk>
sdkRange(int minSdk, int maxSdk)
List<Sdk>
selectSdks(ConfigurationStrategy.Configuration configuration, UsesSdk usesSdk)
Enumerate the SDKs to be used for this test.
-
Constructor Details
-
Method Details
-
selectSdks
@Nonnull public List<Sdk> selectSdks(ConfigurationStrategy.Configuration configuration, UsesSdk usesSdk)Enumerate the SDKs to be used for this test.- Specified by:
selectSdks
in interfaceSdkPicker
- Parameters:
configuration
- a collection of configuration objects, includingConfig
usesSdk
- theUsesSdk
for the test- Returns:
- the list of candidate
Sdk
s. - Since:
- 3.9
-
enumerateEnabledSdks
@Nullable protected static Set<Sdk> enumerateEnabledSdks(SdkCollection sdkCollection, String enabledSdksString) -
configuredSdks
-
decodeSdk
protected int decodeSdk(int value, int defaultSdk, int appMinSdk, int appTargetSdk, int appMaxSdk) -
sdkRange
-