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 13433 2015-05-19 12:04:49Z trapier $
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 © 2016 CNES. All Rights Reserved.