Interface Environment2DWithObstacles
-
- All Implemented Interfaces:
-
it.unibo.alchemist.model.Environment
,it.unibo.alchemist.model.EnvironmentWithObstacles
,it.unibo.alchemist.model.EuclideanEnvironment
,it.unibo.alchemist.model.environments.Euclidean2DEnvironment
,java.io.Serializable
,kotlin.collections.Iterable
,kotlin.collections.MutableIterable
public interface Environment2DWithObstacles<W extends Obstacle2D<Euclidean2DPosition>, T extends Object> implements EnvironmentWithObstacles<W, T, Euclidean2DPosition>, Euclidean2DEnvironment<T>
A bidimensional EnvironmentWithObstacles.
-
-
Method Summary
Modifier and Type Method Description abstract List<W>
getObstaclesInRange(Euclidean2DPosition center, Double range)
Given a point and a range, retrieves all the obstacles within. abstract List<W>
getObstaclesInRange(Double centerx, Double centery, Double range)
Given a point and a range, retrieves all the obstacles within. abstract Boolean
hasMobileObstacles()
-
Methods inherited from class it.unibo.alchemist.model.Environment
addGlobalReaction, addLayer, addNode, addTerminator, getDimensions, getDistanceBetweenNodes, getGlobalReactions, getIncarnation, getLayer, getLayers, getLinkingRule, getNeighborhood, getNodeByID, getNodeCount, getNodes, getNodesWithinRange, getNodesWithinRange, getOffset, getPosition, getSimulation, getSize, getSizeInDistanceUnits, isTerminated, makePosition, moveNodeToPosition, removeGlobalReaction, removeNode, setLinkingRule, setSimulation
-
Methods inherited from class it.unibo.alchemist.model.EnvironmentWithObstacles
addObstacle, getObstacles, intersectsObstacle, next, removeObstacle
-
Methods inherited from class kotlin.collections.Iterable
forEach, spliterator
-
Methods inherited from class kotlin.collections.MutableIterable
iterator
-
Methods inherited from class it.unibo.alchemist.model.EuclideanEnvironment
getOrigin, makePosition, moveNode
-
Methods inherited from class it.unibo.alchemist.model.environments.Euclidean2DEnvironment
makePosition
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
getObstaclesInRange
abstract List<W> getObstaclesInRange(Euclidean2DPosition center, Double range)
Given a point and a range, retrieves all the obstacles within.
- Parameters:
center
-the center point
range
-the range to scan
- Returns:
the list of obstacles
-
getObstaclesInRange
abstract List<W> getObstaclesInRange(Double centerx, Double centery, Double range)
Given a point and a range, retrieves all the obstacles within.
- Parameters:
centerx
-the x coordinate of the center
centery
-the y coordinate of the center
range
-the range to scan
- Returns:
the list of Obstacles
-
hasMobileObstacles
abstract Boolean hasMobileObstacles()
- Returns:
true if this environment has mobile obstacles, false if the obstacles are static
-
-
-
-