original_string: public function dispatch($event_name, Event $event)
      {
          $dir = $this->events_dir.$event_name.'/';
  
          if (!file_exists($dir)) {
              mkdir($dir, 0755, true);
          }
  
          $event = serialize($event);
          file_put_contents($dir.md5($event).'.meta', $event);
      }
code: public function dispatch($event_name, Event $event)
      {
          $dir = $this->events_dir.$event_name.'/';
  
          if (!file_exists($dir)) {
              mkdir($dir, 0755, true);
          }
  
          $event = serialize($event);
          file_put_contents($dir.md5($event).'.meta', $event);
      }
code_tokens: public function dispatch ( $ event_name , Event $ event ) { $ dir = $ this -> events_dir . $ event_name . '/' ; if ( ! file_exists ( $ dir ) ) { mkdir ( $ dir , 0755 , true ) ; } $ event = serialize ( $ event ) ; file_put_contents ( $ dir . md5 ( $ event ) . '.meta' , $ event ) ; }
docstring: Store the event and dispatch it later.
  
  @param string $event_name
  @param Event $event
docstring_tokens: Store the event and dispatch it later .