00001 #include "base.h" 00002 #include <iostream> 00003 #include <class_loader/class_loader.h> 00004 00005 class Dog : public Base 00006 { 00007 public: 00008 virtual void saySomething(){std::cout << "Bark" << std::endl;} 00009 }; 00010 00011 class Cat : public Base 00012 { 00013 public: 00014 virtual void saySomething(){std::cout << "Meow" << std::endl;} 00015 }; 00016 00017 class Duck : public Base 00018 { 00019 public: 00020 virtual void saySomething(){std::cout << "Quack" << std::endl;} 00021 }; 00022 00023 class Cow : public Base 00024 { 00025 public: 00026 virtual void saySomething(){std::cout << "Moooo" << std::endl;} 00027 }; 00028 00029 class Sheep : public Base 00030 { 00031 public: 00032 virtual void saySomething(){std::cout << "Baaah" << std::endl;} 00033 }; 00034 00035 CLASS_LOADER_REGISTER_CLASS(Dog, Base); 00036 CLASS_LOADER_REGISTER_CLASS(Cat, Base); 00037 CLASS_LOADER_REGISTER_CLASS(Duck, Base); 00038 CLASS_LOADER_REGISTER_CLASS(Cow, Base); 00039 CLASS_LOADER_REGISTER_CLASS(Sheep, Base);