RegionCreator.h

Go to the documentation of this file.
00001 
00002 #ifndef REGION_REGIONCREATOR_H_
00003 #define REGION_REGIONCREATOR_H_
00004 #include <display/region/RegionEnums.h>
00005 #include <display/Utilities/VOID.h>
00006 #include <set>
00007 #include <map>
00008 #include <list>
00009 #include <vector>
00010 
00011 namespace casa {
00012         class WorldCanvas;
00013         namespace viewer {
00014                 class RegionCreator {
00015                 public:
00016                         typedef std::list <RegionCreator*> creator_list_type;
00017                         // called when the user indicates that a region should be deleted...
00018                         virtual void revokeRegion (Region *) = 0;
00019                         // returns the set of region types which this creator will create
00020                         virtual const std::set <region::RegionTypes> &regionsCreated () const = 0;
00021                         virtual bool create( region::RegionTypes /*region_type*/, WorldCanvas */*wc*/, const std::vector<std::pair <double, double> > &/*pts*/,
00022                                              const std::string &/*label*/, viewer::region::TextPosition /*label_pos*/, const std::vector<int> &/*label_off*/,
00023                                              const std::string &/*font*/, int /*font_size*/, int /*font_style*/, const std::string &/*font_color*/,
00024                                              const std::string &/*line_color*/, viewer::region::LineStyle /*line_style*/, unsigned int /*line_width*/,
00025                                              bool /*annotation*/, VOID */*region_specific_state*/ )= 0;
00026 //                      DISPLAY_PURE_VIRTUAL(RegionCreator::create,true);
00027 
00028                         RegionCreator ();
00029                         virtual ~RegionCreator ();
00030 
00031                         static const creator_list_type &findCreator (region::RegionTypes type);
00032 
00033                 private:
00034                         typedef std::map <region::RegionTypes, creator_list_type*> creator_map_type;
00035                         static creator_map_type creator_map;
00036                         static creator_list_type unsorted_creators;
00037                 };
00038 
00039         } // end namespace viewer
00040 } // end namespace casa
00041 
00042 #endif
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 31 Aug 2016 for casa by  doxygen 1.6.1