ManualDisplayFilterDefinition.withFilters constructor
- {required DisplayFilter? activeFilter,
- required List<
DisplayFilter> availableFilters}
Creates a new ManualDisplayFilterDefinition with the specified active and available filters.
Parameters:
activeFilter
— A display filter from ManualDisplayFilterDefinition.availableFilters to apply.availableFilters
— The collection of display filters that can be applied.
Implementation
factory ManualDisplayFilterDefinition.withFilters(
{required DisplayFilter? activeFilter,
required List<DisplayFilter> availableFilters}) {
_initializeArcGISEnvironmentIfNeeded();
final coreAvailableFilters =
availableFilters.toMutableArray(valueType: _ElementType.displayFilter);
final handle = _withThrowingErrorHandler((errorHandler) {
return runtimecore.RT_ManualDisplayFilterDefinition_createWithFilters(
activeFilter?._handle ?? ffi.nullptr,
coreAvailableFilters._handle,
errorHandler);
});
final ManualDisplayFilterDefinition object =
ManualDisplayFilterDefinition._withHandle(handle);
object._activeFilter.cache(activeFilter);
object._availableFilters.value.setCache(availableFilters);
return object;
}