LanguageExt.Core

LanguageExt.Core DataTypes Range

Contents

class CharRange Source #

Methods

method CharRange FromMinMax (char min, char max) Source #

Construct a new range

Parameters

param from

The minimum value in the range

param to

The maximum value in the range

method CharRange FromCount (char from, int count) Source #

Construct a new range

Parameters

param from

The minimum value in the range

param count

The number of items in the range

class Range <SELF, MonoidOrdA, A> Source #

where SELF : Range<SELF, MonoidOrdA, A>
where MonoidOrdA : struct, Monoid<A>, Ord<A>, Arithmetic<A>

Represents a range of values

Parameters

type SELF

The type that is deriving from this type

type MonoidOrdA

Monoid of A class instance

type A

Bound values type

Fields

field A From Source #

First value in the range

field A To Source #

Last (inclusive) value in the range

field A Step Source #

Step size to the next item in the range

field bool StepIsAscending Source #

True if adding step to n makes the resulting value greater than n

Properties

property object Case Source #

Reference version for use in pattern-matching

Methods

method SELF FromMinMax (A min, A max, A step) Source #

Construct a new range

Parameters

param from

The minimum value in the range

param to

The maximum value in the range

param step

The size of each step in the range

method SELF FromCount (A min, A count, A step) Source #

Construct a new range

Parameters

param from

The minimum value in the range

param count

The number of items in the range

param step

The size of each step in the range

method bool InRange (A value) Source #

Returns true if the value provided is in range

Parameters

param value

Value to test

returns

True if the value provided is in range

method bool Overlaps (SELF other) Source #

Returns true if the range provided overlaps this range

Parameters

param other

The range to test

returns

True if the range provided overlaps this range

method Seq<A> ToSeq () Source #

method IEnumerable<A> AsEnumerable () Source #

method IEnumerator<A> GetEnumerator () Source #

method S Fold <S> (S state, Func<S, A, S> f) Source #