TimeIntervalCollectionTIntersect Method (TimeIntervalT, IEqualityComparerT) |
Computes the intersection of this interval collection with an interval.
Namespace:
AGI.Foundation.Time
Assembly:
AGI.Foundation.Core (in AGI.Foundation.Core.dll) Version: 24.2.419.0 (24.2.419.0)
Syntax public TimeIntervalCollection<T> Intersect(
TimeInterval<T> interval,
IEqualityComparer<T> dataComparer
)
Public Function Intersect (
interval As TimeInterval(Of T),
dataComparer As IEqualityComparer(Of T)
) As TimeIntervalCollection(Of T)
public:
TimeIntervalCollection<T>^ Intersect(
TimeInterval<T>^ interval,
IEqualityComparer<T>^ dataComparer
)
member Intersect :
interval : TimeInterval<'T> *
dataComparer : IEqualityComparer<'T> -> TimeIntervalCollection<'T>
Parameters
- interval
- Type: AGI.Foundation.TimeTimeIntervalT
The interval to intersect with this collection - dataComparer
- Type: System.Collections.GenericIEqualityComparerT
The object to use to compare the Data properties of intervals.
Return Value
Type:
TimeIntervalCollectionTThe intersection of this collection with the interval.
Remarks
The returned collection will only contain the intervals that are in both collections.
If two intervals in the two collections overlap but have different
Data,
the overlapping part will NOT be included in the resulting collection.
See Also