LmRuntimeBuilder { public LmRuntimeBuilder extractorResolver(ResourceResolver loader) { Objects.requireNonNull(loader); this.extractorResolverFactory = () -> loader; return this; } LmRuntimeBuilder(); LmRuntimeBuilder adapter(LinkEtlAdapter adapter); LmRuntimeBuilder withTargetRuntime(ServerRuntime targetRuntime); LmRuntimeBuilder withTokenManager(ITokenManager tokenManager); LmRuntimeBuilder withConnector(String id, Connector connector); LmRuntimeBuilder withConnectorFactory(Class<C> connectorType,
                                                                       IConnectorFactory<C> factory); LmRuntimeBuilder withConnectorFactory(Class<C> connectorType,
                                                                       Class<? extends IConnectorFactory<C>> factoryType); LmRuntimeBuilder withConnectorFromTarget(); LmRuntimeBuilder withExtractorFactory(String extractorType, Class<? extends IExtractorFactory<?>> factoryType); LmRuntimeBuilder withExtractorFactory(String extractorType, IExtractorFactory<?> factory); LmRuntimeBuilder valueConverter(Class<?> javaType, ValueConverter converter); LmRuntimeBuilder extractorResolver(ResourceResolver loader); LmRuntimeBuilder extractorModelsRoot(File rootDir); LmRuntimeBuilder extractorModelsRoot(URL baseUrl); LmRuntime build(); static final String START_TOKEN_VAR; static final String END_TOKEN_VAR; }
@Test public void testBuild_NoTargetRuntime() { LmRuntimeBuilder builder = new LmRuntimeBuilder() .extractorResolver(mock(ResourceResolver.class)); assertThrows(IllegalStateException.class, builder::build); }