P4C
The P4 Compiler
Loading...
Searching...
No Matches
P4::Util::EnumeratorHandle< T > Class Template Reference

#include <enumerator.h>

Public Types

using difference_type = std::ptrdiff_t
 
using iterator_category = std::input_iterator_tag
 
using pointer = void
 
using reference = T
 
using value_type = T
 

Public Member Functions

bool operator!= (const EnumeratorHandle< T > &other) const
 
reference operator* () const
 
const EnumeratorHandle< T > & operator++ ()
 
bool operator== (const EnumeratorHandle< T > &other) const
 

Friends

template<typename U>
EnumeratorHandle< U > begin (const EnumeratorPtr< U > &enumerator)
 
template<typename U>
EnumeratorHandle< U > end (const EnumeratorPtr< U > &enumerator)
 

Detailed Description

template<typename T>
class P4::Util::EnumeratorHandle< T >

This class provides support for C++-style range for loops EnumeratorPtr<T> e; for (auto a : e) ...