Skip to content

Commit

Permalink
change time format
Browse files Browse the repository at this point in the history
  • Loading branch information
rewertvsp committed Apr 17, 2024
1 parent 71f79bd commit 09f1e96
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@
import java.net.URISyntaxException;
import java.nio.file.Files;
import java.nio.file.Path;
import java.time.LocalDate;
import java.time.LocalTime;
import java.util.*;

import static org.matsim.core.controler.OutputDirectoryHierarchy.OverwriteFileSetting.overwriteExistingFiles;
Expand Down Expand Up @@ -448,7 +450,7 @@ private Config readAndCheckConfig(Path configPath, String modelName, String samp
if (output == null || output.toString().isEmpty())
config.controller().setOutputDirectory(Path.of(config.controller().getOutputDirectory()).resolve(modelName)
.resolve(usedSmallScaleCommercialTrafficType.toString() + "_" + sampleName + "pct" + "_"
+ java.time.LocalDate.now() + "_" + java.time.LocalTime.now().toSecondOfDay() + "_" + resistanceFactor)
+ LocalDate.now() + "_" + LocalTime.now().toSecondOfDay() + "_" + resistanceFactor)
.toString());
else
config.controller().setOutputDirectory(output.toString());
Expand Down

0 comments on commit 09f1e96

Please sign in to comment.