All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.hyperfoil.core.steps.StatisticsStep Maven / Gradle / Ivy

There is a newer version: 0.27.1
Show newest version
package io.hyperfoil.core.steps;

import java.util.concurrent.atomic.AtomicInteger;

import io.hyperfoil.api.config.Step;

public abstract class StatisticsStep implements Step {
   private static final AtomicInteger ID_COUNTER = new AtomicInteger();

   private final int id;

   public static int nextId() {
      return ID_COUNTER.getAndIncrement();
   }

   protected StatisticsStep(int id) {
      if (id < 0) {
         throw new IllegalArgumentException();
      }
      this.id = id;
   }

   public int id() {
      return id;
   }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy