-
Notifications
You must be signed in to change notification settings - Fork 35
T_CodeJam_Ranges_CompositeRange_1
Andrew Koryavchenko edited this page Jul 4, 2017
·
3 revisions
Describes a composite range that contains some subranges.
Namespace: CodeJam.Ranges
Assembly: CodeJam (in CodeJam.dll) Version: 1.1.0.0 (1.1.0.0)
C#
[SerializableAttribute]
public struct CompositeRange<T> : IEquatable<CompositeRange<T>>,
IFormattable, ICompositeRange<T>
VB
<SerializableAttribute>
Public Structure CompositeRange(Of T)
Implements IEquatable(Of CompositeRange(Of T)), IFormattable,
ICompositeRange(Of T)
F#
[<SealedAttribute>]
[<SerializableAttribute>]
type CompositeRange<'T> =
struct
interface IEquatable<CompositeRange<'T>>
interface IFormattable
interface ICompositeRange<'T>
end
- T
- The type of the value. Should implement or .
Name | Description | |
---|---|---|
CompositeRange(T)(Range(T)) | Creates instance of . | |
CompositeRange(T)(IEnumerable(Range(T))) | Creates instance of . |
Name | Description | |
---|---|---|
ContainingRange | Range that contains all subranges. | |
IsEmpty | The composite range is empty, ∅. | |
IsMerged | The composite range cannot be simplified anymore. Subranges do not intersect and start one exactly after another. | |
IsNotEmpty | The composite range is NOT empty, ≠ ∅ | |
SubRanges | Collection of subranges. |
Name | Description | |
---|---|---|
Equals(Object) | Indicates whether the current range and a specified object are equal. (Overrides ValueType.Equals(Object).) | |
Equals(CompositeRange(T)) | Indicates whether the current range is equal to another. | |
GetHashCode | Returns a hash code for the current range. (Overrides ValueType.GetHashCode().) | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
Merge | Returns simplified composite range. Adjacent ranges with same keys will be merged. | |
ToString() | Returns string representation of the range. (Overrides ValueType.ToString().) | |
ToString(IFormatProvider) | Returns string representation of the range using the specified format string. If T does not implement the format string is ignored. | |
ToString(String) | Returns string representation of the range using the specified format string. If T does not implement the format string is ignored. | |
ToString(String, IFormatProvider) | Returns string representation of the range using the specified format string. If T does not implement the format string is ignored. |
Name | Description | |
---|---|---|
Equality | Implements the operator ==. | |
Inequality | Implements the operator !=. |
Name | Description | |
---|---|---|
Empty | Empty range, ∅ | |
Infinite | Infinite range, (-∞..+∞) |
Name | Description | |
---|---|---|
Contains(T)(T) | Overloaded. Determines whether the composite range contains the specified value. (Defined by CompositeRangeExtensions.) |
|
Contains(T)(Range(T)) | Overloaded. Determines whether the composite range contains another range. (Defined by CompositeRangeExtensions.) |
|
Contains(T)(RangeBoundaryFrom(T)) | Overloaded. Determines whether the composite range contains the specified range boundary. (Defined by CompositeRangeExtensions.) |
|
Contains(T)(RangeBoundaryTo(T)) | Overloaded. Determines whether the composite range contains the specified range boundary. (Defined by CompositeRangeExtensions.) |
|
Contains(T)(T, T) | Overloaded. Determines whether the composite range contains another range. (Defined by CompositeRangeExtensions.) |
|
Contains(T, TCompositeRange)(TCompositeRange) | Overloaded. Determines whether the composite range contains another range. (Defined by CompositeRangeExtensions.) |
|
Contains(T, TKey2)(Range(T, TKey2)) | Overloaded. Determines whether the composite range contains another range. (Defined by CompositeRangeExtensions.) |
|
Except(T)(Range(T)) | Overloaded. Returns source range with other range excluded. (Defined by CompositeRangeExtensions.) |
|
Except(T)(T, T) | Overloaded. Returns source range with other range excluded. (Defined by CompositeRangeExtensions.) |
|
Except(T, TCompositeRange)(TCompositeRange) | Overloaded. Returns source range with other range excluded. (Defined by CompositeRangeExtensions.) |
|
Except(T, TKey2)(Range(T, TKey2)) | Overloaded. Returns source range with other range excluded. (Defined by CompositeRangeExtensions.) |
|
ExtendFrom(T)(T) | Overloaded. Extends the range from the left. (Defined by CompositeRangeExtensions.) |
|
ExtendFrom(T)(RangeBoundaryFrom(T)) | Overloaded. Extends the range from the left. (Defined by CompositeRangeExtensions.) |
|
ExtendTo(T)(T) | Overloaded. Extends the range from the right. (Defined by CompositeRangeExtensions.) |
|
ExtendTo(T)(RangeBoundaryTo(T)) | Overloaded. Extends the range from the right. (Defined by CompositeRangeExtensions.) |
|
GetComplementation(T) | Returns complementation composite range. Result range contains result of (infinityRange.Exclude(compositeRange). (Defined by CompositeRangeExtensions.) | |
GetIntersection(T)(T) | Overloaded. Returns ranges that has intersections with passed range. (Defined by CompositeRangeExtensions.) |
|
GetIntersection(T)(Range(T)) | Overloaded. Returns ranges that has intersections with passed range. (Defined by CompositeRangeExtensions.) |
|
GetIntersection(T)(T, T) | Overloaded. Returns ranges that has intersections with passed range. (Defined by CompositeRangeExtensions.) |
|
GetIntersection(T, TKey2)(Range(T, TKey2)) | Overloaded. Returns ranges that has intersections with passed range. (Defined by CompositeRangeExtensions.) |
|
GetIntersections(T) | Returns all range intersections from the composite range. (Defined by CompositeRangeExtensions.) | |
HasIntersection(T)(Range(T)) | Overloaded. Determines whether the composite range has intersection with another range. (Defined by CompositeRangeExtensions.) |
|
HasIntersection(T)(T, T) | Overloaded. Determines whether the composite has intersection with another range. (Defined by CompositeRangeExtensions.) |
|
HasIntersection(T, TCompositeRange)(TCompositeRange) | Overloaded. Determines whether the composite range has intersection with another range. (Defined by CompositeRangeExtensions.) |
|
HasIntersection(T, TKey2)(Range(T, TKey2)) | Overloaded. Determines whether the composite range has intersection with another range. (Defined by CompositeRangeExtensions.) |
|
Intersect(T)(Range(T)) | Overloaded. Returns an intersection of the the ranges. (Defined by CompositeRangeExtensions.) |
|
Intersect(T)(T, T) | Overloaded. Returns an intersection of the the ranges. (Defined by CompositeRangeExtensions.) |
|
Intersect(T, TCompositeRange)(TCompositeRange) | Overloaded. Returns an intersection of the the ranges. (Defined by CompositeRangeExtensions.) |
|
Intersect(T, TKey2)(Range(T, TKey2)) | Overloaded. Returns an intersection of the the ranges. (Defined by CompositeRangeExtensions.) |
|
MakeExclusive(T) | Replaces inclusive boundaries with exclusive ones with the values from the selector callbacks (Defined by CompositeRangeExtensions.) | |
MakeInclusive(T) | Replaces exclusive boundaries with inclusive ones with the values from the selector callbacks (Defined by CompositeRangeExtensions.) | |
TrimFrom(T)(T) | Overloaded. Trims the range from the left. (Defined by CompositeRangeExtensions.) |
|
TrimFrom(T)(RangeBoundaryFrom(T)) | Overloaded. Trims the range from the left. (Defined by CompositeRangeExtensions.) |
|
TrimTo(T)(T) | Overloaded. Trims the range from the right. (Defined by CompositeRangeExtensions.) |
|
TrimTo(T)(RangeBoundaryTo(T)) | Overloaded. Trims the range from the right. (Defined by CompositeRangeExtensions.) |
|
Union(T)(CompositeRange(T)) | Overloaded. Returns a union range containing all subranges. (Defined by CompositeRangeExtensions.) |
|
Union(T)(Range(T)) | Overloaded. Returns a union range containing all subranges. (Defined by CompositeRangeExtensions.) |
|
WithKeys(T, TKey2) | Creates a new composite range with the key specified. (Defined by CompositeRangeExtensions.) | |
WithValues(T, T2)(Func(T, T2)) | Overloaded. Creates a new composite range with the key specified. (Defined by CompositeRangeExtensions.) |
|
WithValues(T, T2)(Func(T, T2), Func(T, T2)) | Overloaded. Creates a new composite range with the key specified. (Defined by CompositeRangeExtensions.) |
CodeJam.Ranges Namespace
System.IComparable(T)
System.IComparable