Types and functions for iterating on the disjuncts of a ppl_Pointset_Powerset_C_Polyhedron_tag.
More...
#include <C_interface.dox.h>
Types and functions for iterating on the disjuncts of a ppl_Pointset_Powerset_C_Polyhedron_tag.
◆ ppl_new_Pointset_Powerset_C_Polyhedron_iterator()
Builds a new iterator and writes a handle to it at address pit.
- Parameters
-
| pit | Receives the newly allocated object handle; release it with the matching deletion function. |
- Returns
- Zero on success; a negative error code on failure.
◆ ppl_new_Pointset_Powerset_C_Polyhedron_iterator_from_iterator()
Builds a copy of y and writes a handle to it at address pit.
- Parameters
-
| pit | Receives the newly allocated object handle; release it with the matching deletion function. |
| y | The borrowed handle to the input object. |
- Returns
- Zero on success; a negative error code on failure.
◆ ppl_Pointset_Powerset_C_Polyhedron_iterator_begin()
Assigns to psit an iterator "pointing" to the beginning of the sequence of disjuncts of ps.
- Parameters
-
| ps | The powerset operand. |
| psit | The iterator handle selecting the current element. |
- Returns
- Zero on success; a negative error code on failure.
◆ ppl_Pointset_Powerset_C_Polyhedron_iterator_end()
Assigns to psit an iterator "pointing" past the end of the sequence of disjuncts of ps.
- Parameters
-
| ps | The powerset operand. |
| psit | The iterator handle selecting the current element. |
- Returns
- Zero on success; a negative error code on failure.
◆ ppl_delete_Pointset_Powerset_C_Polyhedron_iterator()
Invalidates the handle it: this makes sure the corresponding resources will eventually be released.
- Parameters
-
| it | The borrowed handle to the input object. |
- Returns
- Zero on success; a negative error code on failure.
◆ ppl_Pointset_Powerset_C_Polyhedron_iterator_dereference()
Dereferences it writing a const handle to the resulting disjunct at address d.
- Note
- Even though
it is an non-const iterator, dereferencing it results in a handle to a const disjunct. This is because mutable iterators are meant to allow for the modification of the sequence of disjuncts (e.g., by dropping elements), while preventing direct modifications of the disjuncts they point to.
- Warning
- The iterator must refer to a disjunct, not the end of the powerset. The non-null result is borrowed from the powerset and must not be modified or deleted. It remains valid only while the powerset and its owners are alive and until another operation on an owning object, including const operations, may invalidate it. Obtaining begin/end iterators and ordinary iterator traversal do not invalidate it. Read-only inspection of the disjunct is permitted, subject to the lifetime rules of any handles borrowed in turn from that disjunct; see Borrowed Domain Systems. Copy the disjunct with the matching ppl_new_C_Polyhedron_from_C_Polyhedron constructor if an independent lifetime is needed. On failure,
*d is unchanged.
- Parameters
-
| it | The borrowed handle to the input object. |
| d | The borrowed handle to the input object. |
- Returns
- Zero on success; a negative error code on failure.
◆ ppl_Pointset_Powerset_C_Polyhedron_iterator_increment()
Increments it so that it "points" to the next disjunct.
- Parameters
-
| it | The iterator handle selecting the current element. |
- Returns
- Zero on success; a negative error code on failure.
◆ ppl_Pointset_Powerset_C_Polyhedron_iterator_decrement()
Decrements it so that it "points" to the previous disjunct.
- Parameters
-
| it | The iterator handle selecting the current element. |
- Returns
- Zero on success; a negative error code on failure.
◆ ppl_Pointset_Powerset_C_Polyhedron_iterator_equal_test()
Returns a positive integer if the iterators corresponding to x and y are equal; returns 0 if they are different.
- Parameters
-
| x | The borrowed handle to the input object. |
| y | The borrowed handle to the input object. |
- Returns
- A positive integer if the iterators corresponding to
x and y are equal; returns 0 if they are different.
The documentation for this interface was generated from the following file: