Checks if a widget exists

@param $name

@return bool
332564
public function widgetExist($name)
    {
        $name = strtolower($name);

        return isset($this->dataStore[0][$name]) ? $this->dataStore[0][$name] : false;
    }
721938
public function has($name)
    {
        $tid = $this->getTid($name);
        if (!isset($this->_containers[$tid])) {
            return false;
        }
        return $this->_containers[$tid]->has($name);
    }
1330385
public function exists($name)
    {
        if (isset($this->extraTemplates[$name])) {
            return true;
        }

        return $this->base->exists($name);
    }
1076959
public function has(string $name): bool
    {
        $name = $this->getDefinitiveName($name);

        return isset($this->instances[$name]);
    }
688702
static public function widget($name=null)
	{
	    if ($name = static::findClass($name, 'widget')) {
	        $id = 'widget' . ($name ? '.' . $name : '');
	        if (!static::has($id)) {
	            static::setShared($id, function () use ($name) {
	                if ($name instanceof \Wslim\View\Widget) {
	                    return $name::instance();
	                } else {
	                    return new $name;
	                }
	            });
	        }
	        return static::get($id);
	    }
	    return null;
	}
155455
public function exists($name): bool
    {
        $filename = $this->getFilename($name);
        if ($filename === false) {
            return false;
        }

        return true;
    }
558497
public function exists($name)
    {
        if ($name instanceof Template) {
            return true;
        }

        $loader = $this->environment->getLoader();

        if ($loader instanceof ExistsLoaderInterface || method_exists($loader, 'exists')) {
            return $loader->exists((string) $name);
        }

        try {
            // cast possible TemplateReferenceInterface to string because the
            // EngineInterface supports them but LoaderInterface does not
            $loader->getSourceContext((string) $name)->getCode();
        } catch (LoaderError $e) {
            return false;
        }

        return true;
    }
1250251
public function has(string $name) : bool
    {
        try {
            $result = $this->configCommand($name);
        } catch (RuntimeException $exception) {
            return false;
        }

        return $result->isSuccessful();
    }
213367
public function has($name)
    {
        $path = explode('.', $name);
        $key = array_shift($path);

        if ($this->checkCache($key)) {
            return $path ? $this->cache[$key]->has($path) : true;
        }

        return false;
    }
455923
public function has($name): bool
    {
        $this->readTimes++;

        $key = $this->getCacheKey($name);

        return wincache_ucache_exists($key);
    }
80003
public function isExists($name)
    {
        try {
            $this->getQueueId($name);
            $result = true;
        } catch (RuntimeException $e) {
            $result = false;
        }

        return $result;
    }
167097
public function has(string $name): bool
    {
        foreach ($this->elements as $element) {
            if ($element instanceof NamedInterface && $element->getName() == $name) {
                return true;
            }
        }

        return false;
    }
189269
public function has($name): bool
    {
        try {
            $this->container->get($name);

            return true;
        } catch (\Exception $e) {
            return false;
        }
    }
83379
public function exists($name)
	{
	    $name = $this->normalizeServiceName($name);
	    return $this->getCommandManager()->hasListeners($name);
	}
28815
public function exists(string $name): bool
    {
        if (isset($this->cache[$name])) {
            return true;
        }

        try {
            $this->findTemplate($name);
        } catch (\InvalidArgumentException $e) {
            return false;
        }

        return true;
    }
100096
public function exists($name)
    {
        $suffix = '.twig';
        $endsWithSuffix = strtolower(substr($name, -\strlen($suffix))) === $suffix;

        return !$endsWithSuffix;
    }
591065
public function hasWidget($widget)
    {
        if ($widget instanceof Model) {
            $widget = $widget->id;
        }

        return $this->widgets()->where('widget_id', $widget)->exists();
    }