From e3ae9c6599cdec1aa4e91c4d36f83b97fc660fc2 Mon Sep 17 00:00:00 2001 From: Selim Eser <2211482@stud.hs-mannheim.de> Date: Sun, 9 Jun 2024 18:45:42 +0200 Subject: [PATCH] destination_details method implemented --- src/main/java/de/hs_mannheim/domain/System.java | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/main/java/de/hs_mannheim/domain/System.java b/src/main/java/de/hs_mannheim/domain/System.java index 28a32be..ea70f0f 100644 --- a/src/main/java/de/hs_mannheim/domain/System.java +++ b/src/main/java/de/hs_mannheim/domain/System.java @@ -113,7 +113,15 @@ public class System { } public String[] destination_details(String destination_zip){ - return new String[1]; + String[] result = new String[5]; + + result[0] = distance(destination_zip); // Entfernung + result[1] = travel_time(destination_zip)[0]; // Reisedauer Auto + result[2] = travel_time(destination_zip)[1]; // Reisedauer Fahrrad + result[3] = calc_l_consumption(destination_zip); // Kraftstoffverbrauch Auto + result[4] = weather_forecast(destination_zip); // Wettervorhersage für die nächsten 3 Tage + + return result; } public String current_weather(){