Java Code Examples for org.hibernate.boot.registry.selector.internal.StrategySelectorImpl#registerStrategyImplementor()

The following examples show how to use org.hibernate.boot.registry.selector.internal.StrategySelectorImpl#registerStrategyImplementor() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: QuarkusStrategySelectorBuilder.java    From quarkus with Apache License 2.0 5 votes vote down vote up
@SuppressWarnings("unchecked")
private static <T> void applyFromStrategyRegistration(
        StrategySelectorImpl strategySelector,
        StrategyRegistration<T> strategyRegistration) {
    for (String name : strategyRegistration.getSelectorNames()) {
        strategySelector.registerStrategyImplementor(
                strategyRegistration.getStrategyRole(),
                name,
                strategyRegistration.getStrategyImplementation());
    }
}
 
Example 2
Source File: QuarkusStrategySelectorBuilder.java    From quarkus with Apache License 2.0 5 votes vote down vote up
private static void addTransactionCoordinatorBuilders(StrategySelectorImpl strategySelector) {
    strategySelector.registerStrategyImplementor(
            TransactionCoordinatorBuilder.class,
            JdbcResourceLocalTransactionCoordinatorBuilderImpl.SHORT_NAME,
            JdbcResourceLocalTransactionCoordinatorBuilderImpl.class);
    strategySelector.registerStrategyImplementor(
            TransactionCoordinatorBuilder.class,
            JtaTransactionCoordinatorBuilderImpl.SHORT_NAME,
            JtaTransactionCoordinatorBuilderImpl.class);
}
 
Example 3
Source File: QuarkusStrategySelectorBuilder.java    From quarkus with Apache License 2.0 5 votes vote down vote up
private static void addMultiTableBulkIdStrategies(StrategySelectorImpl strategySelector) {
    strategySelector.registerStrategyImplementor(
            MultiTableBulkIdStrategy.class,
            PersistentTableBulkIdStrategy.SHORT_NAME,
            PersistentTableBulkIdStrategy.class);
    strategySelector.registerStrategyImplementor(
            MultiTableBulkIdStrategy.class,
            GlobalTemporaryTableBulkIdStrategy.SHORT_NAME,
            GlobalTemporaryTableBulkIdStrategy.class);
    strategySelector.registerStrategyImplementor(
            MultiTableBulkIdStrategy.class,
            LocalTemporaryTableBulkIdStrategy.SHORT_NAME,
            LocalTemporaryTableBulkIdStrategy.class);
}
 
Example 4
Source File: QuarkusStrategySelectorBuilder.java    From quarkus with Apache License 2.0 5 votes vote down vote up
private static void addImplicitNamingStrategies(StrategySelectorImpl strategySelector) {
    strategySelector.registerStrategyImplementor(
            ImplicitNamingStrategy.class,
            "default",
            ImplicitNamingStrategyJpaCompliantImpl.class);
    strategySelector.registerStrategyImplementor(
            ImplicitNamingStrategy.class,
            "jpa",
            ImplicitNamingStrategyJpaCompliantImpl.class);
    strategySelector.registerStrategyImplementor(
            ImplicitNamingStrategy.class,
            "component-path",
            ImplicitNamingStrategyComponentPathImpl.class);
}
 
Example 5
Source File: QuarkusStrategySelectorBuilder.java    From quarkus with Apache License 2.0 5 votes vote down vote up
private static void addCacheKeysFactories(StrategySelectorImpl strategySelector) {
    strategySelector.registerStrategyImplementor(
            CacheKeysFactory.class,
            DefaultCacheKeysFactory.SHORT_NAME,
            DefaultCacheKeysFactory.class);
    strategySelector.registerStrategyImplementor(
            CacheKeysFactory.class,
            SimpleCacheKeysFactory.SHORT_NAME,
            SimpleCacheKeysFactory.class);
}