org.orekit.utils
Class AbsoluteDateIntervalsList
java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractSet<E>
java.util.TreeSet<AbsoluteDateInterval>
org.orekit.utils.AbsoluteDateIntervalsList
- All Implemented Interfaces:
- Serializable, Cloneable, Iterable<AbsoluteDateInterval>, Collection<AbsoluteDateInterval>, NavigableSet<AbsoluteDateInterval>, Set<AbsoluteDateInterval>, SortedSet<AbsoluteDateInterval>
public class AbsoluteDateIntervalsList
- extends TreeSet<AbsoluteDateInterval>
This class represents a list of objects AbsoluteDateInterval
.
It extends a TreeSet of AbsoluteDateInterval
instances ; as the
AbsoluteDateInterval
objects implement the ComparableInterval
class, the list is an ordered collection of time intervals.
- Since:
- 1.1
- Version:
- $Id: AbsoluteDateIntervalsList.java 6012 2012-08-29 13:58:40Z TournebizeJ $
- Author:
- Tiziana Sabatini
- See Also:
AbsoluteDateInterval
,
TreeSet
,
Serialized Form- Concurrency :
- not thread-safe
- Concurrency comment :
- thread safety is not required for this class. And, TreeSet is not thread-safe.
Methods inherited from class java.util.TreeSet |
add, addAll, ceiling, clear, clone, comparator, contains, descendingIterator, descendingSet, first, floor, headSet, headSet, higher, isEmpty, iterator, last, lower, pollFirst, pollLast, remove, size, subSet, subSet, tailSet, tailSet |
AbsoluteDateIntervalsList
public AbsoluteDateIntervalsList()
getIntervalsContainingDate
public AbsoluteDateIntervalsList getIntervalsContainingDate(AbsoluteDate date)
- Gets the
AbsoluteDateIntervalsList
containing the specified date.
The list can contain zero, one or more AbsoluteDateInterval
.
- Parameters:
date
- the date included in the time intervals
- Returns:
- a list of time intervals containing the input date.
getInclusiveInterval
public AbsoluteDateInterval getInclusiveInterval()
- Gets the shortest interval containing all the intervals belonging to the list.
While a date included in at least one of the listed intervals must be contained in
this global interval, the opposite is not guaranteed (the inclusive interval can contain
dates that do not belong to any listed interval).
- Returns:
- an
AbsoluteDateInterval
including all the intervals of the list
getComplementaryIntervals
public AbsoluteDateIntervalsList getComplementaryIntervals()
- Gets the list of complementary intervals of the given list of intervals.
- Returns:
- an
AbsoluteDateIntervalsList
including all the complementary intervals
Copyright © 2016 CNES. All Rights Reserved.