Site set restricted w.r.t. More...
#include <p_if.hh>
Public Types | |
typedef p_if_piter_< typename S::bkd_piter, S, F > | bkd_piter |
Backward Site_Iterator associated type. | |
typedef Site_Set< void > | category |
typedef S::element | element |
Element associated type. | |
typedef p_if< S, F > | exact_t |
typedef p_if_piter_< typename S::fwd_piter, S, F > | fwd_piter |
Forward Site_Iterator associated type. | |
typedef fwd_piter | piter |
Site_Iterator associated type. | |
typedef S::psite | psite |
Psite associated type. | |
typedef subject< S::psite >::ret | site |
Site associated type. | |
Public Member Functions | |
bool | has (const psite &p) const |
Test if p belongs to the subset. | |
bool | is_empty () const |
Test if the site set is empty. | |
bool | is_valid () const |
Test if this site set is valid. | |
std::size_t | memory_size () const |
Return the size of this site set in memory. | |
const S & | overset () const |
Give the primary overset. | |
p_if () | |
Constructor without argument. | |
p_if (const S &s, const F &f) | |
Constructor with a site set s and a predicate f . | |
bool | pred (const psite &p) const |
Test predicate on point site p . | |
const F & | predicate () const |
Give the predicate function. | |
Protected Attributes | |
F | f_ |
S | s_ |
Private Types | |
typedef p_if< S, F > | self_ |
typedef internal::site_set_base_ < typename S::psite, self_ > | super_ |
Site set restricted w.r.t.
a predicate.
Parameter S
is a site set type; parameter F is a function from point to Boolean.
typedef p_if_piter_<typename S ::bkd_piter, S, F> mln::p_if< S, F >::bkd_piter |
Backward Site_Iterator associated type.
typedef Site_Set<void> mln::Site_Set< p_if< S, F > >::category [inherited] |
Reimplemented from mln::Object< p_if< S, F > >.
Element associated type.
typedef p_if< S, F > mln::Object< p_if< S, F > >::exact_t [inherited] |
typedef p_if_piter_<typename S ::fwd_piter, S, F> mln::p_if< S, F >::fwd_piter |
Forward Site_Iterator associated type.
Site_Iterator associated type.
typedef subject<S::psite >::ret mln::internal::site_set_base_< S::psite , p_if< S, F > >::site [inherited] |
Site associated type.
typedef internal::site_set_base_<typename S ::psite, self_> mln::p_if< S, F >::super_ [private] |
Constructor with a site set s
and a predicate f
.
Test if p
belongs to the subset.
References mln::p_if< S, F >::f_, and mln::p_if< S, F >::has().
Referenced by mln::p_if< S, F >::has().
bool mln::internal::site_set_base_< S::psite , p_if< S, F > >::is_empty | ( | ) | const [inherited] |
Test if the site set is empty.
This final method dispatches to is_empty_ whose default implementation relies on the 'nsites' method.
bool mln::p_if< S, F >::is_valid | ( | ) | const [inline] |
Test if this site set is valid.
std::size_t mln::p_if< S, F >::memory_size | ( | ) | const [inline] |
Return the size of this site set in memory.
const S & mln::p_if< S, F >::overset | ( | ) | const [inline] |
Give the primary overset.
Referenced by mln::p_if_piter_< Pi, S, F >::pi_change_target_().
Test predicate on point site p
.
References mln::p_if< S, F >::f_.
const F & mln::p_if< S, F >::predicate | ( | ) | const [inline] |
Give the predicate function.
Referenced by mln::p_if< S, F >::has(), and mln::p_if< S, F >::pred().