From 7fedbe9688a45b7b46637e083e51c5d8bc70e981 Mon Sep 17 00:00:00 2001 From: Nicolas Payette Date: Fri, 15 Nov 2024 18:36:02 +0000 Subject: [PATCH] remove the "Factory" suffix from a few field names --- .../agents/fisheables/CurrentCellFisheableFactory.java | 4 ++-- .../uk/ac/ox/poseidon/agents/vessels/VesselFactory.java | 4 ++-- .../ac/ox/poseidon/core/time/RelativeDateTimeFactory.java | 8 ++++---- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/agents/src/main/java/uk/ac/ox/poseidon/agents/fisheables/CurrentCellFisheableFactory.java b/agents/src/main/java/uk/ac/ox/poseidon/agents/fisheables/CurrentCellFisheableFactory.java index 0d8af1d90..c124a6128 100644 --- a/agents/src/main/java/uk/ac/ox/poseidon/agents/fisheables/CurrentCellFisheableFactory.java +++ b/agents/src/main/java/uk/ac/ox/poseidon/agents/fisheables/CurrentCellFisheableFactory.java @@ -40,13 +40,13 @@ public class CurrentCellFisheableFactory> extends VesselScopeFactory>> { - private Factory> fisheableGridFactory; + private Factory> fisheableGrid; @Override protected Supplier> newInstance( final Simulation simulation, final Vessel vessel ) { - return new CurrentCellFisheable<>(vessel, fisheableGridFactory.get(simulation)); + return new CurrentCellFisheable<>(vessel, fisheableGrid.get(simulation)); } } diff --git a/agents/src/main/java/uk/ac/ox/poseidon/agents/vessels/VesselFactory.java b/agents/src/main/java/uk/ac/ox/poseidon/agents/vessels/VesselFactory.java index c22ca7d55..512dae388 100644 --- a/agents/src/main/java/uk/ac/ox/poseidon/agents/vessels/VesselFactory.java +++ b/agents/src/main/java/uk/ac/ox/poseidon/agents/vessels/VesselFactory.java @@ -40,7 +40,7 @@ public class VesselFactory implements Factory { @NonNull private BehaviourFactory initialBehaviour; @NonNull private Factory idSupplier; @NonNull private Factory vesselField; - @NonNull private Factory portFactory; + @NonNull private Factory homePort; @NonNull private Factory portGrid; private double speed; @@ -50,7 +50,7 @@ public final Vessel get(final Simulation simulation) { final var vessel = new Vessel( idSupplier.get(simulation).nextId(), portGrid.get(simulation), - portFactory.get(simulation), + homePort.get(simulation), speed, vesselField, new ForwardingEventManager(simulation.getEventManager()) diff --git a/core/src/main/java/uk/ac/ox/poseidon/core/time/RelativeDateTimeFactory.java b/core/src/main/java/uk/ac/ox/poseidon/core/time/RelativeDateTimeFactory.java index ef0a87c88..204e80451 100644 --- a/core/src/main/java/uk/ac/ox/poseidon/core/time/RelativeDateTimeFactory.java +++ b/core/src/main/java/uk/ac/ox/poseidon/core/time/RelativeDateTimeFactory.java @@ -32,14 +32,14 @@ @EqualsAndHashCode(callSuper = false) abstract class RelativeDateTimeFactory implements Factory { - @NonNull private Factory referenceDateTimeFactory; - @NonNull private Factory temporalAmountFactory; + @NonNull private Factory referenceDateTime; + @NonNull private Factory temporalAmount; @Override public LocalDateTime get(final Simulation simulation) { return operation( - referenceDateTimeFactory.get(simulation), - temporalAmountFactory.get(simulation) + referenceDateTime.get(simulation), + temporalAmount.get(simulation) ); }