/** * Gets the 'knp_snappy.image' service. * * This service is shared. * This method always returns the same instance of the service. * * @return \Knp\Bundle\SnappyBundle\Snappy\LoggableGenerator A Knp\Bundle\SnappyBundle\Snappy\LoggableGenerator instance. */ protected function getKnpSnappy_ImageService() { $a = new \Knp\Snappy\Image('wkhtmltoimage', array(), array()); $a->setTemporaryFolder(__DIR__ . '/snappy'); return $this->services['knp_snappy.image'] = new \Knp\Bundle\SnappyBundle\Snappy\LoggableGenerator($a, $this->get('monolog.logger.snappy', ContainerInterface::NULL_ON_INVALID_REFERENCE)); }