def register(action):
if isinstance(action, str):<EOL><INDENT>Action.register(Action(action))<EOL><DEDENT>elif isinstance(action, Action):<EOL><INDENT>Action.registered.add(action)<EOL><DEDENT>else:<EOL><INDENT>for a in action:<EOL><INDENT>Action.register(a)<EOL><DEDENT><DEDENT>
Action registration is used to support generating lists of
        permitted actions from a permission set and an object pattern.
        Only registered actions will be returned by such queries.