souffle  2.0.2-371-g6315b36
Public Member Functions | Private Types | Private Member Functions | Private Attributes | Friends
souffle::detail::brie::TrieIterator< Value, IterCore > Class Template Reference

An iterator over the stored entries. More...

#include <Brie.h>

Collaboration diagram for souffle::detail::brie::TrieIterator< Value, IterCore >:
Collaboration graph

Public Member Functions

bool operator!= (const TrieIterator &other) const
 
const Value & operator* () const
 
TrieIteratoroperator++ ()
 
TrieIterator operator++ (int)
 
const Value * operator-> () const
 
TrieIteratoroperator= (const TrieIterator &)=default
 
TrieIteratoroperator= (TrieIterator &&)=default
 
bool operator== (const TrieIterator &other) const
 
void print (std::ostream &out) const
 
 TrieIterator ()=default
 
 TrieIterator (const TrieIterator &)=default
 
 TrieIterator (iter_core_arg_type param)
 
 TrieIterator (TrieIterator &&)=default
 

Private Types

using iter_core_arg_type = typename std::remove_reference_t< IterCore >::store_iter
 

Private Member Functions

auto getNestedView ()
 
 TrieIterator (Value value, IterCore iter_core)
 

Private Attributes

IterCore iter_core
 
Value value
 

Friends

template<unsigned Len, unsigned Pos, unsigned Dimensions>
struct fix_binding
 
template<unsigned Pos, unsigned Dimensions>
struct fix_first
 
template<unsigned Dimensions>
struct fix_first_nested
 
template<unsigned Dimensions>
struct fix_lower_bound
 
template<unsigned Dimensions>
struct fix_upper_bound
 
std::ostream & operator<< (std::ostream &out, const TrieIterator &iter)
 
template<typename A , typename B >
class TrieIterator
 

Detailed Description

template<typename Value, typename IterCore>
class souffle::detail::brie::TrieIterator< Value, IterCore >

An iterator over the stored entries.

Iterators for tries consist of a top-level iterator maintaining the master copy of a materialized tuple and a recursively nested iterator core – one for each nested trie level.

Definition at line 1933 of file Brie.h.

Member Typedef Documentation

◆ iter_core_arg_type

template<typename Value , typename IterCore >
using souffle::detail::brie::TrieIterator< Value, IterCore >::iter_core_arg_type = typename std::remove_reference_t<IterCore>::store_iter
private

Definition at line 1953 of file Brie.h.

Constructor & Destructor Documentation

◆ TrieIterator() [1/5]

template<typename Value , typename IterCore >
souffle::detail::brie::TrieIterator< Value, IterCore >::TrieIterator ( Value  value,
IterCore  iter_core 
)
inlineexplicitprivate

Definition at line 1968 of file Brie.h.

1970 {

◆ TrieIterator() [2/5]

template<typename Value , typename IterCore >
souffle::detail::brie::TrieIterator< Value, IterCore >::TrieIterator ( )
default

◆ TrieIterator() [3/5]

template<typename Value , typename IterCore >
souffle::detail::brie::TrieIterator< Value, IterCore >::TrieIterator ( const TrieIterator< Value, IterCore > &  )
default

◆ TrieIterator() [4/5]

template<typename Value , typename IterCore >
souffle::detail::brie::TrieIterator< Value, IterCore >::TrieIterator ( TrieIterator< Value, IterCore > &&  )
default

◆ TrieIterator() [5/5]

template<typename Value , typename IterCore >
souffle::detail::brie::TrieIterator< Value, IterCore >::TrieIterator ( iter_core_arg_type  param)
inlineexplicit

Definition at line 1977 of file Brie.h.

1978 {

Member Function Documentation

◆ getNestedView()

template<typename Value , typename IterCore >
auto souffle::detail::brie::TrieIterator< Value, IterCore >::getNestedView ( )
inlineprivate

Definition at line 1960 of file Brie.h.

1961  : iter_core(std::move(param), value) {}
1962 
1963  // the equality operator as required by the iterator concept
1964  bool operator==(const TrieIterator& other) const {
1965  // equivalent if pointing to the same value

◆ operator!=()

template<typename Value , typename IterCore >
bool souffle::detail::brie::TrieIterator< Value, IterCore >::operator!= ( const TrieIterator< Value, IterCore > &  other) const
inline

Definition at line 1986 of file Brie.h.

1987  {
1988  auto cpy = *this;

◆ operator*()

template<typename Value , typename IterCore >
const Value& souffle::detail::brie::TrieIterator< Value, IterCore >::operator* ( ) const
inline

Definition at line 1990 of file Brie.h.

◆ operator++() [1/2]

template<typename Value , typename IterCore >
TrieIterator& souffle::detail::brie::TrieIterator< Value, IterCore >::operator++ ( )
inline

Definition at line 1998 of file Brie.h.

1998  {
1999  iter.print(out);
2000  return out;
2001  }

References souffle::detail::brie::TrieIterator< Value, IterCore >::print().

Here is the call graph for this function:

◆ operator++() [2/2]

template<typename Value , typename IterCore >
TrieIterator souffle::detail::brie::TrieIterator< Value, IterCore >::operator++ ( int  )
inline

Definition at line 2003 of file Brie.h.

2015  {

◆ operator->()

template<typename Value , typename IterCore >
const Value* souffle::detail::brie::TrieIterator< Value, IterCore >::operator-> ( ) const
inline

Definition at line 1994 of file Brie.h.

1994  {
1995  out << "iter(" << iter_core << " -> " << value << ")";
1996  }

◆ operator=() [1/2]

template<typename Value , typename IterCore >
TrieIterator& souffle::detail::brie::TrieIterator< Value, IterCore >::operator= ( const TrieIterator< Value, IterCore > &  )
default

◆ operator=() [2/2]

template<typename Value , typename IterCore >
TrieIterator& souffle::detail::brie::TrieIterator< Value, IterCore >::operator= ( TrieIterator< Value, IterCore > &&  )
default

◆ operator==()

template<typename Value , typename IterCore >
bool souffle::detail::brie::TrieIterator< Value, IterCore >::operator== ( const TrieIterator< Value, IterCore > &  other) const
inline

Definition at line 1980 of file Brie.h.

1982  {
1983  iter_core.inc(value);

◆ print()

template<typename Value , typename IterCore >
void souffle::detail::brie::TrieIterator< Value, IterCore >::print ( std::ostream &  out) const
inline

Definition at line 2010 of file Brie.h.

2015  {

Referenced by souffle::detail::brie::TrieIterator< Value, IterCore >::operator++().

Friends And Related Function Documentation

◆ fix_binding

template<typename Value , typename IterCore >
template<unsigned Len, unsigned Pos, unsigned Dimensions>
friend struct fix_binding
friend

Definition at line 1935 of file Brie.h.

◆ fix_first

template<typename Value , typename IterCore >
template<unsigned Pos, unsigned Dimensions>
friend struct fix_first
friend

Definition at line 1944 of file Brie.h.

◆ fix_first_nested

template<typename Value , typename IterCore >
template<unsigned Dimensions>
friend struct fix_first_nested
friend

Definition at line 1947 of file Brie.h.

◆ fix_lower_bound

template<typename Value , typename IterCore >
template<unsigned Dimensions>
friend struct fix_lower_bound
friend

Definition at line 1938 of file Brie.h.

◆ fix_upper_bound

template<typename Value , typename IterCore >
template<unsigned Dimensions>
friend struct fix_upper_bound
friend

Definition at line 1941 of file Brie.h.

◆ operator<<

template<typename Value , typename IterCore >
std::ostream& operator<< ( std::ostream &  out,
const TrieIterator< Value, IterCore > &  iter 
)
friend

Definition at line 2014 of file Brie.h.

2015  {
2016  Derived& impl() {
2017  return static_cast<Derived&>(*this);

◆ TrieIterator

template<typename Value , typename IterCore >
template<typename A , typename B >
friend class TrieIterator
friend

Definition at line 1950 of file Brie.h.

Field Documentation

◆ iter_core

template<typename Value , typename IterCore >
IterCore souffle::detail::brie::TrieIterator< Value, IterCore >::iter_core
private

Definition at line 1956 of file Brie.h.

◆ value

template<typename Value , typename IterCore >
Value souffle::detail::brie::TrieIterator< Value, IterCore >::value
private

Definition at line 1955 of file Brie.h.


The documentation for this class was generated from the following file:
souffle::detail::brie::TrieIterator::value
Value value
Definition: Brie.h:1955
souffle::detail::brie::TrieIterator::TrieIterator
friend class TrieIterator
Definition: Brie.h:1950
souffle::detail::brie::TrieIterator::iter_core
IterCore iter_core
Definition: Brie.h:1956
souffle::detail::brie::TrieIterator::operator==
bool operator==(const TrieIterator &other) const
Definition: Brie.h:1980