import { Arbitrary } from './definition/Arbitrary'; /** * Constraints to be applied on {@link option} * @public */ export interface OptionConstraints { /** The probability to build a nil value is of `1 / freq` */ freq?: number; /** The nil value (default would be null) */ nil?: TNil; } /** * For either null or a value coming from `arb` * * @param arb - Arbitrary that will be called to generate a non null value * * @public */ declare function option(arb: Arbitrary): Arbitrary; /** * For either null or a value coming from `arb` with custom frequency * * @param arb - Arbitrary that will be called to generate a non null value * @param freq - The probability to build a null value is of `1 / freq` * * @public */ declare function option(arb: Arbitrary, freq: number): Arbitrary; /** * For either nil or a value coming from `arb` with custom frequency * * @param arb - Arbitrary that will be called to generate a non nil value * @param constraints - Constraints on the option * * @public */ declare function option(arb: Arbitrary, constraints: OptionConstraints): Arbitrary; export { option };