Adds the module and its dependencies to the result list.
168355
def _process_module_order(parser, module, i, result):
    """"""
    #Some code might decide to use the fortpy module methods for general
    #development, ignore it since we know it will be present in the end.
    if module == "fortpy" or module == "fpy_auxiliary":
        return

    #See if the parser has alread loaded this module.
    if module not in parser.modules:
        parser.load_dependency(module, True, True, False)

    #It is possible that the parser couldn't find it, if so
    #we can't get a self-consistent ordering.
    if module in parser.modules:
        modneeds = parser.modules[module].needs
        for modn in modneeds:
            if modn not in result:
                #Since this module depends on the other, insert the other
                #above it in the list.
                result.insert(i, modn)
            else:
                x = result.index(modn)
                if x > i:
                    #We need to move this module higher up in the food chain
                    #because it is needed sooner.
                    result.remove(modn)
                    result.insert(i, modn)

            newi = result.index(modn)
            _process_module_order(parser, modn, newi, result)
    else:
        raise ValueError("unable to find module {}.".format(module))
195262
def add_dependency(self,my_dep):
        
        if self.dependency_layer is None:
            self.dependency_layer = Cdependencies()
            self.root.append(self.dependency_layer.get_node())
        self.dependency_layer.add_dependency(my_dep)
36149
private void installModules(final Node node, final NetworkContext context, final Handler<AsyncResult<Void>> doneHandler) {
    List<ModuleContext> modules = new ArrayList<>();
    for (ComponentContext<?> component : context.components()) {
      if (component.isModule()) {
        modules.add(component.asModule());
      }
    }

    final CountingCompletionHandler<Void> counter = new CountingCompletionHandler<Void>(modules.size()).setHandler(doneHandler);
    for (ModuleContext module : modules) {
      installModule(node, module, counter);
    }
  }
588551
def create_result(self, imports, module_name, import_from, meta, val, dividers):
        """"""
        options = {"imports": imports, "module_name": module_name, "import_from": import_from}
        return ImportLine.FieldSpec(formatter=MergedOptionStringFormatter).normalise(meta, options)
366437
def add_pom_dependencies( pom_path, scopes=['compile'] )
      if Naether.platform == 'java'
        @resolver.addDependencies( pom_path, scopes )
      else
        list = Naether::Java.convert_to_java_list( scopes )
        @resolver._invoke( 'addDependencies', 'Ljava.lang.String;Ljava.util.List;', pom_path, list )
      end
    end
792132
def add_result(self, result):
        
        for handler in self._handlers:
            handler(result)
        if self._successful and result.status not in _successful_results:
            self._successful = False
1141421
def _setup(module, extras):
    """"""

    Qt.__binding__ = module.__name__

    for name in list(_common_members) + extras:
        try:
            submodule = _import_sub_module(
                module, name)
        except ImportError:
            try:
                # For extra modules like sip and shiboken that may not be
                # children of the binding.
                submodule = __import__(name)
            except ImportError:
                continue

        setattr(Qt, "_" + name, submodule)

        if name not in extras:
            # Store reference to original binding,
            # but don't store speciality modules
            # such as uic or QtUiTools
            setattr(Qt, name, _new_module(name))
255274
public void addDependencies( String pomPath, List<String> scopes ) throws ProjectException {
        addDependencies( new Project( pomPath), scopes );
    }
1322611
def add(self, calc, module, package=None):
        
        super(Calculations, self).add(calc, module, package)
        # only update layer info if it is missing!
        if calc not in self.layer:
            # copy calc source parameters to :attr:`Layer.layer`
            self.layer[calc] = {'module': module, 'package': package}
        # instantiate the calc object
        self.objects[calc] = self.sources[calc]()
        # register calc and dependencies in registry
        calc_src_obj = self.objects[calc]
        meta = [getattr(calc_src_obj, m) for m in self.reg.meta_names]
        self.reg.register(calc_src_obj.calcs, *meta)
889716
protected void addModulesList(Collection<ModuleElement> modules, Content tbody) {
        boolean altColor = true;
        for (ModuleElement mdle : modules) {
            if (!mdle.isUnnamed()) {
                Content moduleLinkContent = getModuleLink(mdle, new StringContent(mdle.getQualifiedName().toString()));
                Content thModule = HtmlTree.TH_ROW_SCOPE(HtmlStyle.colFirst, moduleLinkContent);
                HtmlTree tdSummary = new HtmlTree(HtmlTag.TD);
                tdSummary.addStyle(HtmlStyle.colLast);
                addSummaryComment(mdle, tdSummary);
                HtmlTree tr = HtmlTree.TR(thModule);
                tr.addContent(tdSummary);
                tr.addStyle(altColor ? HtmlStyle.altColor : HtmlStyle.rowColor);
                tbody.addContent(tr);
            }
            altColor = !altColor;
        }
    }
905903
public void addDependency(final Dependency dependency) {
        if(dependency != null && !dependencies.contains(dependency)){
            this.dependencies.add(dependency);
        }
    }
473504
private static void addDependency(List<Dependency> dependencies, MavenCoordinates requiredArtifact, Constants.ArtifactType type, String scope) {
		Dependency dependency = new Dependency();
		dependency.setGroupId(requiredArtifact.getGroupId());
		dependency.setArtifactId(requiredArtifact.getArtifactId());
		dependency.setVersion(requiredArtifact.getVersion());

		if(scope!=null){
			dependency.setScope(scope);
		}
		if (type != null) {
			dependency.setType(type.getType());
		}
		dependencies.add(dependency);
	}
174998
public void addReads(Instrumentation instrumentation, JavaModule module) {
        DISPATCHER.addReads(instrumentation, this.module, module.unwrap());
    }
959786
public static List<DbDependency> getAllDbDependencies(final DbModule module) {
        final List<DbDependency> dependencies = new ArrayList<DbDependency>();
        dependencies.addAll(module.getDependencies());

        for(final DbModule submodule: module.getSubmodules()){
            dependencies.addAll(getAllDbDependencies(submodule));
        }

        return dependencies;
    }
886798
function addModuleIdsToModuleWrapper(
  module: Module,
  idForPath: ({path: string}) => number,
): string {
  const {dependencies, file} = module;
  const {code} = file;

  // calling `idForPath` on the module itself first gives us a lower module id
  // for the file itself than for its dependencies. That reflects their order
  // in the bundle.
  const fileId = idForPath(file);

  const paramsToAdd = [fileId];

  if (dependencies.length) {
    paramsToAdd.push(dependencies.map(idForPath));
  }

  return addParamsToDefineCall(code, ...paramsToAdd);
}
924104
def order_module_dependencies(modules, parser):
    """"""
    result = []        
    for modk in modules:
        if modk not in result:
            result.append(modk)

    #We also need to look up the dependencies of each of these modules
    recursed = list(result)
    for i in range(len(result)):
        module = result[i]
        _process_module_order(parser, module, i, recursed)

    return recursed
270020
def list_dependencies(self, module, result):
        """"""
        if result is None:
            result = {}
        #We will try at least once to load each module that we don't have
        if module not in self.modules:
            self.load_dependency(module, True, True, False)

        if module in self.modules and module not in result:
            result[module] = self.modules[module].filepath
            for depend in self.modules[module].dependencies:
                name = depend.split(".")[0].lower()
                if name not in result:
                    self.list_dependencies(name, result)

        return result