MimeWhere final class
Minn\Query\MimeWhere · public/minn/src/Minn/Query/MimeWhere.php · 36 lines
wp_post_mime_type_where as the reference writes it (probe wp-query-sql): each mime type (a list or a comma-separated string) cleaned to a pattern, a bare group or a star widened with % into a LIKE, an exact type an equality, all OR'd; an empty type or a lone wildcard means no clause.
Constants and properties
| private | WILDCARDS = array ( 0 => '', 1 => '%', 2 => '%/%', ) |
Public
| static | sql(array|string $types, string $alias = ''): string# | The clause for some mime types, against a table's column when one is named. @param string|list<string> $types
|
Internals 1
Private and protected methods: how the class does its work. Not a contract; they change whenever the code is tidied.
| private | pattern(string $type): string# | A type cleaned to group/subgroup (an empty subgroup a star), or a bare group widened to group/*. |
Nothing matches.