View Javadoc
1   package org.woehlke.computer.kurzweil.conwaysgameoflive.model.world;
2   
3   import lombok.*;
4   
5   import java.io.Serializable;
6   
7   /**
8    * © 2006 - 2008 Thomas Woehlke.
9    * @author Thomas Woehlke
10   *
11   * @see <a href="https://github.com/Computer-Kurzweil/conwaysgameoflife">Github Repository</a>
12   * @see <a href="https://java.woehlke.org/conwaysgameoflife/">Maven Project Repository</a>
13   */
14  @Getter
15  @Setter
16  @ToString
17  @EqualsAndHashCode
18  @NoArgsConstructor
19  @AllArgsConstructor
20  public class SimulatedEvolutionParameter implements Serializable {
21  
22      private static final long serialVersionUID = 242L;
23  
24      private int foodPerDay;
25      private int foodPerDayGardenOfEden;
26      private boolean gardenOfEdenEnabled;
27  
28      public void increaseFoodPerDay() {
29          this.foodPerDay++;
30      }
31  
32      public void decreaseFoodPerDay() {
33          this.foodPerDay--;
34      }
35  
36      public void toggleGardenOfEden() {
37        this.gardenOfEdenEnabled = ! this.gardenOfEdenEnabled;
38      }
39  
40  }