Compare commits

..

7 Commits

130 changed files with 193 additions and 145 deletions

View File

@ -8,7 +8,6 @@
[![License MIT](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/iluwatar/java-design-patterns/master/LICENSE.md) [![License MIT](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/iluwatar/java-design-patterns/master/LICENSE.md)
[![Join the chat at https://gitter.im/iluwatar/java-design-patterns](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/iluwatar/java-design-patterns?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![Join the chat at https://gitter.im/iluwatar/java-design-patterns](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/iluwatar/java-design-patterns?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![Quality Gate](https://sonarcloud.io/api/project_badges/measure?project=com.iluwatar%3Ajava-design-patterns&metric=alert_status)](https://sonarcloud.io/dashboard/index/com.iluwatar%3Ajava-design-patterns) [![Quality Gate](https://sonarcloud.io/api/project_badges/measure?project=com.iluwatar%3Ajava-design-patterns&metric=alert_status)](https://sonarcloud.io/dashboard/index/com.iluwatar%3Ajava-design-patterns)
[![CII Best Practices](https://bestpractices.coreinfrastructure.org/projects/1503/badge)](https://bestpractices.coreinfrastructure.org/projects/1503)
# Introduction # Introduction

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>abstract-document</artifactId> <artifactId>abstract-document</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>abstract-factory</artifactId> <artifactId>abstract-factory</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>acyclic-visitor</artifactId> <artifactId>acyclic-visitor</artifactId>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>adapter</artifactId> <artifactId>adapter</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>aggregator-microservices</artifactId> <artifactId>aggregator-microservices</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>aggregator-microservices</artifactId> <artifactId>aggregator-microservices</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>aggregator-microservices</artifactId> <artifactId>aggregator-microservices</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>aggregator-microservices</artifactId> <artifactId>aggregator-microservices</artifactId>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>ambassador</artifactId> <artifactId>ambassador</artifactId>

View File

@ -22,6 +22,7 @@
*/ */
package com.iluwatar.ambassador; package com.iluwatar.ambassador;
import com.iluwatar.ambassador.util.RandomProvider;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
@ -31,9 +32,10 @@ import static java.lang.Thread.sleep;
* A remote legacy application represented by a Singleton implementation. * A remote legacy application represented by a Singleton implementation.
*/ */
public class RemoteService implements RemoteServiceInterface { public class RemoteService implements RemoteServiceInterface {
static final int THRESHOLD = 200;
private static final Logger LOGGER = LoggerFactory.getLogger(RemoteService.class); private static final Logger LOGGER = LoggerFactory.getLogger(RemoteService.class);
private static RemoteService service = null; private static RemoteService service = null;
private final RandomProvider randomProvider;
static synchronized RemoteService getRemoteService() { static synchronized RemoteService getRemoteService() {
if (service == null) { if (service == null) {
@ -42,24 +44,33 @@ public class RemoteService implements RemoteServiceInterface {
return service; return service;
} }
private RemoteService() {} private RemoteService() {
this(Math::random);
}
/**
* This constuctor is used for testing purposes only.
*/
RemoteService(RandomProvider randomProvider) {
this.randomProvider = randomProvider;
}
/** /**
* Remote function takes a value and multiplies it by 10 taking a random amount of time. * Remote function takes a value and multiplies it by 10 taking a random amount of time.
* Will sometimes return -1. This imitates connectivity issues a client might have to account for. * Will sometimes return -1. This imitates connectivity issues a client might have to account for.
* @param value integer value to be multiplied. * @param value integer value to be multiplied.
* @return if waitTime is more than 200ms, it returns value * 10, otherwise -1. * @return if waitTime is less than {@link RemoteService#THRESHOLD}, it returns value * 10,
* otherwise {@link RemoteServiceInterface#FAILURE}.
*/ */
@Override @Override
public long doRemoteFunction(int value) { public long doRemoteFunction(int value) {
long waitTime = (long) Math.floor(Math.random() * 1000); long waitTime = (long) Math.floor(randomProvider.random() * 1000);
try { try {
sleep(waitTime); sleep(waitTime);
} catch (InterruptedException e) { } catch (InterruptedException e) {
LOGGER.error("Thread sleep state interrupted", e); LOGGER.error("Thread sleep state interrupted", e);
} }
return waitTime >= 200 ? value * 10 : -1; return waitTime <= THRESHOLD ? value * 10 : FAILURE;
} }
} }

View File

@ -26,6 +26,7 @@ package com.iluwatar.ambassador;
* Interface shared by ({@link RemoteService}) and ({@link ServiceAmbassador}). * Interface shared by ({@link RemoteService}) and ({@link ServiceAmbassador}).
*/ */
interface RemoteServiceInterface { interface RemoteServiceInterface {
int FAILURE = -1;
long doRemoteFunction(int value) throws Exception; long doRemoteFunction(int value) throws Exception;
} }

View File

@ -59,15 +59,15 @@ public class ServiceAmbassador implements RemoteServiceInterface {
private long safeCall(int value) { private long safeCall(int value) {
int retries = 0; int retries = 0;
long result = -1; long result = FAILURE;
for (int i = 0; i < RETRIES; i++) { for (int i = 0; i < RETRIES; i++) {
if (retries >= RETRIES) { if (retries >= RETRIES) {
return -1; return FAILURE;
} }
if ((result = checkLatency(value)) == -1) { if ((result = checkLatency(value)) == FAILURE) {
LOGGER.info("Failed to reach remote: (" + (i + 1) + ")"); LOGGER.info("Failed to reach remote: (" + (i + 1) + ")");
retries++; retries++;
try { try {

View File

@ -0,0 +1,8 @@
package com.iluwatar.ambassador.util;
/**
* An interface for randomness. Useful for testing purposes.
*/
public interface RandomProvider {
double random();
}

View File

@ -24,6 +24,8 @@ package com.iluwatar.ambassador;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import static org.junit.jupiter.api.Assertions.assertTrue;
/** /**
* Test for {@link Client} * Test for {@link Client}
*/ */
@ -35,6 +37,6 @@ public class ClientTest {
Client client = new Client(); Client client = new Client();
long result = client.useService(10); long result = client.useService(10);
assert result == 100 || result == -1; assertTrue(result == 100 || result == RemoteService.FAILURE);
} }
} }

View File

@ -22,16 +22,43 @@
*/ */
package com.iluwatar.ambassador; package com.iluwatar.ambassador;
import com.iluwatar.ambassador.util.RandomProvider;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertTrue;
/** /**
* Test for {@link RemoteService} * Test for {@link RemoteService}
*/ */
public class RemoteServiceTest { public class RemoteServiceTest {
@Test @Test
public void test() { public void testFailedCall() {
long result = RemoteService.getRemoteService().doRemoteFunction(10); RemoteService remoteService = new RemoteService(
assert result == 100 || result == -1; new StaticRandomProvider(0.21));
long result = remoteService.doRemoteFunction(10);
assertEquals(RemoteServiceInterface.FAILURE, result);
}
@Test
public void testSuccessfulCall() {
RemoteService remoteService = new RemoteService(
new StaticRandomProvider(0.2));
long result = remoteService.doRemoteFunction(10);
assertEquals(100, result);
}
private class StaticRandomProvider implements RandomProvider {
private double value;
StaticRandomProvider(double value) {
this.value = value;
}
@Override
public double random() {
return value;
}
} }
} }

View File

@ -24,6 +24,8 @@ package com.iluwatar.ambassador;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import static org.junit.jupiter.api.Assertions.assertTrue;
/** /**
* Test for {@link ServiceAmbassador} * Test for {@link ServiceAmbassador}
*/ */
@ -32,6 +34,6 @@ public class ServiceAmbassadorTest {
@Test @Test
public void test() { public void test() {
long result = new ServiceAmbassador().doRemoteFunction(10); long result = new ServiceAmbassador().doRemoteFunction(10);
assert result == 100 || result == -1; assertTrue(result == 100 || result == RemoteServiceInterface.FAILURE);
} }
} }

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>api-gateway</artifactId> <artifactId>api-gateway</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>api-gateway-service</artifactId> <artifactId>api-gateway-service</artifactId>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>api-gateway</artifactId> <artifactId>api-gateway</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>api-gateway</artifactId> <artifactId>api-gateway</artifactId>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>api-gateway</artifactId> <artifactId>api-gateway</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>async-method-invocation</artifactId> <artifactId>async-method-invocation</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>bridge</artifactId> <artifactId>bridge</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>builder</artifactId> <artifactId>builder</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>business-delegate</artifactId> <artifactId>business-delegate</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>caching</artifactId> <artifactId>caching</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>callback</artifactId> <artifactId>callback</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>chain</artifactId> <artifactId>chain</artifactId>
<dependencies> <dependencies>

View File

@ -27,7 +27,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>collection-pipeline</artifactId> <artifactId>collection-pipeline</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>command</artifactId> <artifactId>command</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>composite</artifactId> <artifactId>composite</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<dependencies> <dependencies>

View File

@ -21,7 +21,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>cqrs</artifactId> <artifactId>cqrs</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>dao</artifactId> <artifactId>dao</artifactId>

View File

@ -33,7 +33,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>data-bus</artifactId> <artifactId>data-bus</artifactId>
<dependencies> <dependencies>

View File

@ -28,7 +28,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>data-mapper</artifactId> <artifactId>data-mapper</artifactId>
<dependencies> <dependencies>

View File

@ -28,7 +28,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>data-transfer-object</artifactId> <artifactId>data-transfer-object</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>decorator</artifactId> <artifactId>decorator</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>dependency-injection</artifactId> <artifactId>dependency-injection</artifactId>
<dependencies> <dependencies>

View File

@ -29,11 +29,11 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>dirty-flag</artifactId> <artifactId>dirty-flag</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
<name>dirty-flag</name> <name>dirty-flag</name>
<url>http://maven.apache.org</url> <url>http://maven.apache.org</url>
<properties> <properties>

View File

@ -27,7 +27,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>double-checked-locking</artifactId> <artifactId>double-checked-locking</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>double-dispatch</artifactId> <artifactId>double-dispatch</artifactId>
<dependencies> <dependencies>

View File

@ -26,7 +26,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>eip-message-channel</artifactId> <artifactId>eip-message-channel</artifactId>
<dependencies> <dependencies>

View File

@ -28,7 +28,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>eip-publish-subscribe</artifactId> <artifactId>eip-publish-subscribe</artifactId>
<dependencies> <dependencies>

View File

@ -26,7 +26,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<dependencies> <dependencies>

View File

@ -26,7 +26,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<dependencies> <dependencies>

View File

@ -28,7 +28,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>event-aggregator</artifactId> <artifactId>event-aggregator</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>event-asynchronous</artifactId> <artifactId>event-asynchronous</artifactId>
<dependencies> <dependencies>

View File

@ -31,7 +31,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>event-driven-architecture</artifactId> <artifactId>event-driven-architecture</artifactId>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>event-queue</artifactId> <artifactId>event-queue</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>event-sourcing</artifactId> <artifactId>event-sourcing</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>execute-around</artifactId> <artifactId>execute-around</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>facade</artifactId> <artifactId>facade</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>factory-kit</artifactId> <artifactId>factory-kit</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>factory-method</artifactId> <artifactId>factory-method</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>flux</artifactId> <artifactId>flux</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>flyweight</artifactId> <artifactId>flyweight</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>front-controller</artifactId> <artifactId>front-controller</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<packaging>jar</packaging> <packaging>jar</packaging>
<artifactId>guarded-suspension</artifactId> <artifactId>guarded-suspension</artifactId>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>half-sync-half-async</artifactId> <artifactId>half-sync-half-async</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>hexagonal</artifactId> <artifactId>hexagonal</artifactId>
<dependencies> <dependencies>

View File

@ -22,13 +22,12 @@
*/ */
package com.iluwatar.hexagonal.domain; package com.iluwatar.hexagonal.domain;
import java.util.ArrayList;
import java.util.Collections; import java.util.Collections;
import java.util.HashSet; import java.util.HashSet;
import java.util.List;
import java.util.PrimitiveIterator; import java.util.PrimitiveIterator;
import java.util.Random; import java.util.Random;
import java.util.Set; import java.util.Set;
import java.util.Iterator;
/** /**
* *
@ -85,11 +84,10 @@ public class LotteryNumbers {
* @return numbers as comma separated string * @return numbers as comma separated string
*/ */
public String getNumbersAsString() { public String getNumbersAsString() {
List<Integer> list = new ArrayList<>();
list.addAll(numbers);
StringBuilder builder = new StringBuilder(); StringBuilder builder = new StringBuilder();
Iterator<Integer> iterator = numbers.iterator();
for (int i = 0; i < NUM_NUMBERS; i++) { for (int i = 0; i < NUM_NUMBERS; i++) {
builder.append(list.get(i)); builder.append(iterator.next());
if (i < NUM_NUMBERS - 1) { if (i < NUM_NUMBERS - 1) {
builder.append(","); builder.append(",");
} }

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>intercepting-filter</artifactId> <artifactId>intercepting-filter</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>interpreter</artifactId> <artifactId>interpreter</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>iterator</artifactId> <artifactId>iterator</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<groupId>com.iluwatar.layers</groupId> <groupId>com.iluwatar.layers</groupId>
<artifactId>layers</artifactId> <artifactId>layers</artifactId>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>lazy-loading</artifactId> <artifactId>lazy-loading</artifactId>
<dependencies> <dependencies>

View File

@ -24,7 +24,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>mediator</artifactId> <artifactId>mediator</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>memento</artifactId> <artifactId>memento</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>model-view-controller</artifactId> <artifactId>model-view-controller</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>model-view-presenter</artifactId> <artifactId>model-view-presenter</artifactId>
<name>model-view-presenter</name> <name>model-view-presenter</name>

View File

@ -28,7 +28,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>module</artifactId> <artifactId>module</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>monad</artifactId> <artifactId>monad</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>monostate</artifactId> <artifactId>monostate</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>multiton</artifactId> <artifactId>multiton</artifactId>
<dependencies> <dependencies>

View File

@ -21,7 +21,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>mute-idiom</artifactId> <artifactId>mute-idiom</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>mutex</artifactId> <artifactId>mutex</artifactId>
<dependencies> <dependencies>

View File

@ -16,7 +16,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>naked-objects</artifactId> <artifactId>naked-objects</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>naked-objects-dom</artifactId> <artifactId>naked-objects-dom</artifactId>

View File

@ -16,7 +16,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>naked-objects</artifactId> <artifactId>naked-objects</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>naked-objects-fixture</artifactId> <artifactId>naked-objects-fixture</artifactId>

View File

@ -16,7 +16,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>naked-objects</artifactId> <artifactId>naked-objects</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>naked-objects-integtests</artifactId> <artifactId>naked-objects-integtests</artifactId>

View File

@ -15,7 +15,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>naked-objects</artifactId> <artifactId>naked-objects</artifactId>
@ -350,17 +350,17 @@
<dependency> <dependency>
<groupId>${project.groupId}</groupId> <groupId>${project.groupId}</groupId>
<artifactId>naked-objects-dom</artifactId> <artifactId>naked-objects-dom</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>${project.groupId}</groupId> <groupId>${project.groupId}</groupId>
<artifactId>naked-objects-fixture</artifactId> <artifactId>naked-objects-fixture</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>${project.groupId}</groupId> <groupId>${project.groupId}</groupId>
<artifactId>naked-objects-webapp</artifactId> <artifactId>naked-objects-webapp</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</dependency> </dependency>
</dependencies> </dependencies>

View File

@ -16,7 +16,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>naked-objects</artifactId> <artifactId>naked-objects</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>naked-objects-webapp</artifactId> <artifactId>naked-objects-webapp</artifactId>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>null-object</artifactId> <artifactId>null-object</artifactId>
<dependencies> <dependencies>

View File

@ -30,7 +30,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>object-mother</artifactId> <artifactId>object-mother</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>object-pool</artifactId> <artifactId>object-pool</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>observer</artifactId> <artifactId>observer</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>page-object</artifactId> <artifactId>page-object</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>poison-pill</artifactId> <artifactId>poison-pill</artifactId>
<dependencies> <dependencies>

View File

@ -21,7 +21,7 @@
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
<packaging>pom</packaging> <packaging>pom</packaging>
<inceptionYear>2014</inceptionYear> <inceptionYear>2014</inceptionYear>
<properties> <properties>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>private-class-data</artifactId> <artifactId>private-class-data</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>producer-consumer</artifactId> <artifactId>producer-consumer</artifactId>
<dependencies> <dependencies>

View File

@ -29,7 +29,7 @@
<parent> <parent>
<groupId>com.iluwatar</groupId> <groupId>com.iluwatar</groupId>
<artifactId>java-design-patterns</artifactId> <artifactId>java-design-patterns</artifactId>
<version>1.20.0</version> <version>1.21.0-SNAPSHOT</version>
</parent> </parent>
<artifactId>promise</artifactId> <artifactId>promise</artifactId>
<dependencies> <dependencies>

Some files were not shown because too many files have changed in this diff Show More