$getProperty method

  1. @override
$Value? $getProperty(
  1. Runtime runtime,
  2. String identifier
)
override

Get a property by identifier on this instance

Implementation

@override
$Value? $getProperty(Runtime runtime, String identifier) {
  switch (identifier) {
    case 'pattern':
      return $RegExp.wrap($value.pattern);

    case 'groupNames':
      return $Iterable.wrap($value.groupNames.map((e) => $String(e)));

    case 'namedGroup':
      return $Function(__namedGroup.call);
  }
  return _superclass.$getProperty(runtime, identifier);
}