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

io.hyperfoil.core.builders.ServiceLoadedContract Maven / Gradle / Ivy

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

/**
 * Fill-in the builder provided in {@link #builder()} and then call {@link #complete()}.
 */
public final class ServiceLoadedContract {
   private final Object builder;
   private final Runnable completion;

   public ServiceLoadedContract(Object builder, Runnable completion) {
      this.builder = builder;
      this.completion = completion;
   }

   public Object builder() {
      return builder;
   }

   public void complete() {
      completion.run();
   }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy