Exemple #1
0
 def __call__(self, args, parsed_globals):
     # Create an event handler for a Provider Document
     instance = self.EventHandlerClass(self)
     # Now generate all of the events for a Provider document.
     # We pass ourselves along so that we can, in turn, get passed
     # to all event handlers.
     docevents.generate_events(self.session, self)
     self.renderer.render(self.doc.getvalue())
     instance.unregister()
Exemple #2
0
 def __call__(self, args, parsed_globals):
     # Create an event handler for a Provider Document
     instance = self.EventHandlerClass(self)
     # Now generate all of the events for a Provider document.
     # We pass ourselves along so that we can, in turn, get passed
     # to all event handlers.
     docevents.generate_events(self.session, self)
     self.renderer.render(self.doc.getvalue())
     instance.unregister()
Exemple #3
0
    def __call__(self, args, parsed_globals):
        if args:
            subcommand_parser = ArgTableArgParser({}, self.subcommand_table)
            parsed, remaining = subcommand_parser.parse_known_args(args)
            if getattr(parsed, 'subcommand', None) is not None:
                return self.subcommand_table[parsed.subcommand](remaining,
                                                                parsed_globals)

        # Create an event handler for a Provider Document
        instance = self.EventHandlerClass(self)
        # Now generate all of the events for a Provider document.
        # We pass ourselves along so that we can, in turn, get passed
        # to all event handlers.
        docevents.generate_events(self.session, self)
        self.renderer.render(self.doc.getvalue())
        instance.unregister()
Exemple #4
0
    def __call__(self, args, parsed_globals):
        if args:
            subcommand_parser = ArgTableArgParser({}, self.subcommand_table)
            parsed, remaining = subcommand_parser.parse_known_args(args)
            if getattr(parsed, 'subcommand', None) is not None:
                return self.subcommand_table[parsed.subcommand](remaining,
                                                                parsed_globals)

        # Create an event handler for a Provider Document
        instance = self.EventHandlerClass(self)
        # Now generate all of the events for a Provider document.
        # We pass ourselves along so that we can, in turn, get passed
        # to all event handlers.
        docevents.generate_events(self.session, self)
        self.renderer.render(self.doc.getvalue())
        instance.unregister()