|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object cz.cuni.amis.pogamut.base.agent.module.AgentModule<AGENT> cz.cuni.amis.pogamut.base.agent.module.SensorModule<DefConAgent> cz.cuni.amis.pogamut.defcon.communication.worldview.polygons.GameMapInfoPolygons
public class GameMapInfoPolygons
Module containing polygonal description of certain features of map.
Field Summary | |
---|---|
protected int |
currentEnemyId
Current enemy id in case based on territory. |
protected BasicFlag |
currentFlag
Currently processed flag |
protected int |
currentTerritoryId
Current territory id in case of TERRITORY flags |
protected TreeMap<Integer,SortedMap<Integer,Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>>> |
enemyTerritories
List of enemy territories. |
protected IFlagChecker |
flagChecker
Flag checker for queries to map features |
protected List<List<DefConLocation>> |
land
Land. |
protected int |
lastAssignedTerritory
|
protected double |
minX
|
protected double |
minY
|
protected TreeMap<Integer,Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>> |
ownTerritories
List of own territories. |
protected List<List<DefConLocation>> |
sea
Sea. |
protected float |
SIMPLIFICATION_FACTOR
Factor of polygon's area to vertices count. |
protected float |
STEP_SIZE
Size of a sampling step. |
protected ArrayList<Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>> |
territories
Territories. |
Fields inherited from class cz.cuni.amis.pogamut.base.agent.module.SensorModule |
---|
worldView |
Fields inherited from class cz.cuni.amis.pogamut.base.agent.module.AgentModule |
---|
agent, controller, eventBus, log |
Constructor Summary | |
---|---|
GameMapInfoPolygons(DefConAgent<?> agent,
IFlagChecker flagChecker)
|
|
GameMapInfoPolygons(DefConAgent<?> agent,
IFlagChecker flagChecker,
String preprocessedPath)
|
|
GameMapInfoPolygons(DefConAgent<?> agent,
IFlagChecker flagChecker,
String preprocessedPath,
Logger log)
|
|
GameMapInfoPolygons(DefConAgent<?> agent,
IFlagChecker flagChecker,
String preprocessedPath,
Logger log,
ComponentDependencies dependencies)
|
Method Summary | |
---|---|
SortedMap<Integer,SortedMap<Integer,Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>>> |
getEnemiesTerritories()
|
SortedMap<Integer,Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>> |
getEnemyTerritories(int enemyId)
Returns a list of territories the enemy has. |
List<List<DefConLocation>> |
getLand()
Returns contours of negation of sea. |
SortedMap<Integer,Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>> |
getOwnTerritories()
|
List<List<DefConLocation>> |
getSea()
Returns contours of sea. |
Pair<List<List<DefConLocation>>,List<List<DefConLocation>>> |
getTerritory(int territoryId)
Returns a single territory. |
DefConWorldView |
getWorldView()
|
protected void |
processMap()
Processes the map from scratch. |
void |
saveBorders(IPrecomputedBordersSaver saver)
|
Methods inherited from class cz.cuni.amis.pogamut.base.agent.module.AgentModule |
---|
cleanUp, getComponentId, getLog, getState, initComponentId, isRunning, kill, pause, reset, resume, start, stop, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected final float STEP_SIZE
protected final float SIMPLIFICATION_FACTOR
protected ArrayList<Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>> territories
protected TreeMap<Integer,Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>> ownTerritories
protected TreeMap<Integer,SortedMap<Integer,Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>>> enemyTerritories
protected List<List<DefConLocation>> land
protected List<List<DefConLocation>> sea
protected IFlagChecker flagChecker
protected BasicFlag currentFlag
protected int currentTerritoryId
protected int currentEnemyId
protected int lastAssignedTerritory
protected double minX
protected double minY
Constructor Detail |
---|
public GameMapInfoPolygons(DefConAgent<?> agent, IFlagChecker flagChecker)
public GameMapInfoPolygons(DefConAgent<?> agent, IFlagChecker flagChecker, String preprocessedPath)
public GameMapInfoPolygons(DefConAgent<?> agent, IFlagChecker flagChecker, String preprocessedPath, Logger log)
public GameMapInfoPolygons(DefConAgent<?> agent, IFlagChecker flagChecker, String preprocessedPath, Logger log, ComponentDependencies dependencies)
Method Detail |
---|
public void saveBorders(IPrecomputedBordersSaver saver)
public DefConWorldView getWorldView()
protected void processMap()
public SortedMap<Integer,Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>> getOwnTerritories()
public SortedMap<Integer,SortedMap<Integer,Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>>> getEnemiesTerritories()
public Pair<List<List<DefConLocation>>,List<List<DefConLocation>>> getTerritory(int territoryId)
territoryId
-
public SortedMap<Integer,Pair<List<List<DefConLocation>>,List<List<DefConLocation>>>> getEnemyTerritories(int enemyId)
enemyId
-
public List<List<DefConLocation>> getLand()
public List<List<DefConLocation>> getSea()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |