Beispiel #1
0
 /**
  * Sets the archive stub.
  *
  * @param Builder $builder The archive builder.
  *
  * @return BuildCommand For method chaining.
  */
 private function setStub(Builder $builder)
 {
     $event = new PreStubEvent($builder, $this->createStub());
     $this->dispatcher->dispatch(Events::PRE_BUILD_STUB, $event);
     if (null !== $event->getStub()) {
         $builder->setStub($event->getStub());
     }
     $this->dispatcher->dispatch(Events::POST_BUILD_STUB, new PostStubEvent($builder, $event->getStub()));
     return $this;
 }