Records final class
Minn\Runtime\Records · public/minn/src/Minn/Runtime/Records.php · 133 lines
Posts, terms and comments as WordPress hands them to plugins: found by id (or the one being read), made from a row or an object, and given back as the object, an associative array (ARRAY_A) or a list (ARRAY_N); and whether a value is a list of errors.
Used by 55 (show)
Public
| static | post(mixed $post = NULL, mixed $output = 'OBJECT', mixed $filter = 'raw'): mixed# | A post (get_post): the one being read when none is named; a post object as given; one made from a row, an object or an array with an ID; else by id, a copy of the cached one (what one plugin changes is not what the next reader sees). Then put in the context asked for. |
| static | term(mixed $term, mixed $taxonomy = '', mixed $output = 'OBJECT', mixed $filter = 'raw'): mixed# | A term (get_term): an error for none or an unknown taxonomy; a term object as given, one made from an object, else by id (null when there is none). get_term and get_{taxonomy} filter the raw term, told its own taxonomy; then it is put in the context asked for, on a copy of a term the caller handed in. |
| static | comment(mixed $comment = NULL, mixed $output = 'OBJECT'): mixed# | A comment (get_comment): the one being read for any empty id; a comment object as given; one made from an object with a comment_ID; else by id, its fields text as the database hands them over (null when there is none). Then get_comment. |
| static | isError(mixed $thing): bool# | Whether a value is a list of errors (is_wp_error); one that is is told to is_wp_error_instance. |
Internals 2
Private and protected methods: how the class does its work. Not a contract; they change whenever the code is tidied.
Nothing matches.