org.orekit.attitudes
Class AttitudeChronologicalComparator

java.lang.Object
  extended by org.orekit.attitudes.AttitudeChronologicalComparator
All Implemented Interfaces:
Serializable, Comparator<Attitude>

public final class AttitudeChronologicalComparator
extends Object
implements Comparator<Attitude>, Serializable

This class is a comparator used to compare the Attitude objects in the ephemeris set. This comparators allows two identical attitudes ephemeris to be kept in the set; this feature is important to compute two ephemeris at the attitude transition points.

Since:
1.3
Version:
$Id: AttitudeChronologicalComparator.java 17582 2017-05-10 12:58:16Z bignon $
Author:
Tiziana Sabatini
See Also:
AbstractAttitudeEphemerisGenerator, TwoSpinBiasSlew, Serialized Form
Concurrency :
immutable

Constructor Summary
AttitudeChronologicalComparator()
          Simple constructor.
 
Method Summary
 int compare(Attitude o1, Attitude o2)
          Compare two Attitude instances.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Constructor Detail

AttitudeChronologicalComparator

public AttitudeChronologicalComparator()
Simple constructor.

Method Detail

compare

public int compare(Attitude o1,
                   Attitude o2)
Compare two Attitude instances.

Specified by:
compare in interface Comparator<Attitude>
Parameters:
o1 - first Attitude instance
o2 - second Attitude instance
Returns:
a negative integer or a positive integer as the first instance is before or after the second one. If the two instances are simultaneous, returns 1 (to avoid deleting attitude instances in the ephemeris set).


Copyright © 2017 CNES. All Rights Reserved.