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

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

Public Member Functions

 p_run ()
 p_run (const P &start, unsigned short len)
 p_run (const P &start, const P &end)
mln::box< P > bbox () const
end () const
bool has (const psite &p) const
bool has (const P &p) const
bool has_index (unsigned short i) const
void init (const P &start, unsigned short len)
bool is_empty () const
bool is_valid () const
unsigned short length () const
std::size_t memory_size () const
unsigned nsites () const
operator[] (unsigned short i) const
const P & start () const

Protected Attributes

unsigned len_
start_

Public Types

typedef p_run_bkd_piter_< P > bkd_piter
typedef Site_Set< void > category
typedef P element
typedef p_run< P > exact_t
typedef p_run_fwd_piter_< P > fwd_piter
typedef fwd_piter piter
typedef p_run_psite< P > psite
typedef mln::box< P > q_box
typedef subject< P >::ret site

Related Functions

(Note that these are not member functions.)

template<typename P >
std::ostream & operator<< (std::ostream &ostr, const p_run< P > &r)

Detailed Description

template<typename P>
class mln::p_run< P >

Point set class in run.

This is a mathematical set of points (not a multi-set). The parameter P shall be a Point type.

Definition at line 87 of file p_run.hh.

Constructor & Destructor Documentation

template<typename P>
mln::p_run< P >::p_run ( )

Constructor without argument.

template<typename P>
mln::p_run< P >::p_run ( const P &  start,
unsigned short  len 
)

Constructor.

template<typename P>
mln::p_run< P >::p_run ( const P &  start,
const P &  end 
)

Constructor.

Member Function Documentation

template<typename P>
mln::box<P> mln::p_run< P >::bbox ( ) const

Give the exact bounding box.

template<typename P>
P mln::p_run< P >::end ( ) const

Return (compute) the ending point.

template<typename P>
bool mln::p_run< P >::has ( const psite p) const

Test if p belongs to this point set.

template<typename P>
bool mln::p_run< P >::has ( const P &  p) const

Test if p belongs to this point set.

template<typename P>
bool mln::p_run< P >::has_index ( unsigned short  i) const

Test if index i belongs to this point set.

template<typename P>
void mln::p_run< P >::init ( const P &  start,
unsigned short  len 
)

Set the starting point.

bool mln::internal::site_set_base_< P, p_run< P > >::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 P>
bool mln::p_run< P >::is_valid ( ) const

Test if this run is valid, i.e., with length > 0.

template<typename P>
unsigned short mln::p_run< P >::length ( ) const

Give the length of the run.

template<typename P>
std::size_t mln::p_run< P >::memory_size ( ) const

Return the size of this site set in memory.

template<typename P>
unsigned mln::p_run< P >::nsites ( ) const

Give the number of sites.

template<typename P>
P mln::p_run< P >::operator[] ( unsigned short  i) const

Return the i-th point.

template<typename P>
const P& mln::p_run< P >::start ( ) const

Return the starting point.

Friends And Related Function Documentation

template<typename P >
std::ostream & operator<< ( std::ostream &  ostr,
const p_run< P > &  r 
)
related

Member Data Documentation

template<typename P>
unsigned mln::p_run< P >::len_
protected

The length of the run.

Definition at line 165 of file p_run.hh.

template<typename P>
P mln::p_run< P >::start_
protected

The first point of the run.

Definition at line 162 of file p_run.hh.

Member Typedef Documentation

template<typename P>
typedef p_run_bkd_piter_<P> mln::p_run< P >::bkd_piter

Backward Site_Iterator associated type.

Definition at line 102 of file p_run.hh.

typedef Site_Set<void> mln::Site_Set< p_run< P > >::category
inherited

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

template<typename P>
typedef P mln::p_run< P >::element

Element associated type.

Definition at line 92 of file p_run.hh.

typedef p_run< P > mln::Object< p_run< P > >::exact_t
inherited

Definition at line 105 of file object.hh.

template<typename P>
typedef p_run_fwd_piter_<P> mln::p_run< P >::fwd_piter

Forward Site_Iterator associated type.

Definition at line 99 of file p_run.hh.

template<typename P>
typedef fwd_piter mln::p_run< P >::piter

Site_Iterator associated type.

Definition at line 105 of file p_run.hh.

template<typename P>
typedef p_run_psite<P> mln::p_run< P >::psite

Psite associated type.

Definition at line 96 of file p_run.hh.

template<typename P>
typedef mln::box<P> mln::p_run< P >::q_box

Box associated type.

Definition at line 150 of file p_run.hh.

typedef subject<P>::ret mln::internal::site_set_base_< P, p_run< P > >::site
inherited

Site associated type.

Definition at line 58 of file site_set_base.hh.