Register deferred field.

@param  \Closure  $resolver
@param  string  $path
@return mixed
516549
public function defer(Closure $resolver, string $path)
    {
        if ($data = Arr::get($this->result, "data.{$path}")) {
            return $data;
        }

        if ($this->isDeferred($path) || ! $this->acceptFurtherDeferring) {
            return $this->resolve($resolver, $path);
        }

        $this->deferred[$path] = $resolver;
    }
964565
public function isStored($path, $filter, $resolver = null)
    {
        return $this->getResolver($filter, $resolver)->isStored($path, $filter);
    }
356959
public static function register($path)
	{
		self::$_path = $path;
		self::addPath($path);

		if ($loaders = spl_autoload_functions())
			array_map('spl_autoload_unregister', $loaders);
		else
			$loaders = function_exists('__autoload') ? array('__autoload') : array();

		array_unshift($loaders, array(__CLASS__, 'load'));
		array_map('spl_autoload_register', $loaders);
	}
1077618
public static function register($path = null)
    {
        self::$_path = $path ? $path : dirname(__FILE__);

        return spl_autoload_register([__CLASS__, 'load'], true, true);
    }
835041
public function registerPath($path, $highPriority = true)
    {
        if ($highPriority) {
            array_unshift($this->paths, $path);
        } else {
            array_push($this->paths, $path);
        }
        return $this;
    }
49381
public function generateUrl($path, $filter, array $runtimeConfig = [], $resolver = null)
    {
        $params = [
            'path' => ltrim($path, '/'),
            'filter' => $filter,
        ];

        if ($resolver) {
            $params['resolver'] = $resolver;
        }

        if (empty($runtimeConfig)) {
            $filterUrl = $this->router->generate('liip_imagine_filter', $params, UrlGeneratorInterface::ABSOLUTE_URL);
        } else {
            $params['filters'] = $runtimeConfig;
            $params['hash'] = $this->signer->sign($path, $runtimeConfig);

            $filterUrl = $this->router->generate('liip_imagine_filter_runtime', $params, UrlGeneratorInterface::ABSOLUTE_URL);
        }

        return $filterUrl;
    }
1025062
public function PrependExternal ($path = '', $async = FALSE, $defer = FALSE, $doNotMinify = FALSE) {
		return $this->Prepend($path, $async, $defer, $doNotMinify, TRUE);
	}
239596
protected function _resolve()
    {
        if (!$this->_deferred) {
            return;
        }
        $data = $this->_deferred;

        $instance = $data['instance'];
        $this->_not = $data['not'];
        $boolean = $instance->resolve();
        $data['description'] = $instance->description();
        $data['backtrace'] = $instance->backtrace();
        $this->_log($boolean, $data);

        $this->_deferred = null;
    }
1080854
public function get($path, callable $handler): RouterInterface
    {
        $ruler = $this->createRuler('GET', $path);
        return $this->addRuler($ruler, $handler);
    }
1278553
public function attach(EntryNameResolverInterface $resolver, $priority = self::DEFAULT_PRIORITY)
    {
        $this->resolvers->insert(
            [
                'instance' => $resolver,

            ],
            $priority
        );

        return $this;
    }
325209
public function option($path, callable $handler): RouterInterface
    {
        $ruler = $this->createRuler('OPTION', $path);
        return $this->addRuler($ruler, $handler);
    }
189148
protected function addRequiredForSecretField(ValidatorResolver $resolver, $field, $hidden)
    {
        $resolver->sometimes($field, 'required', function ($input) use ($hidden) {
            return $input->$hidden == 'yes';
        });
    }
1065621
public function registerBladeEngine($resolver)
    {
        $me = $this;
        $app = $this->container;

        // The Compiler engine requires an instance of the CompilerInterface, which in
        // this case will be the Blade compiler, so we'll first create the compiler
        // instance to pass into the engine so it can compile the views properly.
        $this->container->singleton('blade.compiler', function($app) use ($me)
        {
            $cache = $me->cachePath;

            return new BladeCompiler($app['files'], $cache);
        });

        $resolver->register('blade', function() use ($app)
        {
            return new CompilerEngine($app['blade.compiler'], $app['files']);
        });
    }
468130
public function registerBladeEngine($resolver)
    {
        // The Compiler engine requires an instance of the CompilerInterface, which in
        // this case will be the Blade compiler, so we'll first create the compiler
        // instance to pass into the engine so it can compile the views properly.
        $this->plugin->singleton('blade.compiler', function () {
            return new BladeCompiler(
                $this->plugin['files'], $this->plugin['config']['view.compiled']
            );
        });

        $resolver->register('blade', function () {
            return new CompilerEngine($this->plugin['blade.compiler']);
        });
    }
662403
public function registerRawRouting(array $routes, PackageResolver $resolver)
    {
        foreach ($routes as $key => &$route) {
            // Package
            if (isset($route['package'])) {
                if (!isset($route['pattern'])) {
                    throw new \InvalidArgumentException(sprintf('Route need pattern: %s', print_r($route, true)));
                }

                if (!$resolver->exists($route['package'])) {
                    throw new \InvalidArgumentException(sprintf(
                        'Package %s not exists when register routing: %s.',
                        $route['package'],
                        $key
                    ));
                }

                $package = $resolver->getPackage($route['package']);

                $package->loadRouting($this, $route['pattern']);

                continue;
            }

            // Simple route
            $this->addRouteByConfig($key, $route);
        }

        return $this;
    }
1043372
def get_field_resolver(
        self, field_resolver: GraphQLFieldResolver
    ) -> GraphQLFieldResolver:
        
        if self._middleware_resolvers is None:
            return field_resolver
        if field_resolver not in self._cached_resolvers:
            self._cached_resolvers[field_resolver] = reduce(
                lambda chained_fns, next_fn: partial(next_fn, chained_fns),
                self._middleware_resolvers,
                field_resolver,
            )
        return self._cached_resolvers[field_resolver]
642299
public function resolve($path, $filter, $resolver = null)
    {
        if (false !== mb_strpos($path, '/../') || 0 === mb_strpos($path, '../')) {
            throw new NotFoundHttpException(sprintf("Source image was searched with '%s' outside of the defined root path", $path));
        }

        $preEvent = new CacheResolveEvent($path, $filter);
        $this->dispatcher->dispatch(ImagineEvents::PRE_RESOLVE, $preEvent);

        $url = $this->getResolver($preEvent->getFilter(), $resolver)->resolve($preEvent->getPath(), $preEvent->getFilter());

        $postEvent = new CacheResolveEvent($preEvent->getPath(), $preEvent->getFilter(), $url);
        $this->dispatcher->dispatch(ImagineEvents::POST_RESOLVE, $postEvent);

        return $postEvent->getUrl();
    }