Bind.

@param propertiesPath
the properties path
@param clazz
the clazz
@throws BindingException
the binding exception
542853
public static synchronized void bind(String propertiesPath, Class clazz) throws BindingException
    {
        if (em == null)
        {
            em = PersistenceService.getEM(emf, propertiesPath, clazz.getName());
        }
        onBind(clazz);
    }
1106026
public void setBindings( Collection<VarBindingDef> bindings)
    {
    bindings_ = new HashMap<VarDef,VarBindingDef>();
    properties_ = new PropertySet();
    
    if( bindings != null)
      {
      for( VarBindingDef binding : bindings)
        {
        add( binding);
        }
      }
    }
1286090
public void setClassPath(Path classpath) {
        pathComponents.removeAllElements();
        if (classpath != null) {
            Path actualClasspath = classpath.concatSystemClasspath("ignore");
            String[] pathElements = actualClasspath.list();
            for (int i = 0; i < pathElements.length; ++i) {
                try {
                    addPathElement(pathElements[i]);
                } catch (BuildException e) {
                    // ignore path elements which are invalid
                    // relative to the project
                }
            }
        }
    }
740779
public void register( Object source, String path )
	{
		unregister();
		
		dataBinding = Binder.bind( source, path ).mode( Mode.OneWay ).to( adapter ).activate();
	}
1347050
public static void compile(Class<?> cls, File outputPath) {
        if (outputPath == null) {
            throw new NullPointerException("Param 'outputPath' is null.");
        }
        if (!outputPath.isDirectory()) {
            throw new RuntimeException("Param 'outputPath' value should be a path directory. path=" + outputPath);
        }

    }
840872
private static void loadProperty(String filePath)
    {
        try (InputStream propertyStream = Thread.currentThread().getContextClassLoader().getResourceAsStream(
                filePath);
                Reader propertyReader = new InputStreamReader(propertyStream, DEFAULT_CHARSET);)
        {
            Properties properties = new Properties();
            properties.load(propertyReader);
            propertiesMap.put(filePath, properties);
        }
        catch (Exception ex)
        {
            String errorPattern = "Property file load failed. Skip load. : PropertyFile={0}";
            logger.warn(MessageFormat.format(errorPattern, filePath), ex);
        }
    }
1020944
public function configure(Binder $binder, string $projectPath = null)
    {
        $this->environment->registerErrorHandler($projectPath);
        $this->environment->registerExceptionHandler($projectPath);
        $binder->setEnvironment($this->environment->name())
                ->bind(Environment::class)->toInstance($this->environment);
        if (file_exists($this->propertiesFile($projectPath))) {
            $binder->bindPropertiesFromFile(
                    $this->propertiesFile($projectPath),
                    $this->environment->name()
            );
        }

        $binder->bindConstant('stubbles.project.path')->to($projectPath);
        foreach ($this->buildPathes($projectPath) as $name => $value) {
            $binder->bindConstant($name)->to($value);
        }
    }
1202325
@Override
    public void bind(DynamicConfiguration config) {
      Injections.addBinding(
              Injections.newFactoryBinder(this).to(type).in(Singleton.class),
              config);
      Injections.addBinding(
              Injections.newBinder(this).to(ValueFactoryProvider.class),
              config);
    }
423112
@Override
	public void bind(Name name, Object obj) throws NamingException
    {
        if (name.isEmpty())
            throw new InvalidNameException("Cannot bind empty name");

        // Extract components that belong to this namespace
        String nm = name.toString();

        // Find object in internal hash table
        if (bindings.get(nm) != null)
        {
            throw new NameAlreadyBoundException("Use rebind to override");
        }

        // Add object to internal hash table
        bindings.put(nm, obj);
    }
1113463
function (binding, subpath) {
      var args = Util.resolveArgs(
        arguments,
        function (x) { return x instanceof Binding ? 'binding' : null; }, '?subpath'
      );
      addDeletion(this, args.binding || this._binding, asArrayPath(args.subpath));
      return this;
    }
785656
protected final DefinitionBinder bind(String beanName, Class<?> clazz) {
    Assert.notNull(beanName);
    Assert.notNull(clazz);
    return config.bind(beanName, clazz);
  }
273753
public static Properties loadClasspath(String path) throws IOException {
		InputStream input = PropUtils.class.getClassLoader().getResourceAsStream(path);
		Properties prop = null;
		try {
			prop = load(input);
		} finally {
			IOUtils.close(input);
		}
		return prop;
	}
1311226
private static void reportMultipleBindingAmbiguity(Set<URL> binderPathSet) {
        if (isAmbiguousStaticLoggerBinderPathSet(binderPathSet)) {
            Util.report("Class path contains multiple SLF4J bindings.");
            for (URL path : binderPathSet) {
                Util.report("Found binding in [" + path + "]");
            }
            Util.report("See " + MULTIPLE_BINDINGS_URL + " for an explanation.");
        }
    }
199359
protected Binder findBinderByPropertyName(Class parentObjectType, String propertyName) {
        PropertyNameKey key = new PropertyNameKey(parentObjectType, propertyName);
        Binder binder = (Binder)propertyNameBinders.get(key);
        if (binder == null) {
            // if no direct match was found try to find a match in any super classes
            final Map potentialMatchingBinders = new HashMap();
            for (Iterator i = propertyNameBinders.entrySet().iterator(); i.hasNext();) {
                Map.Entry entry = (Map.Entry)i.next();
                if (((PropertyNameKey)entry.getKey()).getPropertyName().equals(propertyName)) {
                    potentialMatchingBinders.put(((PropertyNameKey)entry.getKey()).getParentObjectType(),
                            entry.getValue());
                }
            }
            binder = (Binder) ClassUtils.getValueFromMapForClass(parentObjectType, potentialMatchingBinders);
            if (binder != null) {
                // remember the lookup so it doesn't have to be discovered again
                registerBinderForPropertyName(parentObjectType, propertyName, binder);
            }
        }
        return binder;
    }
241271
public static void rebindCasConfigurationProperties(final ConfigurationPropertiesBindingPostProcessor binder,
                                                        final ApplicationContext applicationContext) {

        val map = applicationContext.getBeansOfType(CasConfigurationProperties.class);
        val name = map.keySet().iterator().next();
        LOGGER.trace("Reloading CAS configuration via [{}]", name);
        val e = applicationContext.getBean(name);
        binder.postProcessBeforeInitialization(e, name);
        val bean = applicationContext.getAutowireCapableBeanFactory().initializeBean(e, name);
        applicationContext.getAutowireCapableBeanFactory().autowireBean(bean);
        LOGGER.debug("Reloaded CAS configuration [{}]", name);
    }
1018414
protected void loadConfig(Properties props, String path, InputStream is) {
		// load properties into a Properties object
		try {
			props.load(is);
		} catch (IOException e) {
			throw new BundlingProcessException("Unable to load jawr configuration at " + path + ".", e);
		}
	}
1246286
@Override
	public Response bindApplication( String applicationName, String externalExportPrefix, String boundApp ) {

		this.logger.fine( "Binding " + boundApp  + " to the " + externalExportPrefix + " prefix in application " + applicationName + "." );
		String lang = lang( this.manager );
		Response response;
		try {
			ManagedApplication ma = this.manager.applicationMngr().findManagedApplicationByName( applicationName );
			if( ma == null ) {
				response = handleError(
						Status.NOT_FOUND,
						new RestError( REST_INEXISTING, application( applicationName )),
						lang ).build();

			} else {
				this.manager.applicationMngr().bindOrUnbindApplication( ma, externalExportPrefix, boundApp, true );
				response = Response.ok().build();
			}

		} catch( UnauthorizedActionException | IOException e ) {
			response = RestServicesUtils.handleError(
					Status.FORBIDDEN,
					new RestError( ErrorCode.REST_UNDETAILED_ERROR, e ),
					lang ).build();
		}

		return response;
	}