ScaleRangeDisplayFilter.withScaleRange constructor
Creates a new ScaleRangeDisplayFilter with the specified name, where clause, and scale range.
Parameters:
name
— A descriptive name for this display filter.whereClause
— A SQL expression that defines which features are rendered.minScale
— The minimum scale at which this display filter is applied. If ArcGISMapViewController.scale or Viewpoint.targetScale is less than or equal this value, the DisplayFilter will be applied. This value should be greater than maxScale. A value of 0 indicates this display filter is applied without an upper limit.maxScale
— The maximum scale at which this display filter is applied. If ArcGISMapViewController.scale or Viewpoint.targetScale is greater than or equal this value, the DisplayFilter will be applied. This value should be less than minScale. A value of 0 indicates this display filter is applied without a lower limit.
Implementation
factory ScaleRangeDisplayFilter.withScaleRange({
required String name,
required String whereClause,
required double minScale,
required double maxScale,
}) {
_initializeArcGISEnvironmentIfNeeded();
final coreName = _CString(name);
final coreWhereClause = _CString(whereClause);
final handle = _withThrowingErrorHandler((errorHandler) {
return runtimecore.RT_ScaleRangeDisplayFilter_createWithScaleRange(
coreName.bytes,
coreWhereClause.bytes,
minScale,
maxScale,
errorHandler,
);
});
return DisplayFilter._instanceCache.instanceWith(handle);
}