Class TickingLocation

java.lang.Object
io.github.apfelcreme.Pipes.LoopDetection.TickingLocation
All Implemented Interfaces:
Comparable<TickingLocation>

public class TickingLocation extends Object implements Comparable<TickingLocation>
  • Constructor Details

    • TickingLocation

      public TickingLocation(SimpleLocation location, int timeTicked)
  • Method Details

    • getLocation

      public SimpleLocation getLocation()
      returns the location
      Returns:
      the location
    • getTimesTicked

      public int getTimesTicked()
      returns the time the location was found already
      Returns:
      the time the location was found
    • increment

      public void increment()
      increases the counter
    • compareTo

      public int compareTo(TickingLocation other)
      compares this tickingLocation to another tickingLocation
      Specified by:
      compareTo in interface Comparable<TickingLocation>
      Parameters:
      other - the other ticking location
      Returns:
      -1 if this one is smaller, 0 if they're equal, 1 if this one is bigger