------------------------------------------------------ binding methods
10759
public static <T extends Event> HandlerRegistration bind(EventTarget target, EventType<T, ?> type,
            EventCallbackFn<T> listener) {
        return bind(target, type.name, e -> listener.onEvent(Js.cast(e)));
    }
339045
@Override
    public void onBindViewHolder(@NonNull ViewHolder holder, int position) {
        // - get element from your dataset at this position
        // - replace the contents of the view with that element
        final ViewModel model = mDataset.get(position);
        holder.setFinalStatus(model.mFinalStatus);
        holder.setRedirectStatus(model.mRedirectStatus);
        holder.setSourceId(model.mSourceId);
        holder.setSourceType(model.mSourceType);
    }
525194
public BindObject bind(Framework.Mapping<?> mapping, Map<String, String> data) {
        return bind(mapping, data, "");
    }
624442
private void bindButtonEnabling() {
        final BooleanBinding bexpr = new BooleanBinding() {

            @Override
            protected boolean computeValue() {
                return !(object().sourcePath() != null && object().sourcePath().exists() && object().sourcePath().isDirectory()
                        && object().targetPath() != null && object().targetPath().exists() && object().targetPath().isDirectory());
            }
        };

        final ChangeListener<File> cl = new ChangeListener<File>() {

            @Override
            public void changed(final ObservableValue<? extends File> observable, final File oldValue, final File newValue) {
                bexpr.invalidate();
            }
        };

        object().pSourcePath().addListener(cl);
        object().pTargetPath().addListener(cl);

        view().getStartButton().disableProperty().bind(bexpr);

        final SimpleListProperty<FileComparison> filteredListProperty = new SimpleListProperty<>(view().getTable().getItems());
        view().getExportCSV().disableProperty().bind(filteredListProperty.emptyProperty());

        final SimpleListProperty<FileComparison> listProperty = new SimpleListProperty<>(object().pLastResult());
        view().getMissing().disableProperty().bind(listProperty.emptyProperty());
        view().getDowngraded().disableProperty().bind(listProperty.emptyProperty());
        view().getNewer().disableProperty().bind(listProperty.emptyProperty());
        view().getSame().disableProperty().bind(listProperty.emptyProperty());
        view().getUpdated().disableProperty().bind(listProperty.emptyProperty());
        view().getUpgraded().disableProperty().bind(listProperty.emptyProperty());
    }
591296
private static void generateParseOnXmlAttributes(BindTypeContext context, MethodSpec.Builder methodBuilder,
			BindEntity entity) {
		BindTransform bindTransform;

		int count = 0;
		// count property to manage
		{
			// for each elements
			for (BindProperty property : entity.getCollection()) {
				if (property.xmlInfo.xmlType != XmlType.ATTRIBUTE)
					continue;

				count++;
			}
		}

		if (count > 0) {
			// @formatter:off
			methodBuilder.addCode("\n// attributes \n");
			methodBuilder.addStatement("String attributeName = null");
			// methodBuilder.addStatement("String attributeValue = null");

			methodBuilder.addStatement("int attributesCount = xmlParser.getAttributeCount();");
			methodBuilder.beginControlFlow(
					"for (int attributeIndex = 0; attributeIndex < attributesCount; attributeIndex++)");
			methodBuilder.addStatement("attributeName = xmlParser.getAttributeName(attributeIndex)");
			// methodBuilder.addStatement("attributeValue =
			// $T.unescapeXml(xmlParser.getAttributeValue(attributeIndex))",
			// StringEscapeUtils.class);
			methodBuilder.beginControlFlow("switch(attributeName)$>");

			for (BindProperty property : entity.getCollection()) {
				if (property.xmlInfo.xmlType != XmlType.ATTRIBUTE)
					continue;

				methodBuilder.addCode("case $S:\n$>", BindProperty.xmlName(property));

				bindTransform = BindTransformer.lookup(property);
				methodBuilder.addCode("// field $L (mapped by $S)\n", property.getName(),
						BindProperty.xmlName(property));
				bindTransform.generateParseOnXml(context, methodBuilder, "xmlParser",
						property.getPropertyType().getTypeName(), "instance", property);

				methodBuilder.addStatement("$<break");
			}

			methodBuilder.addCode("default:\n$>");
			methodBuilder.addStatement("$<break$<");
			methodBuilder.endControlFlow();

			methodBuilder.endControlFlow();
			// @formatter:on
		} else {
			methodBuilder.addCode("// No attributes found\n");
		}
	}
634847
private void initRegisteredBindings() {
        
        Enumeration<URL> bindingsConfiguration;
        try {
            bindingsConfiguration = ClassLoaderUtils.getClassLoader().getResources("META-INF/bindings.xml");
        } catch (IOException e) {
            throw new IllegalStateException("Error registering bindings: " + e.getMessage(), e);
        }

        registerConfigurations(bindingsConfiguration);
    }
34076
private function applyBindings()
    {
        foreach ($this->bindings as $abstract => $binding) {
            list($concrete, $shared) = $binding;

            $this->app->bind($abstract, $concrete, $shared);
        }
    }
1187315
public void bindService() {
        Log.v(TAG, "Trying to bind the service");
        Context context = this.context.get();
        isBound = false;
        if (context != null && preferredPackage != null) {
            isBound = CustomTabsClient.bindCustomTabsService(context, preferredPackage, this);
        }
        Log.v(TAG, "Bind request result: " + isBound);
    }
912509
public void bind() throws Throwable
   {
      if (name == null)
         throw new IllegalArgumentException("Name is null");

      if (obj == null)
         throw new IllegalArgumentException("Obj is null");

      if (trace)
         log.trace("Binding " + obj.getClass().getName() + " under " + name);

      Properties properties = new Properties();
      properties.setProperty(Context.PROVIDER_URL, jndiProtocol + "://" + jndiHost + ":" + jndiPort);
      Context context = new InitialContext(properties);

      try
      {
         String className = obj.getClass().getName();
         Reference ref = new Reference(className,
                                       new StringRefAddr("class", className),
                                       JndiBinder.class.getName(),
                                       null);
         ref.add(new StringRefAddr("name", name));

         objs.put(name, obj);

         Util.bind(context, name, ref);

         if (log.isDebugEnabled())
            log.debug("Bound " + obj.getClass().getName() + " under " + name);
      }
      finally
      {
         if (context != null)
         {
            try
            {
               context.close();
            }
            catch (NamingException ne)
            {
               // Ignore
            }
         }
      }
   }
62047
public void bind(Object newValue)
    {
    	if (getValue() == null)
    	{
    		setValue(newValue);
    	}	
    	else
    	{
    		setValue2(newValue);
    		setBound(true); 		
    	}
    }
935716
public void bind () {
    gfx.gl.glBindFramebuffer(GL_FRAMEBUFFER, id());
    gfx.gl.glViewport(0, 0, width(), height());
  }
1231877
private static void onBind(Class clazz)
    {

        if (((MetamodelImpl) em.getMetamodel()).getEntityMetadataMap().isEmpty())
        {

            EntityMetadata metadata = new EntityMetadata(clazz);
            metadata.setPersistenceUnit(getPersistenceUnit());

            setSchemaAndPU(clazz, metadata);

            new TableProcessor(em.getEntityManagerFactory().getProperties(),
                    ((EntityManagerFactoryImpl) em.getEntityManagerFactory()).getKunderaMetadataInstance())
                            .process(clazz, metadata);

            KunderaMetadata kunderaMetadata = ((EntityManagerFactoryImpl) em.getEntityManagerFactory())
                    .getKunderaMetadataInstance();

            new IndexProcessor(kunderaMetadata).process(clazz, metadata);

            ApplicationMetadata appMetadata = kunderaMetadata.getApplicationMetadata();

            ((MetamodelImpl) em.getMetamodel()).addEntityMetadata(clazz, metadata);
            ((MetamodelImpl) em.getMetamodel()).addEntityNameToClassMapping(clazz.getSimpleName(), clazz);
            appMetadata.getMetamodelMap().put(getPersistenceUnit(), em.getMetamodel());

            Map<String, List<String>> clazzToPuMap = new HashMap<String, List<String>>();
            List<String> persistenceUnits = new ArrayList<String>();
            persistenceUnits.add(getPersistenceUnit());
            clazzToPuMap.put(clazz.getName(), persistenceUnits);
            appMetadata.setClazzToPuMap(clazzToPuMap);
            new SchemaConfiguration(em.getEntityManagerFactory().getProperties(), kunderaMetadata, getPersistenceUnit())
                    .configure();

        }

    }
342246
public function Bind()
	{
		if ( $this->getCount() > 0)
		{
			if ( $this->getAbstractNode(0) instanceof PathExprNode )
			{
				/**
				 * @var PathExprNode $pathExpr
				 */
				$pathExpr = $this->getAbstractNode(0);
				if ( in_array( $this->_name, FuncNode::$s_aggregates ) && $this->_ns == XmlReservedNs::xQueryFunc )
				{
					$pathExpr->Unordered = true;
				}
			}
		}
		parent::Bind();
	}
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$
		}
	}
812526
protected function bind()
    {
        $variables = array();

        // Bind each field
        while ($field = $this->metadata->fetch_field()) {
            $this->columns[] = $field->name;
            $this->types[$field->name] = $field->type;
            // Note that while boundValues isn't initialised at this point,
            // later calls to $this->statement->fetch() Will populate
            // $this->boundValues later with the next result.
            $variables[] = &$this->boundValues[$field->name];
        }

        $this->bound = true;
        $this->metadata->free();

        // Buffer all results
        $this->statement->store_result();

        call_user_func_array(array($this->statement, 'bind_result'), $variables);
    }
602701
function(bindingString, data, children, callback, done) {
            container = document.createElement("div");
            container.setAttribute("data-bind", bindingString);
            container.innerHTML = children || "";

            sandbox.appendChild(container);

            ko.cleanNode(sandbox);
            ko.applyBindings(data, sandbox);

            setTimeout(callback, 50);
        }
477685
private void serializeBinds(Map<String, ParameterBindingDTO> bindValues) throws BindException
  {
    List<ColumnTypeDataPair> columns = getColumnValues(bindValues);
    List<String[]> rows = buildRows(columns);
    writeRowsToCSV(rows);
  }