RegexValue class

Represents a regular expression type in Firestore documents.

Only databases of the Enterprise edition store this type. It is a stored value, not a query filter: the client does not compile or check the pattern.

await firestore.doc('rules/a').set(<String, Object?>{
  'match': const RegexValue('^foo', 'i'),
});
final DocumentSnapshot<Map<String, Object?>> snapshot =
    await firestore.doc('rules/a').get();
final RegexValue? match = snapshot.getRegexValue('match');

Constructors

RegexValue(String pattern, String options)
Creates a regular expression from its pattern and its options, for example RegexValue('^foo', 'i').
const

Properties

hashCode → int
The hash code for this object.
no setteroverride
options → String
The regular expression options.
final
pattern → String
The regular expression pattern.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
override