refactoring

This commit is contained in:
Matthias Engelien
2024-09-15 12:41:39 +02:00
parent c311564ecc
commit cbd6d373bb
5 changed files with 62 additions and 19 deletions

View File

@@ -2,6 +2,7 @@ package de.etecture.ga.model;
import java.time.Duration;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
import org.springframework.data.annotation.Id;
@@ -40,6 +41,10 @@ public class Garage {
}
return this;
}
public List<Appointment> appointmentsSorted() {
return this.appointments.stream().sorted().toList();
}
public Garage addService(MDService service) {
garageServices.add(createGarageService(service, null));