Markup Utils

inyoka.markup.utils

copyright:
  1. 2007-2024 by the Inyoka Team, see AUTHORS for more details.

license:

BSD, see LICENSE for more details.

class inyoka.markup.utils.ArgumentCollector(name, bases, d)
inyoka.markup.utils.debug_repr(obj)

A function that does a debug repr for an object. This is used by all the nodes, macros and parsers so that we get a debuggable ast.

inyoka.markup.utils.filter_style(css)
inyoka.markup.utils.has_key(mapping, search)
inyoka.markup.utils.join_array(array, delimiter)
inyoka.markup.utils.regex_match(pattern, string)

Match a string against a regex pattern. Works like simple_match.

inyoka.markup.utils.simple_filter(pattern, iterable, case_sensitive=True)

Filter an iterable against a pattern. The pattern is pretty simple, the only special thing is that “*” is a wildcard. The return value is an iterator, not a list.

inyoka.markup.utils.simple_match(pattern, string, case_sensitive=False)

Match a string against a pattern. Works like simple_filter.