Interface ArbitraryProvider.SubtypeProvider

  • All Superinterfaces:
    java.util.function.Function<TypeUsage,​java.util.Set<Arbitrary<?>>>
    Enclosing interface:
    ArbitraryProvider
    Functional Interface:
    This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

    @FunctionalInterface
    public static interface ArbitraryProvider.SubtypeProvider
    extends java.util.function.Function<TypeUsage,​java.util.Set<Arbitrary<?>>>
    • Method Summary

      All Methods Instance Methods Default Methods 
      Modifier and Type Method Description
      default java.util.Optional<Arbitrary<?>> provideOneFor​(TypeUsage typeUsage)
      Convenience method to combine set of arbitraries in optional choice-based arbitrary.
      default java.util.stream.Stream<java.util.List<Arbitrary<?>>> resolveAndCombine​(TypeUsage... typeUsages)
      Resolve all typeUsages and return a stream of all possible arbitraries combinations per type.
      • Methods inherited from interface java.util.function.Function

        andThen, apply, compose
    • Method Detail

      • resolveAndCombine

        @API(status=MAINTAINED,
             since="1.2.0")
        default java.util.stream.Stream<java.util.List<Arbitrary<?>>> resolveAndCombine​(TypeUsage... typeUsages)
        Resolve all typeUsages and return a stream of all possible arbitraries combinations per type. The list of arbitraries returned in the stream has the same size as the number of typeUsages handed in.
        Parameters:
        typeUsages -
        Returns:
        stream of list of arbitraries
      • provideOneFor

        @API(status=EXPERIMENTAL,
             since="1.5.2")
        default java.util.Optional<Arbitrary<?>> provideOneFor​(TypeUsage typeUsage)
        Convenience method to combine set of arbitraries in optional choice-based arbitrary.
        Parameters:
        typeUsage -
        Returns:
        Optional arbitrary instance