DisplayFilter.withWhereClause constructor

DisplayFilter.withWhereClause(
  1. {required String name,
  2. required String whereClause}
)

Creates a new DisplayFilter with the specified name and where clause.

Parameters:

  • name — A descriptive name for this display filter.
  • whereClause — A SQL expression that defines which features are rendered.

Implementation

factory DisplayFilter.withWhereClause(
    {required String name, required String whereClause}) {
  _initializeArcGISEnvironmentIfNeeded();
  final coreName = _CString(name);
  final coreWhereClause = _CString(whereClause);
  final handle = _withThrowingErrorHandler((errorHandler) {
    return runtimecore.RT_DisplayFilter_createWithWhereClause(
        coreName.bytes, coreWhereClause.bytes, errorHandler);
  });
  return DisplayFilter._instanceCache.instanceWith(handle);
}