View Javadoc

1   
2   package nl.tudelft.goal.ut2004.visualizer.timeline.map;
3   
4   import java.awt.Color;
5   import java.util.List;
6   
7   import com.google.inject.ImplementedBy;
8   
9   import cz.cuni.amis.pogamut.unreal.bot.IUnrealBot;
10  
11  /**
12   * This interface is used for passing info about agent to {@link EntityRenderer}.
13   * 
14   * It is supposed to be unified interface for both timeline and overview map. 
15   * Timeline implementation will provide available info at current time of db.
16   *
17   * @param <T> Type of object this object uses to get its data from
18   * @author Honza
19   */
20  public interface IRenderableUTAgent extends IUnrealBot, IRenderableWorldObject {
21  
22      /**
23       * Get color of agent. It should not change if possible, otherwise it can confuse a user.
24       * @return Color that will be used to render agent in map.
25       */
26      public Color getColor();
27  
28      /**
29       * Get fade line (line of past places the agent was).
30       * @return
31       */
32      public IFadeLine getFadeLine();
33  
34      /**
35       * Return text info associated with the agent. Agent can have multiple infos
36       * associated (e.g. current state, like "I am in water" and "I am looking for ammo")
37       * @return List of infos about the agent.
38       */
39      public List<String> getAssociatedInfo();
40  
41      //TODO(MP): Not rendering map events.
42  	// /**
43  	// * Return list of all map events this agent has at the time.
44  	// * XXX: It is possible it would be better to provide List &lt;ISubGLRenderer&gt;s,
45  	// * but it would clash with model-view-control design pattern.
46  	// * @return List of map events belonging to this agent.
47  	// */
48  	// public List<MapEvent> getMapEvents();
49  
50      /**
51       * Return source of all data that are providing stuff used.
52       * Why do I want it? The selection, I am putting this stuff to lookup and
53       * some other component can look it up and select nodes representing data sources.
54       *
55       * XXX: return type should be more general, but this saves trouble and no need to
56       * generalize too soon.
57       */
58      public Object getDataSource();
59  
60  
61      /**
62       * Return OpenGl name used for selection (see selction mode of opengl).
63       * Basically after all is rendered, whe get glNames(ints) of objects that were
64       * rendered in viewvolume. But we need to map it back. That is what this is for.
65       * @return
66       */
67      public int getGLName();
68  }