$extrastylesheet
Olena  User documentation 2.1
An Image Processing Platform
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
mln::p_edges< G, F > Class Template Reference

#include <mln/core/site_set/p_edges.hh>

Public Member Functions

bool has (const psite &p) const
template<typename G2 >
bool has (const util::edge< G2 > &e) const
void invalidate ()
bool is_empty () const
bool is_valid () const
std::size_t memory_size () const
unsigned nedges () const
unsigned nsites () const
Constructors.
 p_edges ()
 p_edges (const Graph< G > &gr)
 p_edges (const Graph< G > &gr, const Function< F > &f)
template<typename F2 >
 p_edges (const Graph< G > &gr, const Function< F2 > &f)
Accessors.
const G & graph () const
const F & function () const

Public Types

typedef Site_Set< void > category
typedef util::edge< G > edge
typedef p_edges< G, F > exact_t
typedef F fun_t
typedef util::edge< G > graph_element
typedef G graph_t
typedef subject< F::result >::ret site
Associated types.
typedef super_::site element
typedef p_edges_psite< G, F > psite
typedef p_graph_piter< self_,
mln_edge_fwd_iter(G) > 
fwd_piter
typedef p_graph_piter< self_,
mln_edge_bkd_iter(G) > 
bkd_piter
typedef fwd_piter piter

Detailed Description

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
class mln::p_edges< G, F >

Site set mapping graph edges and image sites.

Definition at line 71 of file p_edges.hh.

Constructor & Destructor Documentation

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
mln::p_edges< G, F >::p_edges ( )

Default constructor.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
mln::p_edges< G, F >::p_edges ( const Graph< G > &  gr)

Construct a graph edge psite set from a graph.

Parameters
grThe graph upon which the graph edge psite set is built.
template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
mln::p_edges< G, F >::p_edges ( const Graph< G > &  gr,
const Function< F > &  f 
)

Construct a graph edge psite set from a graph and a function.

Parameters
grThe graph upon which the graph edge psite set is built.
fthe function mapping edges and sites.
template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
template<typename F2 >
mln::p_edges< G, F >::p_edges ( const Graph< G > &  gr,
const Function< F2 > &  f 
)

Construct a graph edge psite set from a graph and a function.

Parameters
grThe graph upon which the graph edge psite set is built.
fthe function mapping edges and sites. It must be convertible towards the function type F.

Member Function Documentation

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
const F& mln::p_edges< G, F >::function ( ) const

Return the mapping function.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
const G& mln::p_edges< G, F >::graph ( ) const

Return the graph associated to this site set.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
bool mln::p_edges< G, F >::has ( const psite p) const

Does this site set has site p?

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
template<typename G2 >
bool mln::p_edges< G, F >::has ( const util::edge< G2 > &  e) const

Does this site set has edge e?

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
void mln::p_edges< G, F >::invalidate ( )

Invalidate this site set.

bool mln::internal::site_set_base_< F::result , p_edges< G, 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.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
bool mln::p_edges< G, F >::is_valid ( ) const

Is this site set valid?

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
std::size_t mln::p_edges< G, F >::memory_size ( ) const

Does this site set has vertex_id? FIXME: causes ambiguities while calling has(mln::neighb_fwd_niter<>); bool has(unsigned vertex_id) const;.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
unsigned mln::p_edges< G, F >::nedges ( ) const

Return The number of edges in the graph.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
unsigned mln::p_edges< G, F >::nsites ( ) const

Return The number of points (sites) of the set, i.e., the number of edges.

Member Typedef Documentation

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
typedef p_graph_piter< self_, mln_edge_bkd_iter(G) > mln::p_edges< G, F >::bkd_piter

Backward Site_Iterator associated type.

Definition at line 132 of file p_edges.hh.

typedef Site_Set<void> mln::Site_Set< p_edges< G, F > >::category
inherited

Definition at line 74 of file core/concept/site_set.hh.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
typedef util::edge<G> mln::p_edges< G, F >::edge

Type of graph edge.

Definition at line 87 of file p_edges.hh.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
typedef super_ ::site mln::p_edges< G, F >::element

Element associated type.

Definition at line 123 of file p_edges.hh.

typedef p_edges< G, F > mln::Object< p_edges< G, F > >::exact_t
inherited

Definition at line 105 of file object.hh.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
typedef F mln::p_edges< G, F >::fun_t

Function associated type.

Definition at line 84 of file p_edges.hh.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
typedef p_graph_piter< self_, mln_edge_fwd_iter(G) > mln::p_edges< G, F >::fwd_piter

Forward Site_Iterator associated type.

Definition at line 129 of file p_edges.hh.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
typedef util::edge<G> mln::p_edges< G, F >::graph_element

Type of graph element this site set focuses on.

Definition at line 90 of file p_edges.hh.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
typedef G mln::p_edges< G, F >::graph_t

Graph associated type.

Definition at line 81 of file p_edges.hh.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
typedef fwd_piter mln::p_edges< G, F >::piter

Site_Iterator associated type.

Definition at line 135 of file p_edges.hh.

template<typename G, typename F = util::internal::id2element<G,util::edge<G> >>
typedef p_edges_psite<G, F> mln::p_edges< G, F >::psite

Point_Site associated type.

Definition at line 126 of file p_edges.hh.

typedef subject<F::result >::ret mln::internal::site_set_base_< F::result , p_edges< G, F > >::site
inherited

Site associated type.

Definition at line 58 of file site_set_base.hh.