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

#include <z3++.h>

Public Member Functions

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

Detailed Description

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

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

Constructor & Destructor Documentation

◆ iterator() [1/2]

iterator ( ast_vector_tpl const *  v,
unsigned  i 
)
inline

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

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

◆ iterator() [2/2]

iterator ( iterator const &  other)
inline

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

1897: m_vector(other.m_vector), m_index(other.m_index) {}

Member Function Documentation

◆ operator!=()

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

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

1903 {
1904 return other.m_index != m_index;
1905 };

◆ operator*()

T operator* ( ) const
inline

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

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

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

◆ operator++() [1/2]

iterator & operator++ ( )
inline

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

1906 {
1907 ++m_index;
1908 return *this;
1909 }

◆ operator++() [2/2]

iterator operator++ ( int  )
inline

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

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

◆ operator->()

T * operator-> ( ) const
inline

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

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

◆ operator=()

iterator operator= ( iterator const &  other)
inline

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

1898{ m_vector = other.m_vector; m_index = other.m_index; return *this; }

◆ operator==()

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

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

1900 {
1901 return other.m_index == m_index;
1902 };

◆ set()

void set ( T &  arg)
inline

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

1910 {
1911 Z3_ast_vector_set(m_vector->ctx(), *m_vector, m_index, arg);
1912 }
context & ctx() const
Definition: z3++.h:406
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.