GearmanBundle.php 890 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. <?php
  2. /**
  3. * Gearman Bundle for Symfony2
  4. *
  5. * For the full copyright and license information, please view the LICENSE
  6. * file that was distributed with this source code.
  7. *
  8. * Feel free to edit as you please, and have fun.
  9. *
  10. * @author Marc Morera <yuhu@mmoreram.com>
  11. */
  12. namespace Mmoreram\GearmanBundle;
  13. use Doctrine\Common\Annotations\AnnotationRegistry;
  14. use Symfony\Component\HttpKernel\Bundle\Bundle;
  15. /**
  16. * Gearman Bundle
  17. *
  18. * @since 2.3.1
  19. */
  20. class GearmanBundle extends Bundle
  21. {
  22. /**
  23. * Boots the Bundle.
  24. */
  25. public function boot()
  26. {
  27. $kernel = $this->container->get('kernel');
  28. AnnotationRegistry::registerFile($kernel
  29. ->locateResource("@GearmanBundle/Driver/Gearman/Work.php")
  30. );
  31. AnnotationRegistry::registerFile($kernel
  32. ->locateResource("@GearmanBundle/Driver/Gearman/Job.php")
  33. );
  34. }
  35. }