Return the factory defined for the named reporter

@param string $name
@return null|string|callable
13935
public function getReporterFactory($name)
    {
        $definition = $this->getReporterDefinition($name);
        if (! isset($definition['factory'])) {
            $definition['factory'] = null;
        }
        return $definition['factory'];
    }
678469
protected function makeService($name)
    {
        $config = $this->getConfig($name);

        // First we will check by the service name to see if an extension has been
        // registered specifically for that service. If it has we will call the
        // Closure and pass it the config allowing it to resolve the service.
        if (isset($this->extensions[$name])) {
            return call_user_func($this->extensions[$name], $config, $name);
        }

        $config = $this->getDbConfig($name);
        $type = $config['type'];

        // Next we will check to see if a type extension has been registered for a service type
        // and will call the factory Closure if so, which allows us to have a more generic
        // resolver for the service types themselves which applies to all services.
        if (isset($this->types[$type])) {
            return $this->types[$type]->make($name, $config);
        }

        throw new InvalidArgumentException("Unsupported service type '$type'.");
    }
10704
public function get(string $name): ApiConnector
    {
        return $this->apiFactory->createApiConnector($name, $this->options);
    }
397511
public function get(string $name)
    {
        if (isset($this->workerClassMap[$name])) {
            return $this->container->get($this->workerClassMap[$name]);
        }
        return $this->container->get($name);
    }
1113389
public function getLogger ($name) {
    if (!isset($this->logs[$name])) {
      $this->logs[$name] = $this->newLogger($name, $this->findParent($name));
    }
    return $this->logs[$name];
  }
647142
public function getLogger($name = null)
    {
        if (null === $name && !isset($this->loggers['nullLogger'])) {
            $this->createNullLogger();
            $name = 'nullLogger';
        }

        return $this->loggers[$name];
    }
1033103
public static function getLogger($name)
    {
        return Registry::hasLogger($name) ? Registry::getInstance($name) : self::createLogger($name);
    }
497175
public function plugin(string $name): \TheCMSThread\Classes\Plugin
    {
        return $this->plugins->get($name);
    }
108252
protected function get($name)
    {
        try {
            return $this->channels[$name] ?? ($this->channels[$name] = $this->resolve($name));
        } catch (\Throwable $e) {
            $logger = $this->createEmergencyLogger();

            $logger->emergency('Unable to create configured logger. Using emergency logger.', [
                    'exception' => $e,
                ]);

            return $logger;
        }
    }
747077
public function getConnector($name)
    {
        if (!$this->connector_map->hasKey($name)) {
            throw new RuntimeError(
                sprintf('Can\'t find connector with name: %s. Maybe a typo within the connections.xml?', $name)
            );
        }

        return $this->connector_map->getItem($name);
    }
1182965
private function createServiceFromDelegator(string $name, array $options = null)
    {
        // @todo: This selection is necessary only because lazy services
        // configuration currently requires an explicit Delegator definition
        if ($this->delegators[$name][0] === Proxy\LazyServiceFactory::class) {
            return $this->createServiceFromLazyServiceDelegator($name, $options);
        }

        $creationCallback = $this->delegatorCallbackCache[$name] ?? null;
        if ($creationCallback) {
            $object = $creationCallback($this->creationContext, $name, $creationCallback, $options);
            return $object;
        }

        $creationCallback = function () use ($name, $options) {
            return $this->createServiceFromFactory($name, $options);
        };

        foreach ($this->delegators[$name] as $index => $delegatorFactory) {
            if (is_string($delegatorFactory) && class_exists($delegatorFactory)) {
                $delegatorFactory = new $delegatorFactory();
                if ($delegatorFactory instanceof DelegatorFactoryInterface) {
                    $this->delegators[$name][$index] = $delegatorFactory;
                    $creationCallback = function () use ($delegatorFactory, $name, $creationCallback, $options) {
                        return $delegatorFactory($this->creationContext, $name, $creationCallback, $options);
                    };
                    continue;
                }
            }
            if (is_callable($delegatorFactory)) {
                $creationCallback = function () use ($delegatorFactory, $name, $creationCallback, $options) {
                    return $delegatorFactory($this->creationContext, $name, $creationCallback, $options);
                };
                continue;
            }
            if (is_string($delegatorFactory)) {
                throw InvalidArgumentException::fromInvalidDelegatorFactoryClass($delegatorFactory);
            }
            throw InvalidArgumentException::fromInvalidDelegatorFactoryInstance($delegatorFactory);
        }

        //cache the callback for later requests
        $this->delegatorCallbackCache[$name] = $creationCallback;
        return $creationCallback($this->creationContext, $name, $creationCallback, $options);
    }
931175
public static function create($name = 'null') {
    $is_upper = FormatterFactory::getDefaultFormatter()->getConfig('boolean_null_upper');
    $node = new NullNode();
    $node->addChild(NameNode::create($is_upper ? 'NULL' : 'null'), 'constantName');
    return $node;
  }
1026959
public static function factory($name)
    {
        $classname = get_called_class();

        if (!isset(self::$instances[$classname])) {
            self::$instances[$classname] = array();
        }

        if ($name instanceof Value) {
            $name = $name->getValue();
        }

        if (!isset(self::$instances[$classname][$name])) {
            $instance = new static($name);
            $name = $instance->getName();

            if (!isset(self::$instances[$classname][$name])) {
                self::$instances[$classname][$name] = $instance;
            }
        }

        return self::$instances[$classname][$name];
    }
730298
protected function adapterFactory(string $name): AdapterInterface
	{
		$factory = $this->adapterFactories[$name];

		return $this->adapters[$name] = $factory();
	}
1184934
public static function factory($prefix, $name = null)
    {
        $calledClass = get_called_class();

        /** @var \PhalconRest\Api\ApiCollection $collection */
        $collection = new $calledClass($prefix);

        if ($name) {
            $collection->name($name);
        }

        return $collection;
    }
670616
public static function getInstance(string $name): Base
    {
        if(!isset(static::$handlers[$name]))
        {
            throw new \RuntimeException(sprintf('GetInstance failed, %s is not found', $name));
        }
        return static::$handlers[$name];
    }
594987
public function getMethod($name)
    {
        if (parent::hasMethod($name) == false) {
            return null;
        }
        
        $moufRefMethod = new MoufReflectionMethod($this, $name);
        return $moufRefMethod;
    }