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

io.hyperfoil.api.config.RunHook Maven / Gradle / Ivy

There is a newer version: 0.27
Show newest version
package io.hyperfoil.api.config;

import java.io.Serializable;
import java.util.Map;
import java.util.Objects;
import java.util.function.Consumer;

public abstract class RunHook implements Serializable, Comparable {
   protected final String name;

   protected RunHook(String name) {
      this.name = Objects.requireNonNull(name);
   }

   public String name() {
      return name;
   }

   public abstract boolean run(Map properties, Consumer outputConsumer);

   @Override
   public int compareTo(RunHook other) {
      return name.compareTo(other.name);
   }

   public interface Builder {
      RunHook build(String name);
   }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy