Class HalfPlaneAdapter_FixedTreasure
- java.lang.Object
-
- com.treasure.hunt.strategy.hider.impl.HalfPlaneAdapter_FixedTreasure
-
- All Implemented Interfaces:
Hider<HalfPlaneHint>
public class HalfPlaneAdapter_FixedTreasure extends java.lang.Object implements Hider<HalfPlaneHint>
Adapter such that searchers who require HalfPlaneHints can play against this strategyUnfortunately some redundant work needs to be done ( e.g. Preferences set twice in the code)
-
-
Constructor Summary
Constructors Constructor Description HalfPlaneAdapter_FixedTreasure()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.locationtech.jts.geom.Point
getTreasureLocation()
void
init(org.locationtech.jts.geom.Point searcherStartPosition)
HalfPlaneHint
move(SearchPath searchPath)
-
-
-
Method Detail
-
init
public void init(org.locationtech.jts.geom.Point searcherStartPosition)
- Specified by:
init
in interfaceHider<HalfPlaneHint>
- Parameters:
searcherStartPosition
- theSearcher
starting position, he will initialized on.
-
move
public HalfPlaneHint move(SearchPath searchPath)
- Specified by:
move
in interfaceHider<HalfPlaneHint>
- Parameters:
searchPath
- theSearchPath
, theSearcher
did last- Returns:
- T a (new) hint.
-
getTreasureLocation
public org.locationtech.jts.geom.Point getTreasureLocation()
- Specified by:
getTreasureLocation
in interfaceHider<HalfPlaneHint>
- Returns:
- the current treasure location
-
-