00001 /** 00002 * @file TeamBallLocatorSelector.h 00003 * 00004 * Definition of class TeamBallLocatorSelector 00005 * 00006 * @author Martin Lötzsch 00007 */ 00008 00009 #ifndef __TeamBallLocatorSelector_h_ 00010 #define __TeamBallLocatorSelector_h_ 00011 00012 #include "Tools/Module/ModuleSelector.h" 00013 00014 #include "TeamBallLocator.h" 00015 #include "GT2004TeamBallLocator.h" 00016 00017 /** 00018 * @class TeamBallLocatorSelector 00019 * 00020 * A module selector for team ball locators. 00021 * 00022 * @author Martin Lötzsch 00023 */ 00024 class TeamBallLocatorSelector : public ModuleSelector, public TeamBallLocatorInterfaces 00025 { 00026 public: 00027 /** 00028 * Constructor. 00029 * @param handler The module handler of the process. 00030 * @param interfaces The paramters of the TeamBallLocator module. 00031 */ 00032 TeamBallLocatorSelector( 00033 ModuleHandler &handler, 00034 const TeamBallLocatorInterfaces& interfaces) 00035 : ModuleSelector(SolutionRequest::teamBallLocator), 00036 TeamBallLocatorInterfaces(interfaces) 00037 { 00038 handler.setModuleSelector(SolutionRequest::teamBallLocator, this); 00039 } 00040 00041 /** 00042 * Is called on start and when the selected solution changes 00043 * to create a specific solution. 00044 * @param id The id of the solution to create 00045 * @return The created solution or 0 00046 */ 00047 virtual Module* createSolution(SolutionRequest::ModuleSolutionID id) 00048 { 00049 switch(id) 00050 { 00051 case SolutionRequest::gt2004TeamBallLocator: 00052 return new GT2004TeamBallLocator(*this); 00053 default: 00054 return 0; 00055 } 00056 } 00057 }; 00058 00059 #endif //__TeamBallLocatorSelector_h_ 00060 00061 /* 00062 * Change log: 00063 * 00064 * $Log: TeamBallLocatorSelector.h,v $ 00065 * Revision 1.2 2004/07/10 00:13:53 spranger 00066 * renaming for coderelease and preparations for gt2005 00067 * 00068 * Revision 1.1.1.1 2004/05/22 17:22:26 cvsadm 00069 * created new repository GT2004_WM 00070 * 00071 * Revision 1.5 2004/04/05 17:56:47 loetzsch 00072 * merged the local German Open CVS of the aibo team humboldt with the tamara CVS 00073 * 00074 * Revision 1.4 2004/03/08 02:11:54 roefer 00075 * Interfaces should be const 00076 * 00077 * Revision 1.3 2004/01/23 23:02:25 wachter 00078 * Reinserted the famous GaussBellTeamBallLocator from the 00079 * as GT2003-code as SensorFusionTeamBallLocator. 00080 * 00081 * Revision 1.2 2004/01/21 14:31:58 loetzsch 00082 * Module Selectors create only the selected solution. 00083 * When the solution changes, the old solution is erased and the new 00084 * one ist created using createSolution(..) 00085 * 00086 * Revision 1.1 2003/10/06 14:10:14 cvsadm 00087 * Created GT2004 (M.J.) 00088 * 00089 * Revision 1.1.1.1 2003/07/02 09:40:24 cvsadm 00090 * created new repository for the competitions in Padova from the 00091 * tamara CVS (Tuesday 2:00 pm) 00092 * 00093 * removed unused solutions 00094 * 00095 * Revision 1.1 2003/05/01 17:09:08 loetzsch 00096 * Redesign of ball modeling: 00097 * - Modularized class BallPosition 00098 * - splitted up module "BallLocator" into "BallLocator" for modeling of percepts 00099 * and "TeamBallLocator" for modelling communicated positions 00100 * - Removed solution JumpingBallLocator 00101 * - Splitted Solution DefaultBallLocator into DefaultBallLocator and DefaultTeamBallLocator 00102 * - Renamed SensorFusionBallLocator to GaussBellTeamBallLocator 00103 * 00104 */