Main Page | Modules | Class Hierarchy | Class List | File List | Class Members

ltl::Range Class Reference

Class to enable referencing of ltl::MArray index ranges. More...

#include <range.h>

List of all members.

Public Member Functions

Static Public Member Functions


Detailed Description

Class to enable referencing of ltl::MArray index ranges.

A ltl::Range is a utility object used in the context of ltl::MArray describing a range of integers used for creating arrays and indexing an array along one dimension. For example, the set of indices {-10, -8, ..., 6, 8, 10} is represented by the object Range( -10, 10, 2 ).


Constructor & Destructor Documentation

ltl::Range::Range const int  first,
const int  last,
const int  stride = 1
[inline]
 

Construct a Range object.

The stride arguments defaults to 1 and may be omitted. last >= first is required.


Member Function Documentation

Range ltl::Range::all  )  [inline, static]
 

This static member returns a special Range object that represents the entire dimension, wherever used.

This is useful to refer to an entire dimension without having to figure out the actual size.

Range ltl::Range::operator+ const int  shift  )  const [inline]
 

Return a positive shifted Range object.

I.e. one whose lower and upper indices are higher by a number shift.

Range ltl::Range::operator- const int  shift  )  const [inline]
 

Return a negative shifted Range object.

I.e. one whose lower and upper indices are lower by a number shift.


The documentation for this class was generated from the following file:
Generated on Fri Dec 24 13:32:05 2004 for LTL by doxygen 1.3.4