Interface LongAgentGraphNode

All Superinterfaces:
AgentGraphNode, GeometricGraphNode
All Known Implementing Classes:
LongAgentGraphNodeImpl, RailNode

public interface LongAgentGraphNode extends AgentGraphNode
Interface to be implemented by all classes that can be values of graph nodes of LongAgentsEnvironment.
Author:
Andrey Korotin
  • Method Details

    • addOccupyingAgent

      void addOccupyingAgent(LongAgent<?,?> longAgent)
      Adds the specified agent to collection of occupying agents (used to prevent the overlay of agents), e.g. when the agent enters this node or jumps to it.
      Parameters:
      longAgent - agent being added
    • removeOccupyingAgent

      void removeOccupyingAgent(LongAgent<?,?> longAgent)
      Removes the specified agent from collection of occupying agents (used to prevent the overlay of agents), e.g. when the agent leaves this node or is completely removed from graph environment.
      Parameters:
      longAgent - agent being removed
    • removeAllOccurrencesOccupyingAgent

      void removeAllOccurrencesOccupyingAgent(LongAgent<?,?> longAgent)
      Removes the all Occurrences of specified agent from collection of occupying agents (used to prevent the overlay of agents), e.g. when the agent leaves this node or is completely removed from graph environment.
      Parameters:
      longAgent - agent being removed
    • getOccupyingAgents

      List<LongAgent<?,?>> getOccupyingAgents()
      Returns an unmodifiable list of occupying agents that are currently occupying this node.
      Returns:
      unmodifiable list of occupying agents that are currently occupying this node