@Test public void testBuild() { Input result = PipelineInputBuilder.newInstance() .withProvider(providerKey) .withParams(params) .withRuntimeName(RUNTIME).build(); assertNotNull(result); assertEquals(RUNTIME, result.get(RuntimeConfig.RUNTIME_NAME)); assertEquals(PROVIDER, result.get(ProviderConfig.PROVIDER_NAME)); params.forEach((name, value) -> assertEquals(value, result.get(name))); }
public Input build() { final Input input = new Input(); if (runtimeName != null) { input.put(RuntimeConfig.RUNTIME_NAME, runtimeName); } if (providerKey != null) { input.put(ProviderConfig.PROVIDER_NAME, providerKey.getId()); } if (params != null) { input.putAll(params); } return input; }
PipelineInputBuilder { public Input build() { final Input input = new Input(); if (runtimeName != null) { input.put(RuntimeConfig.RUNTIME_NAME, runtimeName); } if (providerKey != null) { input.put(ProviderConfig.PROVIDER_NAME, providerKey.getId()); } if (params != null) { input.putAll(params); } return input; } }
PipelineInputBuilder { public Input build() { final Input input = new Input(); if (runtimeName != null) { input.put(RuntimeConfig.RUNTIME_NAME, runtimeName); } if (providerKey != null) { input.put(ProviderConfig.PROVIDER_NAME, providerKey.getId()); } if (params != null) { input.putAll(params); } return input; } private  PipelineInputBuilder(); }
PipelineInputBuilder { public Input build() { final Input input = new Input(); if (runtimeName != null) { input.put(RuntimeConfig.RUNTIME_NAME, runtimeName); } if (providerKey != null) { input.put(ProviderConfig.PROVIDER_NAME, providerKey.getId()); } if (params != null) { input.putAll(params); } return input; } private  PipelineInputBuilder(); static PipelineInputBuilder newInstance(); PipelineInputBuilder withRuntimeName(final String runtimeName); PipelineInputBuilder withProvider(final ProviderKey providerKey); PipelineInputBuilder withParams(final Map<String, String> params); Input build(); }
PipelineInputBuilder { public Input build() { final Input input = new Input(); if (runtimeName != null) { input.put(RuntimeConfig.RUNTIME_NAME, runtimeName); } if (providerKey != null) { input.put(ProviderConfig.PROVIDER_NAME, providerKey.getId()); } if (params != null) { input.putAll(params); } return input; } private  PipelineInputBuilder(); static PipelineInputBuilder newInstance(); PipelineInputBuilder withRuntimeName(final String runtimeName); PipelineInputBuilder withProvider(final ProviderKey providerKey); PipelineInputBuilder withParams(final Map<String, String> params); Input build();  }