mizonokuchi

typedef

Aug 22nd, 2013
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.31 KB | None | 0 0
  1. #include <vector>
  2. #include <string>
  3.  
  4. using namespace std;
  5.  
  6. class MyClass1{
  7. public:
  8.   typedef int id_type;
  9.   id_type id;
  10. };
  11.  
  12. class MyClass2{
  13. public:
  14.   typedef string id_type;
  15.   id_type id;
  16. };
  17.  
  18. template <typename T> class MyClassManager{
  19.   typename T::id_type id;
  20.   T actual_data;
  21. };
  22.  
  23. main(){
  24. }
Advertisement
Add Comment
Please, Sign In to add comment