Method ChooseConfiguration
ChooseConfiguration(NativeSlice<ConfigurationDescriptor>, Feature)
Selects a configuration from the given descriptors
and requestedFeatures
.
Declaration
public override Configuration ChooseConfiguration(NativeSlice<ConfigurationDescriptor> descriptors, Feature requestedFeatures)
Parameters
Type | Name | Description |
---|---|---|
Native |
descriptors | A set of Configuration |
Feature | requestedFeatures | A set of requested Features. |
Returns
Type | Description |
---|---|
Configuration | The configuration that best matches the |
Overrides
Remarks
Selection works as follows:
For each of the configuration descriptors
, compute the number of supported
Features that are present in requestedFeatures
and choose the
configuration descriptor with the highest count. rank is
used to break ties.
Exceptions
Type | Condition |
---|---|
Argument |
Thrown if |
Argument |
Thrown if |
Argument |
Thrown if |