Skip to content

Commit

Permalink
Merge pull request #841 from NASA-AMMOS/refactor/remove-vestigal-clas…
Browse files Browse the repository at this point in the history
…ses-merlin-server

Cleanup Merlin Code
  • Loading branch information
Mythicaeda authored Apr 18, 2023
2 parents 5d6955d + c082e8c commit f9cfe6f
Show file tree
Hide file tree
Showing 61 changed files with 93 additions and 2,109 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import java.util.PriorityQueue;
import java.util.Set;

public final class JobSchedule<JobRef, TimeRef extends DurationLike & Comparable<TimeRef>> {
public final class JobSchedule<JobRef, TimeRef extends SchedulingInstant> {
/** The scheduled time for each upcoming job. */
private final Map<JobRef, TimeRef> scheduledJobs = new HashMap<>();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@
import gov.nasa.jpl.aerie.merlin.protocol.types.Duration;

public record SchedulingInstant(Duration offsetFromStart, SubInstant priority)
implements DurationLike, Comparable<SchedulingInstant>
implements Comparable<SchedulingInstant>
{
@Override
public Duration project() {
return this.offsetFromStart;
}
Expand All @@ -14,10 +13,6 @@ public Duration project() {
public int compareTo(final SchedulingInstant o) {
final var x = this.offsetFromStart.compareTo(o.offsetFromStart);
if (x != 0) return x;

final var y = this.priority.compareTo(o.priority);
if (y != 0) return y;

return 0;
return this.priority.compareTo(o.priority);
}
}

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import gov.nasa.jpl.aerie.merlin.protocol.model.EffectTrait;

import java.util.Objects;
import java.util.Optional;
import java.util.function.Function;

/**
Expand Down