]> Git Server - tankstelle.git/commitdiff
improved javadoc
authorRobin Cheney <cheneyr@eternal.ddnss.de>
Mon, 10 Nov 2025 06:59:07 +0000 (07:59 +0100)
committerRobin Cheney <cheneyr@eternal.ddnss.de>
Mon, 10 Nov 2025 06:59:07 +0000 (07:59 +0100)
src/main/java/de/diejungsvondertanke/tankstelle/Fuel.java
src/main/java/de/diejungsvondertanke/tankstelle/FuelStation.java
src/main/java/de/diejungsvondertanke/tankstelle/FuelType.java
src/main/java/de/diejungsvondertanke/tankstelle/LargeFuelStation.java
src/main/java/de/diejungsvondertanke/tankstelle/Main.java
src/main/java/de/diejungsvondertanke/tankstelle/MediumFuelStation.java
src/main/java/de/diejungsvondertanke/tankstelle/Size.java
src/main/java/de/diejungsvondertanke/tankstelle/SmallFuelStation.java

index 3a37ff817f6709c5206ff22b00d79216606d69db..eab68e0d0b5a15f536a32939f7c6b17885a811b1 100644 (file)
@@ -6,9 +6,7 @@ package de.diejungsvondertanke.tankstelle;
  */
 public class Fuel {
     /**
-     * fuel type
-     * 
-     * @see de.diejungsvondertanke.tankstelle.FuelType FuelType
+     * {@link FuelType}
      */
     public final FuelType FUEL_TYPE;
 
@@ -28,15 +26,13 @@ public class Fuel {
     private float price;
 
     /**
-     * Constructor. Creates a Fuel instance. Is used in each constructor of all fuel
-     * station types
+     * Constructor. Creates a Fuel instance. Is used in each constructor of all
+     * {@link FuelStation fuel station} types
      * 
      * @param fuel_type     Fuel type for this instance
      * @param stored_amount Currently stored amount of fuel in L
      * @param capacity      Maximum fuel storage capacity in L
      * @param price         Retail price in € / L
-     * 
-     * @see de.diejungsvondertanke.tankstelle.FuelStation FuelStation
      */
     public Fuel(FuelType fuel_type, float stored_amount, float price, int capacity) {
         this.FUEL_TYPE = fuel_type;
index adcf1bf822dc71e7e67d7101283969079b30fb28..a98d46757accfeaee2030c2df66ab7a1e09900a3 100644 (file)
@@ -4,25 +4,27 @@ package de.diejungsvondertanke.tankstelle;
  * Abstract class.
  * All fuel station subtypes inherit from this class.
  * 
- * @see de.diejungsvondertanke.tankstelle.LargeFuelStation LargeFuelStation
- * @see de.diejungsvondertanke.tankstelle.MediumFuelStation MediumFuelStation
- * @see de.diejungsvondertanke.tankstelle.SmallFuelStation SmallFuelStation
+ * @see {@link LargeFuelStation
+ *      LargeFuelStation}
+ * @see {@link MediumFuelStation
+ *      MediumFuelStation}
+ * @see {@link SmallFuelStation
+ *      SmallFuelStation}
  */
 abstract class FuelStation {
     /**
-     * Number of employees of this fuel stations
+     * Number of employees of this fuel station
      */
     private byte number_of_employees;
     /**
-     * Fuel types and -amounts
+     * {@link Fuel} types and -amounts
      */
     public Fuel[] fuels;
 
     /**
-     * The size of a fuel station. Is more or less decorative, because you can infer
+     * The {@link Size} of a fuel station. Is more or less decorative, because you
+     * can infer
      * the size from the fuel station's type
-     * 
-     * @see de.diejungsvondertanke.tankstelle.Size Size
      */
     private Size size;
 
@@ -30,13 +32,12 @@ abstract class FuelStation {
      * Protected superconstructor for fuel stations
      * 
      * @param number_of_employees Number of employees working at this fuel station
-     * @param size                Size of the fuel station (see Size enum)
-     * @param fuels               Array of fuels of this fuel station
-     * @see de.diejungsvondertanke.tankstelle.LargeFuelStation LargeFuelStation
-     * @see de.diejungsvondertanke.tankstelle.MediumFuelStation MediumFuelStation
-     * @see de.diejungsvondertanke.tankstelle.SmallFuelStation SmallFuelStation
-     * @see de.diejungsvondertanke.tankstelle.Fuel Fuel
-     * @see de.diejungsvondertanke.tankstelle.Size Size
+     * @param size                {@link Size} of the fuel station (see {@link Size}
+     *                            enum)
+     * @param fuels               Array of {@link Fuel}s of this fuel station
+     * @see {@link LargeFuelStation LargeFuelStation}
+     * @see {@link MediumFuelStation MediumFuelStation}
+     * @see {@link SmallFuelStation SmallFuelStation}
      */
     protected FuelStation(byte number_of_employees, Size size, Fuel[] fuels) {
         this.number_of_employees = number_of_employees;
index ea9b3a30e13913550fe521e89a72f65512bd01f5..b6785e03fcfce417e896b982908ee5c455550f7d 100644 (file)
@@ -1,9 +1,7 @@
 package de.diejungsvondertanke.tankstelle;
 
 /**
- * Possible fuel types
- * 
- * @see de.diejungsvondertanke.tankstelle.Fuel Fuel
+ * Possible {@link Fuel fuel} types
  */
 public enum FuelType {
     /**
index 62b65207972653a61221f3856a10712ba610a973..43dc3522aa6e2df70cc19185ea9c158afe3dd423 100644 (file)
@@ -1,7 +1,7 @@
 package de.diejungsvondertanke.tankstelle;
 
 /**
- * Large fuel station
+ * Large {@link FuelStation fuel station}
  */
 public class LargeFuelStation extends FuelStation {
     /**
@@ -10,12 +10,10 @@ public class LargeFuelStation extends FuelStation {
     private String supermarket_company;
 
     /**
-     * Constructs large fuel stations
+     * Constructs large {@link FuelStation fuel station}s
      * 
      * @param supermarket_company The company managing the integrated supermarket
-     * @see de.diejungsvondertanke.tankstelle.LargeFuelStation#supermarket_company
-     *      supermarket_company
-     * @see de.diejungsvondertanke.tankstelle.FuelStation FuelStation
+     * @see {@link #supermarket_company}
      */
     public LargeFuelStation(String supermarket_company) {
         Fuel[] fuels = { new Fuel(FuelType.SUPER, 8000f, 0f, 16000),
@@ -28,15 +26,12 @@ public class LargeFuelStation extends FuelStation {
     }
 
     /**
-     * Constructs large fuel stations
+     * Constructs large {@link FuelStation fuel station}s
      * 
      * @param supermarket_company The company managing the integrated supermarket
      * @param number_of_employees Number of employees
-     * @see de.diejungsvondertanke.tankstelle.LargeFuelStation#supermarket_company
-     *      supermarket_company
-     * @see de.diejungsvondertanke.tankstelle.FuelStation FuelStation
-     * @see de.diejungsvondertanke.tankstelle.FuelStation#number_of_employees
-     *      number_of_employees
+     * @see {@link #supermarket_company}
+     * @see {@link FuelStation#number_of_employees}
      */
     public LargeFuelStation(String supermarket_company, byte number_of_employees) {
         Fuel[] fuels = { new Fuel(FuelType.SUPER, 8000f, 0f, 16000),
index 2b305bb060b182dc760515a39a1b1a6317da32ea..a49fa88ae5d6751147be56fd81f026af7ef742dd 100644 (file)
@@ -5,7 +5,7 @@ package de.diejungsvondertanke.tankstelle;
  */
 public class Main {
     /**
-     * (Initial) array of all fuel stations
+     * (Initial) array of all {@link FuelStation}s
      */
     static FuelStation[] fuelStations = { new SmallFuelStation((short) 0), new SmallFuelStation((short) 0),
             new MediumFuelStation(0), new MediumFuelStation(0), new MediumFuelStation(0),
index 15b5026a25b486bcf6d7a220378da5f2f1456c5c..9266a9089f623cdffae8410a06435b04ab693076 100644 (file)
@@ -1,7 +1,7 @@
 package de.diejungsvondertanke.tankstelle;
 
 /**
- * Medium fuel station
+ * Medium {@link FuelStation fuel station}
  */
 public class MediumFuelStation extends FuelStation {
     /**
@@ -10,12 +10,10 @@ public class MediumFuelStation extends FuelStation {
     private int retail_space;
 
     /**
-     * Constructs large fuel stations
+     * Constructs medium {@link FuelStation fuel station}s
      * 
      * @param retail_space m² of retail space
-     * @see de.diejungsvondertanke.tankstelle.MediumFuelStation#retail_space
-     *      retail_space
-     * @see de.diejungsvondertanke.tankstelle.FuelStation FuelStation
+     * @see {@link #retail_space}
      */
     public MediumFuelStation(int retail_space) {
         Fuel[] fuels = { new Fuel(FuelType.SUPER, 6000f, 0f, 12000),
@@ -27,15 +25,12 @@ public class MediumFuelStation extends FuelStation {
     }
 
     /**
-     * Constructs large fuel stations
+     * Constructs medium {@link FuelStation fuel station}s
      * 
      * @param retail_space        m² of retail space
      * @param number_of_employees Number of employees
-     * @see de.diejungsvondertanke.tankstelle.MediumFuelStation#retail_space
-     *      retail_space
-     * @see de.diejungsvondertanke.tankstelle.FuelStation FuelStation
-     * @see de.diejungsvondertanke.tankstelle.FuelStation#number_of_employees
-     *      number_of_employees
+     * @see {@link #retail_space}
+     * @see {@link FuelStation#number_of_employees}
      */
     public MediumFuelStation(int retail_space, byte number_of_employees) {
         Fuel[] fuels = { new Fuel(FuelType.SUPER, 6000f, 0f, 12000),
index c137351e916fc5511380866626b6329ade26e444..e9c4c182bc89739922a60dcd8ff51fca05dc1779 100644 (file)
@@ -1,20 +1,26 @@
 package de.diejungsvondertanke.tankstelle;
 
 /**
- * The size of a fuel station. Is more or less decorative, because you can infer
+ * The size of a {@link FuelStation fuel station}. Is more or less decorative,
+ * because you
+ * can infer
  * the size from the fuel station's type
+ * 
+ * @see {@link LargeFuelStation}
+ * @see {@link MediumFuelStation}
+ * @see {@link SmallFuelStation}
  */
 public enum Size {
     /**
-     * A large fuel station
+     * A {@link LargeFuelStation large fuel station}
      */
     LARGE,
     /**
-     * A medium fuel station
+     * A {@link MediumFuelStation medium fuel station}
      */
     MEDIUM,
     /**
-     * A small fuel station
+     * A {@link SmallFuelStation small fuel station}
      */
     SMALL
 }
index 9beb9db177bae450a35c55a93be6208107a0aa77..c069d149b0a2c08ccf13d0db621a5272ee3304c6 100644 (file)
@@ -1,7 +1,7 @@
 package de.diejungsvondertanke.tankstelle;
 
 /**
- * Small fuel station
+ * Small {@link FuelStation fuel station}
  */
 public class SmallFuelStation extends FuelStation {
     /**
@@ -10,12 +10,10 @@ public class SmallFuelStation extends FuelStation {
     private short number_of_vending_machines;
 
     /**
-     * Constructs small fuel stations
+     * Constructs small {@link FuelStation fuel station}s
      * 
      * @param number_of_vending_machines Number of drink vending machines
-     * @see de.diejungsvondertanke.tankstelle.SmallFuelStation#number_of_vending_machines
-     *      number_of_vending_machines
-     * @see de.diejungsvondertanke.tankstelle.FuelStation FuelStation
+     * @see {@link #number_of_vending_machines}
      */
     public SmallFuelStation(short number_of_vending_machines) {
         Fuel[] fuels = { new Fuel(FuelType.SUPER, 4000f, 0f, 8000),
@@ -25,15 +23,12 @@ public class SmallFuelStation extends FuelStation {
     }
 
     /**
-     * Constructs small fuel stations
+     * Constructs small {@link FuelStation fuel station}s
      * 
      * @param number_of_vending_machines Number of drink vending machines
      * @param number_of_employees        Number of employees
-     * @see de.diejungsvondertanke.tankstelle.SmallFuelStation#number_of_vending_machines
-     *      number_of_vending_machines
-     * @see de.diejungsvondertanke.tankstelle.FuelStation FuelStation
-     * @see de.diejungsvondertanke.tankstelle.FuelStation#number_of_employees
-     *      number_of_employees
+     * @see {@link #number_of_vending_machines}
+     * @see {@link FuelStation#number_of_employees}
      */
     public SmallFuelStation(short number_of_vending_machines, byte number_of_employees) {
         Fuel[] fuels = { new Fuel(FuelType.SUPER, 4000f, 0f, 8000),