[wadalabfont-kit] / jis2prim / Assumption.h  

Annotation of /jis2prim/Assumption.h

Parent Directory | Revision Log

Revision: 1.4 - (view) (download) (as text)

1 : ktanaka 1.1 #ifndef _ASSUMPTION_H
2 :     #define _ASSUMPTION_H
3 : ktanaka 1.3 #include <vector>
4 :     #include <iostream>
5 : ktanaka 1.1
6 :     enum PtypeMask{
7 :     TenMask=1<<0,
8 :     YokoMask=1<<1,
9 :     TateMask=1<<2,
10 : ktanaka 1.2 HidariMask=1<<3,
11 :     TatehaneMask=1<<4,
12 :     TatehidariMask=1<<5,
13 : ktanaka 1.1 };
14 :     enum JointType{
15 :     Start,
16 :     JointStart,
17 :     Mid,
18 :     End,
19 :     JointEnd,
20 :     };
21 :    
22 :     class SimpleAssumption{
23 : ktanaka 1.3 friend std::ostream& operator<<(std::ostream &os,const SimpleAssumption &sa);
24 : ktanaka 1.1 protected:
25 :     PtypeMask pmask;
26 :     JointType jtype;
27 : ktanaka 1.2 double x, y;
28 : ktanaka 1.1 int angle;
29 : ktanaka 1.2 int hint;
30 : ktanaka 1.1 public:
31 : ktanaka 1.4 SimpleAssumption(PtypeMask pm, JointType jt,double xx,double yy, int a,int h);
32 : ktanaka 1.1 };
33 :     class AndAssumption{
34 : ktanaka 1.3 friend std::ostream& operator<<(std::ostream &os,const AndAssumption &aa);
35 : ktanaka 1.1 protected:
36 : ktanaka 1.3 std::vector<SimpleAssumption> saList;
37 : ktanaka 1.1 public:
38 : ktanaka 1.4 AndAssumption& add(const SimpleAssumption &sa);
39 : ktanaka 1.1 };
40 :     class Assumption{
41 : ktanaka 1.3 friend std::ostream& operator<<(std::ostream &os,const Assumption &as);
42 : ktanaka 1.1 private:
43 : ktanaka 1.3 std::vector<AndAssumption> aaList;
44 : ktanaka 1.1 public:
45 : ktanaka 1.4 Assumption& add(const AndAssumption &sa);
46 :     Assumption& add(const SimpleAssumption &sa);
47 : ktanaka 1.1 };
48 : ktanaka 1.4 std::ostream& operator<<(std::ostream &os,const SimpleAssumption &sa);
49 :     std::ostream& operator<<(std::ostream &os,const AndAssumption &aa);
50 :     std::ostream& operator<<(std::ostream &os,const Assumption &a);
51 : ktanaka 1.1
52 :     #endif /* _ASSUMPTION_H */

ktanaka

Powered by ViewCVS 1.0-dev

ViewCVS and CVS Help