code: def _command(self, event, command, *args, **kwargs):
          
          self._assert_transition(event)
          self.trigger('pre_%s' % event, **kwargs)
          self._execute_command(command, *args)
          self.trigger('post_%s' % event, **kwargs)
docs: Context state controller.
  
          Check whether the transition is possible or not, it executes it and
          triggers the Hooks with the pre_* and post_* events.
  
          @param event: (str) event generated by the command.
          @param command: (virDomain.method) state transition to impose.
          @raise: RuntimeError.