-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTerm.cs
56 lines (52 loc) · 1.42 KB
/
Term.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
namespace PhpToXml
{
/// <summary>
/// 期間
/// </summary>
public static class Term
{
/// <summary>
/// 前期
/// </summary>
public const int Early = 0;
/// <summary>
/// 後期
/// </summary>
public const int Late = 1;
public const int Quarter1 = 2;
public const int Quarter2 = 3;
public const int Quarter3 = 4;
public const int Quarter4 = 5;
public const int Other = 6;
public const int HALF_MAX = 7;
public static int ToTerm(string s)
{
int half;
switch (s)
{
case "前期":
half = Term.Early;
break;
case "後期":
half = Term.Late;
break;
case "第1クォーター":
half = Term.Quarter1;
break;
case "第2クォーター":
half = Term.Quarter2;
break;
case "第3クォーター":
half = Term.Quarter3;
break;
case "第4クォーター":
half = Term.Quarter4;
break;
default:
half = Term.Other;
break;
}
return half;
}
}
}