|
1
|
|
|
<?php |
|
2
|
|
|
|
|
3
|
|
|
namespace PhpEws\DataType; |
|
4
|
|
|
|
|
5
|
|
|
use PhpEws\DataType; |
|
6
|
|
|
|
|
7
|
|
|
/** |
|
8
|
|
|
* Mapping types for Contacts |
|
9
|
|
|
*/ |
|
10
|
|
|
class FileAsMappingType extends DataType |
|
11
|
|
|
{ |
|
12
|
|
|
/** |
|
13
|
|
|
* File as mapping for "company" |
|
14
|
|
|
* |
|
15
|
|
|
* @var string |
|
16
|
|
|
*/ |
|
17
|
|
|
const COMPANY = 'Company'; |
|
18
|
|
|
|
|
19
|
|
|
/** |
|
20
|
|
|
* File as mapping for "last name, first name" |
|
21
|
|
|
* |
|
22
|
|
|
* @var |
|
23
|
|
|
*/ |
|
24
|
|
|
const COMPANY_LAST_COMMA_FIRST = 'CompanyLastCommaFirst'; |
|
25
|
|
|
|
|
26
|
|
|
/** |
|
27
|
|
|
* File as mapping for "company last name first name" |
|
28
|
|
|
* |
|
29
|
|
|
* @var string |
|
30
|
|
|
*/ |
|
31
|
|
|
const COMPANY_LAST_FIRST = 'CompanyLastFirst'; |
|
32
|
|
|
|
|
33
|
|
|
/** |
|
34
|
|
|
* File as mapping for "company last name first name" |
|
35
|
|
|
* |
|
36
|
|
|
* @var string |
|
37
|
|
|
*/ |
|
38
|
|
|
const COMPANY_LAST_SPACE_FIRST = 'CompanyLastSpaceFirst'; |
|
39
|
|
|
|
|
40
|
|
|
/** |
|
41
|
|
|
* File as mapping for "first name last name" |
|
42
|
|
|
* |
|
43
|
|
|
* @var string |
|
44
|
|
|
*/ |
|
45
|
|
|
const FIRST_SPACE_LAST = 'FirstSpaceLast'; |
|
46
|
|
|
|
|
47
|
|
|
/** |
|
48
|
|
|
* File as mapping for "last name first name" |
|
49
|
|
|
* |
|
50
|
|
|
* @var string |
|
51
|
|
|
*/ |
|
52
|
|
|
const LAST_FIRST = 'LastFirst'; |
|
53
|
|
|
|
|
54
|
|
|
/** |
|
55
|
|
|
* File as mapping for "last name first name company" |
|
56
|
|
|
* |
|
57
|
|
|
* @var string |
|
58
|
|
|
*/ |
|
59
|
|
|
const LAST_FIRST_COMPANY = 'LastFirstCompany'; |
|
60
|
|
|
|
|
61
|
|
|
/** |
|
62
|
|
|
* File as mapping for "last name first name suffix" |
|
63
|
|
|
* |
|
64
|
|
|
* @var string |
|
65
|
|
|
*/ |
|
66
|
|
|
const LAST_FIRST_SUFFIX = 'LastFirstSuffix'; |
|
67
|
|
|
|
|
68
|
|
|
/** |
|
69
|
|
|
* File as mapping for "last name, first name" |
|
70
|
|
|
* |
|
71
|
|
|
* @var string |
|
72
|
|
|
*/ |
|
73
|
|
|
const LAST_COMMA_FIRST = 'LastCommaFirst'; |
|
74
|
|
|
|
|
75
|
|
|
/** |
|
76
|
|
|
* File as mapping for "last name, first name company" |
|
77
|
|
|
* |
|
78
|
|
|
* @var string |
|
79
|
|
|
*/ |
|
80
|
|
|
const LAST_COMMA_FIRST_COMPANY = 'LastCommaFirstCompany'; |
|
81
|
|
|
|
|
82
|
|
|
/** |
|
83
|
|
|
* File as mapping for "last name first name" |
|
84
|
|
|
* |
|
85
|
|
|
* @var string |
|
86
|
|
|
*/ |
|
87
|
|
|
const LAST_SPACE_FIRST = 'LastSpaceFirst'; |
|
88
|
|
|
|
|
89
|
|
|
/** |
|
90
|
|
|
* File as mapping for "lasy name first name company" |
|
91
|
|
|
* |
|
92
|
|
|
* @var string |
|
93
|
|
|
*/ |
|
94
|
|
|
const LAST_SPACE_FIRST_COMPANY = 'LastSpaceFirstCompany'; |
|
95
|
|
|
|
|
96
|
|
|
/** |
|
97
|
|
|
* File as mapping to use when no mapping is desired. |
|
98
|
|
|
* |
|
99
|
|
|
* @var string |
|
100
|
|
|
*/ |
|
101
|
|
|
const NONE = 'None'; |
|
102
|
|
|
|
|
103
|
|
|
/** |
|
104
|
|
|
* Value of the desired mapping. Should be one of the constants from the |
|
105
|
|
|
* FileAsMappingType class. |
|
106
|
|
|
* |
|
107
|
|
|
* @var string |
|
108
|
|
|
*/ |
|
109
|
|
|
public $_; |
|
110
|
|
|
|
|
111
|
|
|
/** |
|
112
|
|
|
* Returns the value of this object as a string |
|
113
|
|
|
* |
|
114
|
|
|
* @return string |
|
115
|
|
|
*/ |
|
116
|
|
|
public function __toString() |
|
117
|
|
|
{ |
|
118
|
|
|
return $this->_; |
|
119
|
|
|
} |
|
120
|
|
|
} |
|
121
|
|
|
|