Header file range/v3/algorithm/sample.hpp

#include <range/v3/range_fwd.hpp>

#include <range/v3/begin_end.hpp>

#include <range/v3/range_concepts.hpp>

#include <range/v3/range_traits.hpp>

#include <range/v3/algorithm/min.hpp>

#include <range/v3/utility/random.hpp>

#include <range/v3/utility/iterator.hpp>

#include <range/v3/utility/iterator_concepts.hpp>

#include <range/v3/utility/iterator_traits.hpp>

#include <range/v3/utility/static_const.hpp>

#include <range/v3/utility/tagged_pair.hpp>

namespace ranges
{
    inline namespace v3
    {
        class sample_fn;
        
        inline namespace 
        {
            constexpr auto& sample = static_const<with_braced_init_args<sample_fn>>::value;
        }
    }
}

Class ranges::v3::sample_fn

class sample_fn
{
public:
    template <typename I, typename S, typename O, typename Gen = detail::default_random_engine&, int _concept_requires_69 = 42, typename std::enable_if<(_concept_requires_69==43)||((ForwardIterator<I>()||SizedSentinel<S, I>())&&Constraint<I, S, O, Gen>()), int>::type=0>
    tagged_pair<tag::in(I), tag::out(O)> operator()(I, O, I first, S last, O out, iterator_difference_t<I> n, Gen&& gen = detail::get_random_engine()) const;
    
    template <typename I, typename S, typename O, typename Gen = detail::default_random_engine&, int _concept_requires_82 = 42, typename std::enable_if<(_concept_requires_82==43)||(RandomAccessIterator<O>()&&!(ForwardIterator<I>()||SizedSentinel<S, I>())&&Constraint<I, S, O, Gen>()), int>::type=0>
    tagged_pair<tag::in(I), tag::out(O)> operator()(I, O, I first, S last, O out, iterator_difference_t<I> n, Gen&& gen = detail::get_random_engine()) const;
    
    template <typename I, typename S, typename ORng, typename Gen = detail::default_random_engine&, int _concept_requires_114 = 42, typename std::enable_if<(_concept_requires_114==43)||((ForwardIterator<I>()||SizedSentinel<S, I>())&&(ForwardRange<ORng>()||SizedRange<ORng>())&&Constraint<I, S, range_iterator_t<ORng>, Gen>()), int>::type=0>
    tagged_pair<tag::in(I), tag::out(range_safe_iterator_t<ORng>)> operator()(I, range_safe_iterator_t<ORng>, I first, S last, ORng&& out, Gen&& gen = detail::get_random_engine()) const;
    
    template <typename I, typename S, typename ORng, typename Gen = detail::default_random_engine&, int _concept_requires_128 = 42, typename std::enable_if<(_concept_requires_128==43)||(RandomAccessIterator<range_iterator_t<ORng>>()&&!(ForwardIterator<I>()||SizedSentinel<S, I>())&&(ForwardRange<ORng>()||SizedRange<ORng>())&&Constraint<I, S, range_iterator_t<ORng>, Gen>()), int>::type=0>
    tagged_pair<tag::in(I), tag::out(range_safe_iterator_t<ORng>)> operator()(I, range_safe_iterator_t<ORng>, I first, S last, ORng&& out, Gen&& gen = detail::get_random_engine()) const;
    
    template <typename Rng, typename O, typename Gen = detail::default_random_engine&, int _concept_requires_141 = 42, typename std::enable_if<(_concept_requires_141==43)||(RandomAccessIterator<O>()&&!(ForwardRange<Rng>()||SizedRange<Rng>())&&Constraint<range_iterator_t<Rng>, range_sentinel_t<Rng>, O, Gen>()), int>::type=0>
    tagged_pair<tag::in(range_safe_iterator_t<Rng>), tag::out(O)> operator()(range_safe_iterator_t<Rng>, O, Rng&& rng, O out, range_difference_t<Rng> n, Gen&& gen = detail::get_random_engine()) const;
    
    template <typename Rng, typename O, typename Gen = detail::default_random_engine&, int _concept_requires_153 = 42, typename std::enable_if<(_concept_requires_153==43)||((ForwardRange<Rng>()||SizedRange<Rng>())&&Constraint<range_iterator_t<Rng>, range_sentinel_t<Rng>, O, Gen>()), int>::type=0>
    tagged_pair<tag::in(range_safe_iterator_t<Rng>), tag::out(O)> operator()(range_safe_iterator_t<Rng>, O, Rng&& rng, O out, range_difference_t<Rng> n, Gen&& gen = detail::get_random_engine()) const;
    
    template <typename IRng, typename ORng, typename Gen = detail::default_random_engine&, int _concept_requires_165 = 42, typename std::enable_if<(_concept_requires_165==43)||(RandomAccessIterator<range_iterator_t<ORng>>()&&!(ForwardRange<IRng>()||SizedRange<IRng>())&&(ForwardRange<ORng>()||SizedRange<ORng>())&&Constraint<range_iterator_t<IRng>, range_sentinel_t<IRng>, range_iterator_t<ORng>, Gen>()), int>::type=0>
    tagged_pair<tag::in(range_safe_iterator_t<IRng>), tag::out(range_safe_iterator_t<ORng>)> operator()(range_safe_iterator_t<IRng>, range_safe_iterator_t<ORng>, IRng&& rng, ORng&& out, Gen&& gen = detail::get_random_engine()) const;
    
    template <typename IRng, typename ORng, typename Gen = detail::default_random_engine&, int _concept_requires_181 = 42, typename std::enable_if<(_concept_requires_181==43)||((ForwardRange<IRng>()||SizedRange<IRng>())&&(ForwardRange<ORng>()||SizedRange<ORng>())&&Constraint<range_iterator_t<IRng>, range_sentinel_t<IRng>, range_iterator_t<ORng>, Gen>()), int>::type=0>
    tagged_pair<tag::in(range_safe_iterator_t<IRng>), tag::out(range_safe_iterator_t<ORng>)> operator()(range_safe_iterator_t<IRng>, range_safe_iterator_t<ORng>, IRng&& rng, ORng&& out, Gen&& gen = detail::get_random_engine()) const;
};

@{


Variable ranges::v3::sample

constexpr auto& sample = static_const<with_braced_init_args<sample_fn>>::value;

sample_fn