RegexFindAll constructor

RegexFindAll({
  1. @required dynamic input,
  2. @required dynamic regex,
  3. dynamic options,
})

Creates $regexFindAll operator expression

Provides regular expression (regex) pattern matching capability in aggregation expressions. The operator returns an array of documents that contains information on each match. If a match is not found, returns an empty array.

MongoDB uses Perl compatible regular expressions (i.e. “PCRE” ) version 8.41 with UTF-8 support.

  • input - The string on which you wish to apply the regex pattern. Can be a string or any valid expression that resolves to a string.
  • regex - The regex pattern to apply. Can be any valid expression that resolves to a string.
  • options - Optional. The following

Implementation

RegexFindAll({@required input, @required regex, options})
    : super('regexFindAll',
          AEObject({'input': input, 'regex': regex, 'options': options}));