net.jqwik.engine.facades.ShrinkableFacadeImpl Maven / Gradle / Ivy
package net.jqwik.engine.facades;
import java.util.function.*;
import net.jqwik.api.*;
import net.jqwik.engine.properties.shrinking.*;
/**
* Is loaded through reflection in api module
*/
public class ShrinkableFacadeImpl extends Shrinkable.ShrinkableFacade {
@Override
public Shrinkable unshrinkable(Supplier valueSupplier, ShrinkingDistance distance) {
return new Unshrinkable<>(valueSupplier, distance);
}
@Override
public Shrinkable map(Shrinkable self, Function mapper) {
return new MappedShrinkable<>(self, mapper);
}
@Override
public Shrinkable filter(Shrinkable self, Predicate filter) {
return new FilteredShrinkable<>(self, filter);
}
@Override
public Shrinkable flatMap(Shrinkable self, Function> flatMapper, int tries, long randomSeed) {
return new FlatMappedShrinkable<>(self, flatMapper, tries, randomSeed, false);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy