iSpike  2.1
Spike conversion library for robotics
D:/Home/Programs/iSpike/include/iSpike/Channel/Channel.hpp
Go to the documentation of this file.
00001 #ifndef CHANNEL_H_
00002 #define CHANNEL_H_
00003 
00004 //iSpike includes
00005 #include <iSpike/PropertyHolder.hpp>
00006 #include <iSpike/Log/Log.hpp>
00007 
00008 //Other includes
00009 #include <string>
00010 using namespace std;
00011 
00012 namespace ispike {
00013 
00015         class Channel : public PropertyHolder {
00016                 public:
00017                         Channel(){ initialized = false; }
00018                         virtual ~Channel(){}
00019 
00021                         int getId()     { return this->id; }
00022 
00024                         void setId(int id){ this->id = id; }
00025 
00027                         int getWidth(){ return this->width;     }
00028 
00030                         void setWidth(int width){ this->width = width; }
00031 
00033                         int getHeight(){ return this->height; }
00034 
00036                         void setHeight(int height){     this->height = height;  }
00037 
00039                         unsigned size() { return width*height; }
00040 
00042                         string getDescription(){ return this->description;      }
00043 
00045                         void setDescription(std::string description){ this->description = description; }
00046 
00048                         virtual void step() = 0;
00049 
00050 
00051                 protected:
00052                         //============================  VARIABLES  =========================
00054                         int id;
00055 
00057                         unsigned width;
00058 
00060                         unsigned height;
00061 
00063                         string description;
00064 
00065 
00066                         //=============================  METHODS  ===========================
00067                         bool isInitialized() {return initialized; }
00068                         void setInitialized(bool initialized) { this->initialized = initialized; }
00069 
00070 
00071                 private:
00073                         bool initialized;
00074 
00075         };
00076 
00077 }
00078 
00079 #endif /* CHANNEL_H_ */
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Defines