Z3
Public Member Functions
ast_vector_tpl< T >::iterator Class Referencefinal

Public Member Functions

 iterator (ast_vector_tpl const *v, unsigned i)
 
bool operator== (iterator const &other) const noexcept
 
bool operator!= (iterator const &other) const noexcept
 
iteratoroperator++ () noexcept
 
void set (T &arg)
 
iterator operator++ (int) noexcept
 
T * operator-> () const
 
operator* () const
 

Detailed Description

template<typename T>
class z3::ast_vector_tpl< T >::iterator

Definition at line 613 of file z3++.h.

Constructor & Destructor Documentation

◆ iterator()

iterator ( ast_vector_tpl const *  v,
unsigned  i 
)
inline

Definition at line 617 of file z3++.h.

617 : m_vector(v), m_index(i) {}

Member Function Documentation

◆ operator!=()

bool operator!= ( iterator const &  other) const
inlinenoexcept

Definition at line 622 of file z3++.h.

622  {
623  return other.m_index != m_index;
624  };

◆ operator*()

T operator* ( ) const
inline

Definition at line 634 of file z3++.h.

634 { return (*m_vector)[m_index]; }

Referenced by ast_vector_tpl< T >::iterator::operator->().

◆ operator++() [1/2]

iterator& operator++ ( )
inlinenoexcept

Definition at line 625 of file z3++.h.

625  {
626  ++m_index;
627  return *this;
628  }

◆ operator++() [2/2]

iterator operator++ ( int  )
inlinenoexcept

Definition at line 632 of file z3++.h.

632 { iterator tmp = *this; ++m_index; return tmp; }
iterator(ast_vector_tpl const *v, unsigned i)
Definition: z3++.h:617

◆ operator->()

T* operator-> ( ) const
inline

Definition at line 633 of file z3++.h.

633 { return &(operator*()); }

◆ operator==()

bool operator== ( iterator const &  other) const
inlinenoexcept

Definition at line 619 of file z3++.h.

619  {
620  return other.m_index == m_index;
621  };

◆ set()

void set ( T &  arg)
inline

Definition at line 629 of file z3++.h.

629  {
630  Z3_ast_vector_set(m_vector->ctx(), *m_vector, m_index, arg);
631  }
context & ctx() const
Definition: z3++.h:463
void Z3_API Z3_ast_vector_set(Z3_context c, Z3_ast_vector v, unsigned i, Z3_ast a)
Update position i of the AST vector v with the AST a.