Version: 0.6.0
categorydataset.h
1 // Name: categorydataset.h
3 // Purpose: category dataset declarations
4 // Author: Moskvichev Andrey V.
5 // Created: 2008/11/07
6 // Copyright: (c) 2008-2010 Moskvichev Andrey V.
7 // Licence: wxWidgets licence
9 
10 #ifndef CATEGORYDATASET_H_
11 #define CATEGORYDATASET_H_
12 
13 #include <wx/dataset.h>
14 #include <wx/bars/barrenderer.h>
15 
19 class WXDLLIMPEXP_FREECHART CategoryDataset : public XYDataset
20 {
21  DECLARE_CLASS(XYDataset)
22 public:
24  virtual ~CategoryDataset();
25 
31  virtual double GetValue(size_t index, size_t serie) = 0;
32 
38  virtual wxString GetName(size_t index) = 0;
39 
44  virtual size_t GetCount() = 0;
45 
46  virtual bool HasValue(size_t index, size_t serie);
47 
48  virtual double GetMinValue(bool verticalAxis);
49 
50  virtual double GetMaxValue(bool verticalAxis);
51 
52  //
53  // XYDataset
54  //
55  virtual double GetX(size_t index, size_t serie);
56 
57  virtual double GetY(size_t index, size_t serie);
58 
59  virtual size_t GetCount(size_t serie);
60 
61  BarRenderer *GetRenderer()
62  {
63  return (BarRenderer *) m_renderer;
64  }
65 
66 protected:
67  virtual bool AcceptRenderer(Renderer *r);
68 };
69 
70 #endif /*CATEGORYDATASET_H_*/
Definition: categorydataset.h:19
Definition: chartrenderer.h:21
virtual bool AcceptRenderer(Renderer *r)
Definition: xydataset.cpp:41
virtual double GetMaxValue(bool verticalAxis)
Definition: xydataset.cpp:120
virtual double GetMinValue(bool verticalAxis)
Definition: xydataset.cpp:110
Definition: barrenderer.h:140
virtual double GetX(size_t index, size_t serie)=0
virtual double GetY(size_t index, size_t serie)=0
Definition: xydataset.h:21
virtual size_t GetCount(size_t serie)=0