incorporate drawable and annotations
[mussa.git] / alg / annotation_colors.hpp
index 96efa250453543047471c32c57dc651863407da8..eaabc1784635f84725c74d832c37d42df909be2a 100644 (file)
@@ -4,14 +4,15 @@
 #include <map>
 #include <string>
 
-#include "alg/color.hpp"
-#include "alg/sequence.hpp"
+#include "color.hpp"
+#include "sequence.hpp"
 
 struct DefaultColorMap;
 struct DefaultColorMap
 {
   typedef std::map<std::string, DefaultColorMap> color_map_type;
   typedef color_map_type::iterator iterator;
+  typedef color_map_type::const_iterator const_iterator;
   DefaultColorMap();
   //! initialize color map with a default color
   DefaultColorMap(const Color &);
@@ -27,8 +28,10 @@ class AnnotationColors
 {
 public:
   AnnotationColors();
-  AnnotationColors(AnnotationColors &);
+  AnnotationColors(const AnnotationColors &);
 
+  // clear all the contents of our mappers
+  void clear();
   //! set default color
   void setColor(Color &);
   //! retreive default color
@@ -52,8 +55,8 @@ public:
   void erase(const std::string &type, const std::string& instance);
 
   //! lookup an annotation color
-  Color lookup(const annot &);
-  Color lookup(const std::string &, const std::string &);
+  Color lookup(const annot &) const;
+  Color lookup(const std::string &, const std::string &) const;
 private:
   // nested maps, with default?
   DefaultColorMap root_map;