Skip to content

range.h

Baptiste Thémine edited this page Jul 5, 2020 · 9 revisions
#include <JLC/range.h>

Description

Definition of range-based iterable container class extending Collection.

The main purpose of class Range is to provide constructors to build an index-based set of elements by applying a specific operation such as incrementation from a begin value to an end value. Elements are accessible through the bracket operator [] at unique index within range starting from 0 to size-1. Zero-sized ranges are valid but cannot be dereferenced and infinite ranges are not valid. Once modifications are completed, a range can then be transformed into a stream to perform search and sorting operations.

Requirements

  • (Mandatory) <cstdio>, <cstdlib>, <iostream>, <iterator>, <stdexcept>, <JLC/debug.h>, <JLC/functions.h> and <JLC/collection.h> must be included.
  • (Optional) <functional> provides additional features from C++11.

Content

Name Description
class Range Defines the class Range and provides range methods.
namespace range Defines the namespace range and provides types, constants, exceptions and utility functions for rangemanipulation.

See also

Clone this wiki locally