Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • Orekit Orekit
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 90
    • Issues 90
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 16
    • Merge requests 16
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Orekit
  • OrekitOrekit
  • Issues
  • #609
Closed
Open
Created Sep 26, 2019 by Yannick Jeandroz@yannick.jeandrozDeveloper

Add comparison methods in AbsoluteDate to improve readability

During the discussion here, the community has decided that some new comparison methods in the class AbsoluteDate and FieldAbsoluteDate would help users of Orekit to write more readable code.

List of new methods to create in class AbsoluteDate and FieldAbsoluteDate (with TimeStamped replaced by FieldTimeStamped for FieldAbsoluteDate):

  • isEqualTo(TimeStamped t): true if instance equals t.getDate()
  • isCloseTo(TimeStamped t, double tolerance): true if t.getDate() is separated from instance by less than tolerance seconds.
  • isBefore(TimeStamped t): true if instance is strictly before t.getDate()
  • isAfter(TimeStamped t): true if instance is strictly after t.getDate()
  • isBeforeOrEqualTo(TimeStamped t): true if instance is simultaneous or before t.getDate()
  • isAfterOrEqualTo(TimeStamped t): true if instance is simultaneous or after t.getDate()
  • isBetween(TimeStamped t1, TimeStamped t2): true if instance is strictly between t1.getDate() and t2.getDate(). t1 and t2 can be in any chronological order, but if they represent the same instant this will always return false.
  • isBetweenOrEqualTo(TimeStamped t1, TimeStamped t2): true if instance is strictly between t1.getDate() and t2.getDate(). t1 and t2 can be in any chronological order
Edited Sep 27, 2019 by Yannick Jeandroz
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking