class Builder {

		private final CloudEurekaInstanceConfig instanceConfig;

		private ApplicationInfoManager applicationInfoManager;

		private EurekaClient eurekaClient;

		private ObjectProvider<HealthCheckHandler> healthCheckHandler;

		private EurekaClientConfig clientConfig;

		private ApplicationEventPublisher publisher;

		private TransportClientFactories<?> transportClientFactories;

		Builder(CloudEurekaInstanceConfig instanceConfig) {
			this.instanceConfig = instanceConfig;
		}

		public Builder with(ApplicationInfoManager applicationInfoManager) {
			this.applicationInfoManager = applicationInfoManager;
			return this;
		}

		public Builder with(EurekaClient eurekaClient) {
			this.eurekaClient = eurekaClient;
			return this;
		}

		public Builder with(ObjectProvider<HealthCheckHandler> healthCheckHandler) {
			this.healthCheckHandler = healthCheckHandler;
			return this;
		}

		public Builder with(TransportClientFactories<?> transportClientFactories) {
			this.transportClientFactories = transportClientFactories;
			return this;
		}

		public Builder with(EurekaClientConfig clientConfig, ApplicationEventPublisher publisher) {
			this.clientConfig = clientConfig;
			this.publisher = publisher;
			return this;
		}

		public EurekaRegistration build() {<FILL_FUNCTION_BODY>}

	}

			Assert.notNull(instanceConfig, "instanceConfig may not be null");

			if (this.applicationInfoManager == null) {
				InstanceInfo instanceInfo = new InstanceInfoFactory().create(this.instanceConfig);
				this.applicationInfoManager = new ApplicationInfoManager(this.instanceConfig, instanceInfo);
			}
			if (this.eurekaClient == null) {
				Assert.notNull(this.clientConfig, "if eurekaClient is null, EurekaClientConfig may not be null");
				Assert.notNull(this.publisher, "if eurekaClient is null, ApplicationEventPublisher may not be null");
				Assert.notNull(this.transportClientFactories,
						"if eurekaClient is null, TransportClientFactories may not be null");

				this.eurekaClient = new CloudEurekaClient(this.applicationInfoManager, this.clientConfig,
						this.transportClientFactories, this.publisher);
			}
			return new EurekaRegistration(instanceConfig, eurekaClient, applicationInfoManager, healthCheckHandler);
		
<no_super_class>