Return dependencies for given variable.

        It have to be register first.
176411
def visit_Name(self, node):
        
        if node.id in self.naming:
            return self.naming[node.id]
        elif node.id in self.global_declarations:
            return [frozenset([self.global_declarations[node.id]])]
        elif isinstance(node.ctx, ast.Param):
            deps = [frozenset()]
            self.naming[node.id] = deps
            return deps
        else:
            raise PythranInternalError("Variable '{}' use before assignment"
                                       "".format(node.id))
659272
def add_dependency(self, value):
        """"""
        if value.name in self.dependencies:
            self.dependencies[value.name.lower()].append(value)
        else:
            self.dependencies[value.name.lower()] = [ value ]
682694
def depends_on(self, dependency):
        
        packages = self.package_info()
        return [package for package in packages if dependency in package.get("requires", "")]
601540
def we_depend_on_them(decls):
        """"""
        to_be_included = set()
        for decl in decls:
            to_be_included.update(dependency_info_t.i_depend_on_them(decl))
        return to_be_included
191338
def _get_dependencies_of(name, location=None):
    '''
    
    '''
    if not location:
        detailed_dap_list = get_installed_daps_detailed()
        if name not in detailed_dap_list:
            return _get_api_dependencies_of(name)
        location = detailed_dap_list[name][0]['location']

    meta = '{d}/meta/{dap}.yaml'.format(d=location, dap=name)
    try:
        data = yaml.load(open(meta), Loader=Loader)
    except IOError:
        return []
    return data.get('dependencies', [])
18210
function getDependencies(jsSource) {
  const lines = jsSource.split('\n');
  const dependencies = {
    ol: pkg.version
  };
  for (let i = 0, ii = lines.length; i < ii; ++i) {
    const line = lines[i];
    const importMatch = line.match(importRegEx);
    if (importMatch) {
      const imp = importMatch[1];
      if (!imp.startsWith('ol/') && imp != 'ol') {
        const parts = imp.split('/');
        let dep;
        if (imp.startsWith('@')) {
          dep = parts.slice(0, 2).join('/');
        } else {
          dep = parts[0];
        }
        if (dep in pkg.devDependencies) {
          dependencies[dep] = pkg.devDependencies[dep];
        }
      }
    }
  }
  return dependencies;
}
797727
def dependencies(self):
        
        result = []
        dependencies = javabridge.get_collection_wrapper(
            javabridge.call(self.jobject, "getDependencies", "()Ljava/util/List;"))
        for dependency in dependencies:
            result.append(Dependency(dependency))
        return result
515194
def variables(
            self,
            name=None,
            function=None,
            decl_type=None,
            header_dir=None,
            header_file=None,
            recursive=None,
            allow_empty=None):

        """"""
        return (
            self._find_multiple(
                self._impl_matchers[
                    scopedef_t.variable],
                name=name,
                function=function,
                decl_type=decl_type,
                header_dir=header_dir,
                header_file=header_file,
                recursive=recursive,
                allow_empty=allow_empty)
        )
960032
public function getVariable($variable) {
		
		if(true === isset($this -> variables[$variable])) {
			return $this -> variables[$variable];
		}
	}
1362838
def _get_dependencies_from_cache(ireq):
    
    if os.environ.get("PASSA_IGNORE_LOCAL_CACHE"):
        return
    if ireq.editable:
        return
    try:
        deps = DEPENDENCY_CACHE[ireq]
        pyrq = REQUIRES_PYTHON_CACHE[ireq]
    except KeyError:
        return

    # Preserving sanity: Run through the cache and make sure every entry if
    # valid. If this fails, something is wrong with the cache. Drop it.
    try:
        packaging.specifiers.SpecifierSet(pyrq)
        ireq_name = packaging.utils.canonicalize_name(ireq.name)
        if any(_is_cache_broken(line, ireq_name) for line in deps):
            broken = True
        else:
            broken = False
    except Exception:
        broken = True

    if broken:
        print("dropping broken cache for {0}".format(ireq.name))
        del DEPENDENCY_CACHE[ireq]
        del REQUIRES_PYTHON_CACHE[ireq]
        return

    return deps, pyrq
581889
def register_variable_compilation(self, path, compilation_cbk, listclass):
        
        self.compilations_variable[path] = {
            'callback':  compilation_cbk,
            'listclass': listclass
        }
1177827
def dependencies(self):
        
        result = []
        iterator = javabridge.iterate_java(javabridge.call(self.jobject, "dependencies", "()Ljava/util/Iterator;"))
        for c in iterator:
            result.append(Capability(c))
        return result
576543
def _get_all_dependencies_of(name, deps=set(), force=False):
    ''''''
    first_deps = _get_api_dependencies_of(name, force=force)
    for dep in first_deps:
        dep = _strip_version_from_dependency(dep)
        if dep in deps:
            continue
        # we do the following not to resolve the dependencies of already installed daps
        if dap in get_installed_daps():
            continue
        deps |= _get_all_dependencies_of(dep, deps)
    return deps | set([name])
373344
def get_dependencies():
    """"""

    dependencies = []

    # Numpy
    dep_attrs = {
        "name": "numpy",
        "min_version": "1.1.0",
        "description": "required",
    }
    try:
        import numpy
        dep_attrs["version"] = numpy.version.version
    except ImportError:
        dep_attrs["version"] = None
    dependencies.append(dep_attrs)

    # wxPython
    dep_attrs = {
        "name": "wxPython",
        "min_version": "2.8.10.1",
        "description": "required",
    }
    try:
        import wx
        dep_attrs["version"] = wx.version()
    except ImportError:
        dep_attrs["version"] = None
    dependencies.append(dep_attrs)

    # Matplotlib
    dep_attrs = {
        "name": "matplotlib",
        "min_version": "1.1.1",
        "description": "required",
    }
    try:
        import matplotlib
        dep_attrs["version"] = matplotlib._version.get_versions()["version"]
    except ImportError:
        dep_attrs["version"] = None
    except AttributeError:
        # May happen in old matplotlib versions
        dep_attrs["version"] = matplotlib.__version__

    dependencies.append(dep_attrs)

    # Pycairo
    dep_attrs = {
        "name": "pycairo",
        "min_version": "1.8.8",
        "description": "required",
    }
    try:
        import cairo
        dep_attrs["version"] = cairo.version
    except ImportError:
        dep_attrs["version"] = None
    dependencies.append(dep_attrs)

    # Python GnuPG
    dep_attrs = {
        "name": "python-gnupg",
        "min_version": "0.3.0",
        "description": "for opening own files without approval",
    }
    try:
        import gnupg
        dep_attrs["version"] = gnupg.__version__
    except ImportError:
        dep_attrs["version"] = None
    dependencies.append(dep_attrs)

    # xlrd
    dep_attrs = {
        "name": "xlrd",
        "min_version": "0.9.2",
        "description": "for loading Excel files",
    }
    try:
        import xlrd
        dep_attrs["version"] = xlrd.__VERSION__
    except ImportError:
        dep_attrs["version"] = None
    dependencies.append(dep_attrs)

    # xlwt
    dep_attrs = {
        "name": "xlwt",
        "min_version": "0.7.2",
        "description": "for saving Excel files",
    }
    try:
        import xlwt
        dep_attrs["version"] = xlwt.__VERSION__
    except ImportError:
        dep_attrs["version"] = None
    dependencies.append(dep_attrs)

    # Jedi
    dep_attrs = {
        "name": "jedi",
        "min_version": "0.8.0",
        "description": "for tab completion and context help in the entry line",
    }
    try:
        import jedi
        dep_attrs["version"] = jedi.__version__
    except ImportError:
        dep_attrs["version"] = None
    dependencies.append(dep_attrs)

    # pyrsvg
    dep_attrs = {
        "name": "pyrsvg",
        "min_version": "2.32",
        "description": "for displaying SVG files in cells",
    }
    try:
        import rsvg
        dep_attrs["version"] = True
    except ImportError:
        dep_attrs["version"] = None
    dependencies.append(dep_attrs)

    # pyenchant
    dep_attrs = {
        "name": "pyenchant",
        "min_version": "1.6.6",
        "description": "for spell checking",
    }
    try:
        import enchant
        dep_attrs["version"] = enchant.__version__
    except ImportError:
        dep_attrs["version"] = None
    dependencies.append(dep_attrs)

    return dependencies
72040
public void addDependentVariables(Variable ... depVars) {
		ArrayList<Variable> newDepVars = new ArrayList<Variable>();
		for (Variable v : this.dependentVariables) newDepVars.add(v);
		for (Variable v : depVars) newDepVars.add(v);
		this.dependentVariables = newDepVars.toArray(new Variable[newDepVars.size()]);
	}
298240
function fetchDependentPackages( $dependencyType, &$failedList )
    {
        $packages = array();
        $provides = $this->Parameters['dependencies'][$dependencyType];

        if ( $provides != null )
        {
            foreach ( $provides as $provide )
            {
                // fetch only dependent packages, not package items.
                if ( $provide['type'] == 'ezpackage' )
                {
                    // TODO: Add fetching from URL (not here ?)
                    $package = $this->fetch( $provide['name'] );

                    if ( !$package )
                    {
                        $failedList[] = $provide['name'];
                        continue;
                    }
                    $packages[] =& $package;
                }
            }
        }
        return $packages;
    }
570492
def add(modname, features, required_version, installed_version=None,
        optional=False):
    """"""
    global DEPENDENCIES
    for dependency in DEPENDENCIES:
        if dependency.modname == modname:
            raise ValueError("Dependency has already been registered: %s"\
                             % modname)
    DEPENDENCIES += [Dependency(modname, features, required_version,
                                installed_version, optional)]