class ServiceBindingsBuilder {

    public void bind(String interfaceName, String className, ClassLoader classLoader) {
        ServiceBinding binding = defineIfNecessary(interfaceName, classLoader);
        if (binding.isLocked()) {
            throw new ServiceConfigurationException(interfaceName + " is locked");
        }
        binding.setImplementingClass(className);
    }

}