QtBase  v6.3.1
Classes | Macros | Typedefs | Functions | Variables
hb-iter.hh File Reference
#include "hb.hh"
#include "hb-algs.hh"
#include "hb-meta.hh"
Include dependency graph for hb-iter.hh:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  hb_iter_t< iter_t, Item >
 
struct  hb_iter_fallback_mixin_t< iter_t, item_t >
 
struct  hb_iter_with_fallback_t< iter_t, item_t >
 
struct  hb_is_iterator_of< Iter, Item >
 
struct  hb_is_iterable< T >
 
struct  hb_is_source_of< Iter, Item >
 
struct  hb_is_sink_of< Iter, Item >
 
struct  hb_map_iter_t< Lhs, Rhs, >
 
struct  hb_map_iter_factory_t< Proj, Sorted >
 
struct  hb_filter_iter_t< Iter, Pred, Proj, >
 
struct  hb_filter_iter_factory_t< Pred, Proj >
 
struct  hb_reduce_t< Redu, InitT >
 
struct  hb_zip_iter_t< A, B >
 
struct  hb_concat_iter_t< A, B >
 
struct  hb_apply_t< Appl >
 
struct  hb_range_iter_t< T, S >
 
struct  hb_iota_iter_t< T, S >
 
struct  hb_repeat_iter_t< T >
 
struct  hb_sink_t< Sink >
 
struct  hb_unzip_t< Sink1, Sink2 >
 

Macros

#define HB_ITER_USING(Name)
 
#define hb_is_iterator_of(Iter, Item)   hb_is_iterator_of<Iter, Item>::value
 
#define hb_is_iterator(Iter)   hb_is_iterator_of (Iter, typename Iter::item_t)
 
#define hb_is_iterable(Iterable)   hb_is_iterable<Iterable>::value
 
#define hb_is_source_of(Iter, Item)   hb_is_source_of<Iter, Item>::value
 
#define hb_is_sink_of(Iter, Item)   hb_is_sink_of<Iter, Item>::value
 
#define hb_is_sorted_source_of(Iter, Item)    (hb_is_source_of(Iter, Item) && Iter::is_sorted_iterator)
 

Typedefs

template<typename Iterable >
using hb_iter_type = decltype(hb_deref(hb_declval(Iterable)).iter())
 
template<typename Iterable >
using hb_item_type = decltype(*hb_deref(hb_declval(Iterable)).iter())
 

Functions

struct {
HB_FUNCOBJ (hb_iter)
 
template<typename T >
hb_iter_type< Toperator() (T &&c) const
 
template<typename Type >
hb_array_t< Typeoperator() (Type *array, unsigned int length) const
 
template<typename Type , unsigned int length>
hb_array_t< Typeoperator() (Type(&array)[length]) const
 
struct {
HB_FUNCOBJ (hb_len)
 
template<typename T >
unsigned operator() (T &&c) const
 
static auto hb_requires (hb_is_iterable(Iterable))> static inline auto end(Iterable &&iterable) HB_AUTO_RETURN(hb_iter(iterable).end()) namespace OT
 
struct {
HB_FUNCOBJ (hb_map)
 
template<typename Proj >
hb_map_iter_factory_t< Proj, hb_function_sortedness_t::NOT_SORTED > operator() (Proj &&f) const
 
struct {
HB_FUNCOBJ (hb_map_retains_sorting)
 
template<typename Proj >
hb_map_iter_factory_t< Proj, hb_function_sortedness_t::RETAINS_SORTING > operator() (Proj &&f) const
 
struct {
HB_FUNCOBJ (hb_map_sorted)
 
template<typename Proj >
hb_map_iter_factory_t< Proj, hb_function_sortedness_t::SORTED > operator() (Proj &&f) const
 
struct {
HB_FUNCOBJ (hb_filter)
 
template<typename Pred = decltype ((hb_identity)), typename Proj = decltype ((hb_identity))>
hb_filter_iter_factory_t< Pred, Proj > operator() (Pred &&p=hb_identity, Proj &&f=hb_identity) const
 
struct {
HB_FUNCOBJ (hb_reduce)
 
template<typename Redu , typename InitT >
hb_reduce_t< Redu, InitT > operator() (Redu &&r, InitT init_value) const
 
struct {
HB_FUNCOBJ (hb_zip)
 
 HB_PARTIALIZE (2)
 
template<typename A , typename B , hb_requires(hb_is_iterable(A) &&hb_is_iterable(B)) >
hb_zip_iter_t< hb_iter_type< A >, hb_iter_type< B > > operator() (A &&a, B &&b) const
 
struct {
HB_FUNCOBJ (hb_concat)
 
template<typename A , typename B , hb_requires(hb_is_iterable(A) &&hb_is_iterable(B)) >
hb_concat_iter_t< hb_iter_type< A >, hb_iter_type< B > > operator() (A &&a, B &&b) const
 
struct {
HB_FUNCOBJ (hb_apply)
 
template<typename Appl >
hb_apply_t< Apploperator() (Appl &&a) const
 
template<typename Appl >
hb_apply_t< Appl & > operator() (Appl *a) const
 
struct {
HB_FUNCOBJ (hb_range)
 
template<typename T = unsigned>
hb_range_iter_t< T, unsigned > operator() (T end=(unsigned) -1) const
 
template<typename T , typename S = unsigned>
hb_range_iter_t< T, Soperator() (T start, T end, S step=1u) const
 
struct {
HB_FUNCOBJ (hb_iota)
 
template<typename T = unsigned, typename S = unsigned>
hb_iota_iter_t< T, Soperator() (T start=0u, S step=1u) const
 
struct {
HB_FUNCOBJ (hb_repeat)
 
template<typename T >
hb_repeat_iter_t< Toperator() (T value) const
 
struct {
HB_FUNCOBJ (hb_enumerate)
 
template<typename Iterable , typename Index = unsigned, hb_requires(hb_is_iterable(Iterable)) >
auto operator() (Iterable &&it, Index start=0u) const HB_AUTO_RETURN(hb_zip(hb_iota(start)
 
struct {
   auto it unsigned count   const { return array.sub_array (0, count)
 
HB_FUNCOBJ (hb_take)
 
template<typename Iterable , hb_requires(hb_is_iterable(Iterable)) >
auto operator() (Iterable &&it, unsigned count) const HB_AUTO_RETURN(hb_zip(hb_range(count)
 
auto it hb_map (hb_second)) template< typename Type > inline hb_array_t< Type > operator()(hb_array_t< Type > array
 
template<typename Type >
hb_sorted_array_t< Typeoperator() (hb_sorted_array_t< Type > array, unsigned count) const
 
struct {
HB_FUNCOBJ (hb_chop)
 
template<typename Iter , hb_requires(hb_is_iterator(Iter)) >
auto operator() (Iter it, unsigned count) const HB_AUTO_RETURN(+hb_iota(it
 
struct {
HB_FUNCOBJ (hb_sink)
 
template<typename Sink >
hb_sink_t< Sink > operator() (Sink &&s) const
 
template<typename Sink >
hb_sink_t< Sink & > operator() (Sink *s) const
 
struct {
HB_FUNCOBJ (hb_drain)
 
template<typename Iter , hb_requires(hb_is_iterator(Iter)) >
void operator() (Iter it) const
 
struct {
HB_FUNCOBJ (hb_unzip)
 
template<typename Sink1 , typename Sink2 >
hb_unzip_t< Sink1, Sink2 > operator() (Sink1 &&s1, Sink2 &&s2) const
 
template<typename Sink1 , typename Sink2 >
hb_unzip_t< Sink1 &, Sink2 & > operator() (Sink1 *s1, Sink2 *s2) const
 
struct {
HB_FUNCOBJ (hb_all)
 
template<typename Iterable , typename Pred = decltype ((hb_identity)), typename Proj = decltype ((hb_identity)), hb_requires(hb_is_iterable(Iterable)) >
bool operator() (Iterable &&c, Pred &&p=hb_identity, Proj &&f=hb_identity) const
 
struct {
HB_FUNCOBJ (hb_any)
 
struct {
HB_FUNCOBJ (hb_none)
 
template<typename C , typename V , hb_requires(hb_is_iterable(C)) >
void hb_fill (C &&c, const V &v)
 
template<typename S , typename D >
void hb_copy (S &&is, D &&id)
 

Variables

struct hb_iter_fallback_mixin_t HB_FUNCOBJ
 

Macro Definition Documentation

◆ hb_is_iterable

#define hb_is_iterable (   Iterable)    hb_is_iterable<Iterable>::value

Definition at line 283 of file hb-iter.hh.

◆ hb_is_iterator

#define hb_is_iterator (   Iter)    hb_is_iterator_of (Iter, typename Iter::item_t)

Definition at line 265 of file hb-iter.hh.

◆ hb_is_iterator_of

#define hb_is_iterator_of (   Iter,
  Item 
)    hb_is_iterator_of<Iter, Item>::value

Definition at line 264 of file hb-iter.hh.

◆ hb_is_sink_of

#define hb_is_sink_of (   Iter,
  Item 
)    hb_is_sink_of<Iter, Item>::value

Definition at line 317 of file hb-iter.hh.

◆ hb_is_sorted_source_of

#define hb_is_sorted_source_of (   Iter,
  Item 
)     (hb_is_source_of(Iter, Item) && Iter::is_sorted_iterator)

Definition at line 320 of file hb-iter.hh.

◆ hb_is_source_of

#define hb_is_source_of (   Iter,
  Item 
)    hb_is_source_of<Iter, Item>::value

Definition at line 301 of file hb-iter.hh.

◆ HB_ITER_USING

#define HB_ITER_USING (   Name)
Value:
using item_t = typename Name::item_t; \
using Name::begin; \
using Name::end; \
using Name::get_item_size; \
using Name::is_iterator; \
using Name::iter; \
using Name::operator bool; \
using Name::len; \
using Name::operator ->; \
using Name::operator *; \
using Name::operator []; \
using Name::operator +=; \
using Name::operator ++; \
using Name::operator -=; \
using Name::operator --; \
using Name::operator +; \
using Name::operator -; \
using Name::operator >>; \
using Name::operator <<; \
static_assert (true, "")
DBusConnection const char DBusError DBusBusType DBusError return DBusConnection DBusHandleMessageFunction void DBusFreeFunction return DBusConnection return DBusConnection return const char DBusError return DBusConnection DBusMessage dbus_uint32_t return DBusConnection dbus_bool_t DBusConnection DBusAddWatchFunction DBusRemoveWatchFunction DBusWatchToggledFunction void DBusFreeFunction return DBusConnection DBusDispatchStatusFunction void DBusFreeFunction DBusTimeout return DBusTimeout return DBusWatch return DBusWatch unsigned int return DBusError const DBusError return const DBusMessage return DBusMessage return DBusMessage return DBusMessage return DBusMessage return DBusMessage return DBusMessageIter * iter
GLuint GLuint end
GLenum GLsizei len
Definition: qopenglext.h:3292
QtPrivate::QRegularExpressionMatchIteratorRangeBasedForIterator begin(const QRegularExpressionMatchIterator &iterator)

Definition at line 129 of file hb-iter.hh.

Typedef Documentation

◆ hb_item_type

template<typename Iterable >
using hb_item_type = decltype (*hb_deref (hb_declval (Iterable)).iter ())

Definition at line 155 of file hb-iter.hh.

◆ hb_iter_type

template<typename Iterable >
using hb_iter_type = decltype (hb_deref (hb_declval (Iterable)).iter ())

Definition at line 153 of file hb-iter.hh.

Function Documentation

◆ hb_copy()

template<typename S , typename D >
void hb_copy ( S &&  is,
D &&  id 
)
inline

Definition at line 1018 of file hb-iter.hh.

Here is the caller graph for this function:

◆ hb_fill()

template<typename C , typename V , hb_requires(hb_is_iterable(C)) >
void hb_fill ( C &&  c,
const V v 
)
inline

Definition at line 1010 of file hb-iter.hh.

Here is the caller graph for this function:

◆ HB_FUNCOBJ() [1/22]

struct @137 HB_FUNCOBJ ( hb_all  )

◆ HB_FUNCOBJ() [2/22]

struct @138 HB_FUNCOBJ ( hb_any  )

◆ HB_FUNCOBJ() [3/22]

struct @127 HB_FUNCOBJ ( hb_apply  )

◆ HB_FUNCOBJ() [4/22]

struct @133 HB_FUNCOBJ ( hb_chop  )

◆ HB_FUNCOBJ() [5/22]

struct @126 HB_FUNCOBJ ( hb_concat  )

◆ HB_FUNCOBJ() [6/22]

struct @135 HB_FUNCOBJ ( hb_drain  )

◆ HB_FUNCOBJ() [7/22]

struct @131 HB_FUNCOBJ ( hb_enumerate  )

◆ HB_FUNCOBJ() [8/22]

struct @123 HB_FUNCOBJ ( hb_filter  )

◆ HB_FUNCOBJ() [9/22]

struct @129 HB_FUNCOBJ ( hb_iota  )

◆ HB_FUNCOBJ() [10/22]

struct @118 HB_FUNCOBJ ( hb_iter  )

◆ HB_FUNCOBJ() [11/22]

struct @119 HB_FUNCOBJ ( hb_len  )

◆ HB_FUNCOBJ() [12/22]

struct @120 HB_FUNCOBJ ( hb_map  )

◆ HB_FUNCOBJ() [13/22]

struct @121 HB_FUNCOBJ ( hb_map_retains_sorting  )

◆ HB_FUNCOBJ() [14/22]

struct @122 HB_FUNCOBJ ( hb_map_sorted  )

◆ HB_FUNCOBJ() [15/22]

struct @139 HB_FUNCOBJ ( hb_none  )

◆ HB_FUNCOBJ() [16/22]

struct @128 HB_FUNCOBJ ( hb_range  )

◆ HB_FUNCOBJ() [17/22]

struct @124 HB_FUNCOBJ ( hb_reduce  )

◆ HB_FUNCOBJ() [18/22]

struct @130 HB_FUNCOBJ ( hb_repeat  )

◆ HB_FUNCOBJ() [19/22]

struct @134 HB_FUNCOBJ ( hb_sink  )

◆ HB_FUNCOBJ() [20/22]

struct @132 HB_FUNCOBJ ( hb_take  )

◆ HB_FUNCOBJ() [21/22]

struct @136 HB_FUNCOBJ ( hb_unzip  )

◆ HB_FUNCOBJ() [22/22]

struct @125 HB_FUNCOBJ ( hb_zip  )

◆ hb_map()

auto it @132::hb_map ( hb_second  )
Here is the caller graph for this function:

◆ HB_PARTIALIZE()

HB_FUNCOBJ::HB_PARTIALIZE ( )

◆ hb_requires()

static auto hb_requires ( hb_is_iterable(Iterable)  ) &&

Definition at line 331 of file hb-iter.hh.

Here is the call graph for this function:

◆ operator()() [1/27]

template<typename A , typename B , hb_requires(hb_is_iterable(A) &&hb_is_iterable(B)) >
hb_zip_iter_t<hb_iter_type<A>, hb_iter_type<B> > HB_FUNCOBJ::operator() ( A &&  a,
B &&  b 
) const

Definition at line 3 of file hb-iter.hh.

◆ operator()() [2/27]

template<typename A , typename B , hb_requires(hb_is_iterable(A) &&hb_is_iterable(B)) >
hb_concat_iter_t<hb_iter_type<A>, hb_iter_type<B> > HB_FUNCOBJ::operator() ( A &&  a,
B &&  b 
) const

Definition at line 3 of file hb-iter.hh.

◆ operator()() [3/27]

template<typename Appl >
hb_apply_t<Appl> HB_FUNCOBJ::operator() ( Appl &&  a) const

Definition at line 1 of file hb-iter.hh.

◆ operator()() [4/27]

template<typename Appl >
hb_apply_t<Appl&> HB_FUNCOBJ::operator() ( Appl a) const

Definition at line 5 of file hb-iter.hh.

◆ operator()() [5/27]

template<typename Type >
hb_sorted_array_t<Type> HB_FUNCOBJ::operator() ( hb_sorted_array_t< Type array,
unsigned  count 
) const
inline

Definition at line 12 of file hb-iter.hh.

◆ operator()() [6/27]

template<typename Iter , hb_requires(hb_is_iterator(Iter)) >
void HB_FUNCOBJ::operator() ( Iter  it) const

Definition at line 2 of file hb-iter.hh.

◆ operator()() [7/27]

template<typename Iter , hb_requires(hb_is_iterator(Iter)) >
auto HB_FUNCOBJ::operator() ( Iter  it,
unsigned  count 
) const

◆ operator()() [8/27]

template<typename Iterable , typename Pred = decltype ((hb_identity)), typename Proj = decltype ((hb_identity)), hb_requires(hb_is_iterable(Iterable)) >
bool operator() ( Iterable &&  c,
Pred &&  p = hb_identity,
Proj &&  f = hb_identity 
) const

Definition at line 4 of file hb-iter.hh.

◆ operator()() [9/27]

template<typename Iterable , typename Index = unsigned, hb_requires(hb_is_iterable(Iterable)) >
auto HB_FUNCOBJ::operator() ( Iterable &&  it,
Index  start = 0u 
) const

◆ operator()() [10/27]

template<typename Iterable , hb_requires(hb_is_iterable(Iterable)) >
auto HB_FUNCOBJ::operator() ( Iterable &&  it,
unsigned  count 
) const

◆ operator()() [11/27]

template<typename Pred = decltype ((hb_identity)), typename Proj = decltype ((hb_identity))>
hb_filter_iter_factory_t<Pred, Proj> HB_FUNCOBJ::operator() ( Pred &&  p = hb_identity,
Proj &&  f = hb_identity 
) const

Definition at line 3 of file hb-iter.hh.

◆ operator()() [12/27]

template<typename Proj >
hb_map_iter_factory_t<Proj, hb_function_sortedness_t::SORTED> HB_FUNCOBJ::operator() ( Proj &&  f) const

Definition at line 2 of file hb-iter.hh.

◆ operator()() [13/27]

template<typename Proj >
hb_map_iter_factory_t<Proj, hb_function_sortedness_t::RETAINS_SORTING> HB_FUNCOBJ::operator() ( Proj &&  f) const

Definition at line 2 of file hb-iter.hh.

◆ operator()() [14/27]

template<typename Proj >
hb_map_iter_factory_t<Proj, hb_function_sortedness_t::NOT_SORTED> HB_FUNCOBJ::operator() ( Proj &&  f) const

Definition at line 2 of file hb-iter.hh.

◆ operator()() [15/27]

template<typename Redu , typename InitT >
hb_reduce_t<Redu, InitT> HB_FUNCOBJ::operator() ( Redu &&  r,
InitT  init_value 
) const

Definition at line 2 of file hb-iter.hh.

◆ operator()() [16/27]

template<typename Sink >
hb_sink_t<Sink> HB_FUNCOBJ::operator() ( Sink &&  s) const

Definition at line 1 of file hb-iter.hh.

◆ operator()() [17/27]

template<typename Sink >
hb_sink_t<Sink&> HB_FUNCOBJ::operator() ( Sink *  s) const

Definition at line 5 of file hb-iter.hh.

◆ operator()() [18/27]

template<typename Sink1 , typename Sink2 >
hb_unzip_t<Sink1, Sink2> HB_FUNCOBJ::operator() ( Sink1 &&  s1,
Sink2 &&  s2 
) const

Definition at line 1 of file hb-iter.hh.

◆ operator()() [19/27]

template<typename Sink1 , typename Sink2 >
hb_unzip_t<Sink1&, Sink2&> HB_FUNCOBJ::operator() ( Sink1 *  s1,
Sink2 *  s2 
) const

Definition at line 5 of file hb-iter.hh.

◆ operator()() [20/27]

template<typename T >
hb_iter_type<T> HB_FUNCOBJ::operator() ( T &&  c) const

Definition at line 1 of file hb-iter.hh.

◆ operator()() [21/27]

template<typename T >
unsigned HB_FUNCOBJ::operator() ( T &&  c) const

Definition at line 1 of file hb-iter.hh.

◆ operator()() [22/27]

template<typename T = unsigned>
hb_range_iter_t<T, unsigned> HB_FUNCOBJ::operator() ( T  end = (unsigned) -1) const

Definition at line 1 of file hb-iter.hh.

◆ operator()() [23/27]

template<typename T , typename S = unsigned>
hb_range_iter_t<T, S> HB_FUNCOBJ::operator() ( T  start,
T  end,
S  step = 1u 
) const

Definition at line 5 of file hb-iter.hh.

◆ operator()() [24/27]

template<typename T = unsigned, typename S = unsigned>
hb_iota_iter_t<T, S> HB_FUNCOBJ::operator() ( T  start = 0u,
S  step = 1u 
) const

Definition at line 1 of file hb-iter.hh.

◆ operator()() [25/27]

template<typename T >
hb_repeat_iter_t<T> HB_FUNCOBJ::operator() ( T  value) const

Definition at line 1 of file hb-iter.hh.

◆ operator()() [26/27]

template<typename Type >
hb_array_t<Type> HB_FUNCOBJ::operator() ( Type array,
unsigned int  length 
) const
inline

Definition at line 7 of file hb-iter.hh.

◆ operator()() [27/27]

template<typename Type , unsigned int length>
hb_array_t<Type> HB_FUNCOBJ::operator() ( Type(&)  array[length]) const

Definition at line 11 of file hb-iter.hh.

Variable Documentation

◆ const

auto it unsigned count const { return array.sub_array (0, count)

Definition at line 847 of file hb-iter.hh.

◆ HB_FUNCOBJ

struct hb_unzip_t HB_FUNCOBJ