All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
direction.cc
Go to the documentation of this file.
1 #include "osl/direction.h"
2 #include <iostream>
3 
5  return DIRECTION_MIN<=d && d<=DIRECTION_MAX;
6 }
7 
8 namespace osl
9 {
10  std::ostream& operator<<(std::ostream& os,const Direction d){
11  static const char* names[]={
12  "UL","U","UR","L",
13  "R","DL","D","DR",
14  "UUL","UUR","LONG_UL",
15  "LONG_U","LONG_UR","LONG_L",
16  "LONG_R","LONG_DL","LONG_D","LONG_DR"
17  };
18  return os << names[static_cast<int>(d)];
19  }
20 
21 }
22 
23 // ;;; Local Variables:
24 // ;;; mode:c++
25 // ;;; c-basic-offset:2
26 // ;;; End: