Does the string match a pattern?

isMatchingFixed(x, pattern, .xname = getNameInParent(x))

isMatchingRegex(x, pattern, .xname = getNameInParent(x))

isNotMatchingFixed(x, pattern, .xname = getNameInParent(x))

isNotMatchingRegex(x, pattern, .xname = getNameInParent(x))

allAreMatchingFixed(x, pattern, .xname = getNameInParent(x))

allAreMatchingRegex(x, pattern, .xname = getNameInParent(x))

allAreNotMatchingFixed(x, pattern, .xname = getNameInParent(x))

allAreNotMatchingRegex(x, pattern, .xname = getNameInParent(x))

Arguments

x

Object.

pattern

character(1). Pattern to use for matching.

.xname

Not intended to be used directly.

Value

logical.

See also

Examples

## TRUE ==== isMatchingRegex(x = "foobar", pattern = "^f")
#> foobar #> TRUE
isNotMatchingRegex(x = "foobar", pattern = "^b")
#> foobar #> TRUE
isMatchingFixed(x = "foobar", pattern = "bar")
#> foobar #> TRUE
isNotMatchingFixed(x = "foo", pattern = "bar")
#> foo #> TRUE