Configures a {@link ViewTransitionBuilder} per the Cascade's Type.

@param builder
@param config Contains context about the view being configured.
10170
@Override
    public void transit(ViewTransitionBuilder builder, ViewTransitionBuilder.ViewGroupTransitionConfig config) {
        float cascadeLength = cascadeEnd - mCascadeStart;
        float minEffectLength = mTransitionEnd - cascadeEnd;
        float fraction = cascadeLength / (config.total - 1);
        float rangeStart = mCascadeStart + (mReverse ? config.total - 1 - config.getIndex() : config.getIndex()) * fraction;
        float rangeEnd;
        switch (type) {
            case STAGGERED:
                rangeEnd = rangeStart + minEffectLength;
                break;
            case RUN_TO_THE_END:
                rangeEnd = mTransitionEnd;
                break;
            case SEQUENTIAL:
                rangeEnd = rangeStart + fraction;
                if (rangeEnd > mTransitionEnd) {
                    rangeEnd = mTransitionEnd;
                }
                break;
            default:
                throw new IllegalArgumentException();
        }

        builder.range(interpolator.getInterpolation(rangeStart), interpolator.getInterpolation(rangeEnd));
    }
299310
public void registerTransition(Automaton source, Automaton destiny) {
        source.parent = this;
        destiny.parent = this;
        ArrayList<Transition> r = possibleTransitions.get(source);
        if (r == null) {
            r = new ArrayList<Transition>();
        }
        r.add(new Transition(destiny));
        possibleTransitions.put(source, r);
    }
486749
public void resolveBuilderGen() {
        if (getBean().isMutable()) {
            if (!getBean().isBuilderScopeVisible() && !getBean().isBeanStyleLightOrMinimal()) {
                return;  // no builder
            }
        }
        if (isDerived()) {
            builderGen = BuilderGen.NoBuilderGen.INSTANCE;
        } else {
            BuilderGen builder = config.getBuilderGenerators().get(getFieldTypeRaw());
            if (builder != null) {
                builderGen = builder;
            } else {
                builderGen = new BuilderGen.SimpleBuilderGen();
            }
        }
    }
385252
function Builder (config) {
  if (!(config instanceof Config)) {
    config = new Config(config)
  }
  this.config = config
  // TODO: check for root.val
  if (!this.config.native.root) {
    // TODO: simplify this set
    this.config.native.set({
      root: {
        val: process.cwd()
      }
    })
  }
}
181299
private function configureSlideShow(ContainerBuilder $container, $config)
    {
        $registry = $container->getDefinition('ekyna_cms.slide_show.registry');

        $container->setParameter('ekyna_cms.slide_show.static', $config['static']);
        $container->setParameter('ekyna_cms.slide_show.themes', $config['themes']);

        $types = $config['types'];

        if (!isset($types['default'])) {
            $types['default'] = [
                'class'   => Type\DefaultType::class,
                'js_path' => 'ekyna-cms/slide-show/type/default',
                'label'   => 'ekyna_cms.slide.type.default.label',
                'config'  => [],
            ];
        }
        if (!isset($types['hero'])) {
            $types['hero'] = [
                'class'   => Type\HeroType::class,
                'js_path' => 'ekyna-cms/slide-show/type/hero',
                'label'   => 'ekyna_cms.slide.type.hero.label',
                'config'  => [],
            ];
        }

        foreach ($types as $name => $c) {
            $class = $c['class'];
            if (class_exists($class)) {
                $id = "ekyna_cms.slide_show.type.{$name}";
                $definition = new Definition($class, []);
                $container->setDefinition($id, $definition);
            } elseif ($container->hasDefinition($class)) {
                $id = $class;
                $definition = $container->getDefinition($class);
                $class = $definition->getClass();
            } else {
                throw new \InvalidArgumentException("Unexpected slide show type '$class'.");
            }

            if (is_subclass_of($class, Type\AbstractType::class)) {
                $definition->addMethodCall('setMediaRepository', [new Reference('ekyna_media.media.repository')]);
                $definition->addMethodCall('setMediaGenerator', [new Reference('ekyna_media.generator')]);
            }

            $definition->addMethodCall('configure', [
                $name,
                $c['label'],
                $c['js_path'],
                isset($c['config']) ? $c['config'] : [],
            ]);

            $registry->addMethodCall('register', [new Reference($id)]);
        }
    }
142731
@Override
  public DurationFormatterFactory setPeriodBuilder(PeriodBuilder builder) {
    if (builder != this.builder) {
      this.builder = builder;
      reset();
    }
    return this;
  }
487414
private void buildNewInstanceMethodForBuilder( MethodSpec.Builder newInstanceMethodBuilder ) {
        newInstanceMethodBuilder.addStatement( "return new $T(builderDeserializer.deserializeInline(reader, ctx, params, null, null, null, bufferedProperties).build(), bufferedProperties)",
                parameterizedName( Instance.class, beanInfo.getType() ) );
    }
168108
public void addTransition(QName name, ElementSelector<T> target) {
        buildState().addTransition(new ElementEqualsConstraint(name), 
                                   target.buildState());
    }
922864
private void fireTransitionStart(Transition transition) {
        if (mTransitionListener != null && transition != null) {
            mTransitionListener.onTransitionStart(transition);
        }
    }
1205392
public RedGBuilder<T> withDefaultValueStrategy(final DefaultValueStrategy strategy) {
        if (instance == null) {
            throw new IllegalStateException("Using the builder after build() was called is not allowed!");
        }
        instance.setDefaultValueStrategy(strategy);
        return this;
    }
1309575
public static KnowledgeBuilderConfiguration newKnowledgeBuilderConfiguration(Properties properties,
                                                                                 ClassLoader... classLoaders) {
        return FactoryServiceHolder.factoryService.newKnowledgeBuilderConfiguration( properties, classLoaders );
    }
755466
@Override
    public <T> RegistrationAnnotatedBindingBuilder<T> register(Class<T> type) {
        return new RegistrationBindingBuilderImpl<>(binder, type);
    }
716229
protected void configureLimits(final T builder) {
        final Integer maxInboundMessageSize = this.properties.getMaxInboundMessageSize();
        if (maxInboundMessageSize != null) {
            builder.maxInboundMessageSize(maxInboundMessageSize);
        }
    }
1243099
@Nonnull
	public static LAction actionFrom(Consumer<LActionBuilder> buildingFunction) {
		LActionBuilder builder = new LActionBuilder();
		buildingFunction.accept(builder);
		return builder.build();
	}
67439
public void setBuilder(Release languageVersion) throws CoreException
	{
		addBuilder(getProject(), ICoreConstants.BUILDER_ID, LANGUAGE_VERSION_ARGUMENT_KEY, languageVersion.toString());
	}
964366
@Nonnull
	public static LLongToCharFunction longToCharFunctionFrom(Consumer<LLongToCharFunctionBuilder> buildingFunction) {
		LLongToCharFunctionBuilder builder = new LLongToCharFunctionBuilder();
		buildingFunction.accept(builder);
		return builder.build();
	}
96876
public void setTerminalConfiguration(final DeviceControllerTerminalConfiguration config)
			throws IOException {

		if (config == null) {
			throw new RuntimeException("null-config is not allowed!");
		}
		final DeviceControllerChannel channel = config.getChannel();
		if (channel == null) {
			throw new RuntimeException("null-channel is not allowed. For devices "
					+ "knowing just one wiper Channel.A is mandatory for "
					+ "parameter 'channel'");
		}

		byte memAddr = config.getChannel().getTerminalControllAddress();

		// read current configuration from device
		int tcon = read(memAddr);

		// modify configuration
		tcon = setBit(tcon, channel.getHardwareConfigControlBit(),
				config.isChannelEnabled());
		tcon = setBit(tcon, channel.getTerminalAConnectControlBit(),
				config.isPinAEnabled());
		tcon = setBit(tcon, channel.getWiperConnectControlBit(),
				config.isPinWEnabled());
		tcon = setBit(tcon, channel.getTerminalBConnectControlBit(),
				config.isPinBEnabled());

		// write new configuration to device
		write(memAddr, tcon);

	}