public abstract class RegexFlags extends Object
regex flags
to MongoDB regex options and vice versa.Modifier and Type | Method and Description |
---|---|
static int |
toRegexFlag(char c)
Lookup the MongoDB specific flags for a given character.
|
static int |
toRegexFlags(String s)
Lookup the MongoDB specific flags for a given regex option string.
|
static String |
toRegexOptions(int flags)
Lookup the MongoDB specific options from given
flags . |
public static String toRegexOptions(int flags)
flags
.flags
- the Regex flags to look up.public static int toRegexFlags(@Nullable String s)
s
- the Regex option/flag to look up. Can be null.String
is null or empty.public static int toRegexFlag(char c)
c
- the Regex option/flag to look up.IllegalArgumentException
- for unknown flagsCopyright © 2011–2021 Pivotal Software, Inc.. All rights reserved.