fix calendar css, take 2. (#213)
[openemr.git] / interface / modules / zend_modules / library / Zend / Log / ProcessorPluginManager.php
blob0e2cae2b7b12e75ddf5b9726a219728ef0e11160
1 <?php
2 /**
3 * Zend Framework (http://framework.zend.com/)
5 * @link http://github.com/zendframework/zf2 for the canonical source repository
6 * @copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
7 * @license http://framework.zend.com/license/new-bsd New BSD License
8 */
10 namespace Zend\Log;
12 use Zend\ServiceManager\AbstractPluginManager;
14 class ProcessorPluginManager extends AbstractPluginManager
16 /**
17 * Default set of processors
19 * @var array
21 protected $invokableClasses = array(
22 'backtrace' => 'Zend\Log\Processor\Backtrace',
23 'referenceid' => 'Zend\Log\Processor\ReferenceId',
24 'requestid' => 'Zend\Log\Processor\RequestId',
27 /**
28 * Allow many processors of the same type
30 * @var bool
32 protected $shareByDefault = false;
34 /**
35 * Validate the plugin
37 * Checks that the processor loaded is an instance of Processor\ProcessorInterface.
39 * @param mixed $plugin
40 * @return void
41 * @throws Exception\InvalidArgumentException if invalid
43 public function validatePlugin($plugin)
45 if ($plugin instanceof Processor\ProcessorInterface) {
46 // we're okay
47 return;
50 throw new Exception\InvalidArgumentException(sprintf(
51 'Plugin of type %s is invalid; must implement %s\Processor\ProcessorInterface',
52 (is_object($plugin) ? get_class($plugin) : gettype($plugin)),
53 __NAMESPACE__
54 ));