Put the bindings to the associated module.
177866
public void contributeToModule() {
		final GuiceModuleAccess module = this.module.get();
		if (!this.removableBindings.isEmpty()) {
			// Ok, we are broking the Java secutiry manager.
			// But it's for having something working!
			try {
				final Field field = module.getClass().getDeclaredField("bindings"); //$NON-NLS-1$
				final boolean accessible = field.isAccessible();
				try {
					field.setAccessible(true);
					final Collection<?> hiddenBindings = (Collection<?>) field.get(module);
					hiddenBindings.removeAll(this.removableBindings);
				} finally {
					field.setAccessible(accessible);
				}
			} catch (Exception exception) {
				throw new IllegalStateException(exception);
			}
		}
		module.addAll(this.bindings);
	}
158355
def add_module(self, module):
        
        if module in self._modules:
            raise KeyError("module already added to this engine")
        ffi.lib.LLVMPY_AddModule(self, module)
        module._owned = True
        self._modules.add(module)
389813
public function reactivateModules()
    {
        foreach ($this->modules as $module) {
            $moduleProperties = $this->parseModuleJson($module->getDirectory());
            $version = $moduleProperties->module->version;

            $this->activateModule($moduleProperties->module->namespace, true);
            $module->activate($version, $version);
        }
    }
496780
protected function registerBindings()
    {
        $binding = config('binding')?: [];

        foreach($binding as $contract => $implementation) {
            $this->bind($contract, $implementation);
        }
    }
929082
def add_module(self, module):
        '''
        
        '''
        for key, value in module.__dict__.iteritems():
            if key[0:2] != '__':
                self.__setattr__(attr=key, value=value)
1017885
def _bind(self, args, kwds):
    """"""
    bindings = dict(kwds)
    for i, arg in enumerate(args):
      bindings[i + 1] = arg
    used = {}
    ancestor = self.ancestor
    if isinstance(ancestor, ParameterizedThing):
      ancestor = ancestor.resolve(bindings, used)
    filters = self.filters
    if filters is not None:
      filters = filters.resolve(bindings, used)
    unused = []
    for i in xrange(1, 1 + len(args)):
      if i not in used:
        unused.append(i)
    if unused:
      raise datastore_errors.BadArgumentError(
          'Positional arguments %s were given but not used.' %
          ', '.join(str(i) for i in unused))
    return self.__class__(kind=self.kind, ancestor=ancestor,
                          filters=filters, orders=self.orders,
                          app=self.app, namespace=self.namespace,
                          default_options=self.default_options,
                          projection=self.projection, group_by=self.group_by)
628167
def bind_collection_to_model_cls(cls):
        
        cls.Collection = type('{0}.Collection'.format(cls.__name__),
                              (cls.Collection,),
                              {'value_type': cls})
        cls.Collection.__module__ = cls.__module__
701738
public function addModule($module) {
        $this->registerModule($module);
        if (is_object($module)) $module = $module->name;
        $this->userModules[] = $module;
    }
1274570
def load_modules(self):
        """"""
        if self.INTERFACES_MODULE is None:
            raise NotImplementedError("A module containing interfaces modules "
                                      "should be setup in INTERFACES_MODULE !")
        else:
            for module, permission in self.modules.items():
                i = getattr(self.INTERFACES_MODULE,
                            module).Interface(self, permission)
                self.interfaces[module] = i
576850
public void add(Binding binding, boolean override) {
		final Set<Binding> moduleBindings = this.module.get().getBindings();
		final Binding otherBinding = findBinding(moduleBindings, binding);
		if (!override) {
			if (otherBinding != null) {
				throw new IllegalArgumentException(MessageFormat.format(
						"Forbidden override of {0} by {1}.", //$NON-NLS-1$
						otherBinding, binding));
			}
		} else if (otherBinding != null) {
			this.removableBindings.add(otherBinding);
		}
		if (!this.bindings.add(binding)) {
			throw new IllegalArgumentException(
					MessageFormat.format("Duplicate binding for {0} in {1}", binding.getKey(), this.name)); //$NON-NLS-1$
		}
	}
1261471
def bind(cls, app, *paths, methods=None, name=None, view=None):
        """"""
        # Register self in admin
        if view is None:
            app.ps.admin.register(cls)
            if not paths:
                paths = ('%s/%s' % (app.ps.admin.cfg.prefix, name or cls.name),)
            cls.url = paths[0]
        return super(AdminHandler, cls).bind(app, *paths, methods=methods, name=name, view=view)
477867
public static void addSupport(AbstractModule module) {
        module.bindInstance(SQLCodegenModule.ENTITYPATH_TYPE, RelationalPathSpatial.class);
        registerTypes(module.get(Configuration.class));
        registerTypes(module.get(TypeMappings.class));
        addImports(module);
    }
1000260
def bind(self, environment):
        """"""
        rv = object.__new__(self.__class__)
        rv.__dict__.update(self.__dict__)
        rv.environment = environment
        return rv
1158795
public void setModule(JSModule module) {
    // An input may only belong to one module.
    checkArgument(module == null || this.module == null || this.module == module);
    this.module = module;
  }
985954
def save(self, *module_names):
        """"""
        for modname in module_names:
            self._saved[modname] = sys.modules.get(modname, None)
580038
def addDataModels(self, mods):
        '''
        
        '''
        # Load all the universal properties
        for _, mdef in mods:
            for univname, _, _ in mdef.get('univs', ()):
                self.addUnivName(univname)

        # Load all the forms
        for _, mdef in mods:
            for formname, formopts, propdefs in mdef.get('forms', ()):

                self.formnames.add(formname)
                self.propnames.add(formname)

                for univname in self.univnames:
                    full = f'{formname}{univname}'
                    self.propnames.add(full)

                for propname, _, _ in propdefs:
                    full = f'{formname}:{propname}'
                    self.propnames.add(full)
881307
function() {

     	var modules = this.modules;
     	for(var i = 0 ; i < modules.length ; i++) {
		  	this.addModuleToList(modules[i]);
     	}

     	// Make the layer a drag drop target
     	if(!this.ddTarget) {
       	this.ddTarget = new YAHOO.util.DDTarget(this.layer.el, "module");
       	this.ddTarget._layer = this.layer;
     	}
 	}