UR::Bo...::Like(3pm)
π¦ NAME π¦
UR::BoolExpr::Template::PropertyComparison::Like β bestie, this is the little comparison class that does an SQL-ish like test. It lives in the UR::BoolExpr::Template::PropertyComparison crew, and yeah, it's from the User Contributed Perl Documentation, section 3pm. She's a Perl module, she's a baddie, she matches strings. π
π DESCRIPTION π
okay so here's the tea, and it's actually so simple:
The test value you hand in is assumed to be an SQL like value. That means the string you give it is not a plain literal, it's a pattern, and two characters are doing special main character work in there:
_β represents a one character wildcard. One char. Just one. She's not greedy, she's precise. π%β represents a 0 or more character wildcard. Could be nothing, could be everything. She contains multitudes. β¨
That SQL-ish value gets converted into a perl regular expression, and then that regex is used to match against an object's properties. That's the whole vibe check right there. πΈ
And here's the part you'd definitely ask about, bestie: if the property returns multiple values, this comparison returns true if any of those values match. Not all of them. Not the first one. Any. One hit and she's slaying. π₯
no cap, this is the entire module. short, iconic, does exactly one job and does it. π
π SEE ALSO π
ngl there's nothing extra listed on this page, so if you need more, go read the rest of the UR::BoolExpr::Template::PropertyComparison family. iykyk π«Ά
that's the whole page, bestie π this one's from the User Contributed Perl Documentation, running on perl v5.32.1, dated 2022-01-17 β mwah, drink your water, and go match some strings responsibly π§π
π¦ where this page comes from
- debian bookworm: libur-perl 0.470+ds-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu jammy: libur-perl 0.470+ds-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libur-perl 0.470+ds-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms