From dd3f920e94e3b3ee31661a93bdb8acb78053a49b Mon Sep 17 00:00:00 2001 From: kske Date: Tue, 28 Jan 2020 17:09:28 +0100 Subject: [PATCH] Changed IdGenerator constructor to accept size instead of end index --- src/main/java/envoy/data/IdGenerator.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/envoy/data/IdGenerator.java b/src/main/java/envoy/data/IdGenerator.java index 9b61a20..1d5803d 100644 --- a/src/main/java/envoy/data/IdGenerator.java +++ b/src/main/java/envoy/data/IdGenerator.java @@ -23,12 +23,12 @@ public class IdGenerator implements Serializable { * Creates an instance of {@link IdGenerator}. * * @param begin the first ID - * @param end the last ID + * @param size the amount of IDs to provide * @since Envoy Common v0.2-alpha */ - public IdGenerator(long begin, long end) { - current = begin; - this.end = end; + public IdGenerator(long begin, long size) { + current = begin; + end = begin + size; } @Override