1: <?php
2: /**
3: * PHPWord
4: *
5: * Copyright (c) 2013 PHPWord
6: *
7: * This library is free software; you can redistribute it and/or
8: * modify it under the terms of the GNU Lesser General Public
9: * License as published by the Free Software Foundation; either
10: * version 2.1 of the License, or (at your option) any later version.
11: *
12: * This library is distributed in the hope that it will be useful,
13: * but WITHOUT ANY WARRANTY; without even the implied warranty of
14: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15: * Lesser General Public License for more details.
16: *
17: * You should have received a copy of the GNU Lesser General Public
18: * License along with this library; if not, write to the Free Software
19: * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20: *
21: * @category PHPWord
22: * @package PHPWord
23: * @copyright Copyright (c) 2013 PHPWord
24: * @license http://www.gnu.org/licenses/old-licenses/lgpl-2.1.txt LGPL
25: * @version 0.7.0
26: */
27:
28: /**
29: * Class PHPWord_DocumentProperties
30: */
31: class PHPWord_DocumentProperties
32: {
33:
34: /**
35: * Creator
36: *
37: * @var string
38: */
39: private $_creator;
40:
41: /**
42: * LastModifiedBy
43: *
44: * @var string
45: */
46: private $_lastModifiedBy;
47:
48: /**
49: * Created
50: *
51: * @var datetime
52: */
53: private $_created;
54:
55: /**
56: * Modified
57: *
58: * @var datetime
59: */
60: private $_modified;
61:
62: /**
63: * Title
64: *
65: * @var string
66: */
67: private $_title;
68:
69: /**
70: * Description
71: *
72: * @var string
73: */
74: private $_description;
75:
76: /**
77: * Subject
78: *
79: * @var string
80: */
81: private $_subject;
82:
83: /**
84: * Keywords
85: *
86: * @var string
87: */
88: private $_keywords;
89:
90: /**
91: * Category
92: *
93: * @var string
94: */
95: private $_category;
96:
97: /**
98: * Company
99: *
100: * @var string
101: */
102: private $_company;
103:
104: /**
105: * Create new PHPWord_DocumentProperties
106: */
107: public function __construct()
108: {
109: $this->_creator = '';
110: $this->_lastModifiedBy = $this->_creator;
111: $this->_created = time();
112: $this->_modified = time();
113: $this->_title = '';
114: $this->_subject = '';
115: $this->_description = '';
116: $this->_keywords = '';
117: $this->_category = '';
118: $this->_company = '';
119: }
120:
121: /**
122: * Get Creator
123: *
124: * @return string
125: */
126: public function getCreator()
127: {
128: return $this->_creator;
129: }
130:
131: /**
132: * Set Creator
133: *
134: * @param string $pValue
135: * @return PHPWord_DocumentProperties
136: */
137: public function setCreator($pValue = '')
138: {
139: $this->_creator = $pValue;
140: return $this;
141: }
142:
143: /**
144: * Get Last Modified By
145: *
146: * @return string
147: */
148: public function getLastModifiedBy()
149: {
150: return $this->_lastModifiedBy;
151: }
152:
153: /**
154: * Set Last Modified By
155: *
156: * @param string $pValue
157: * @return PHPWord_DocumentProperties
158: */
159: public function setLastModifiedBy($pValue = '')
160: {
161: $this->_lastModifiedBy = $pValue;
162: return $this;
163: }
164:
165: /**
166: * Get Created
167: *
168: * @return datetime
169: */
170: public function getCreated()
171: {
172: return $this->_created;
173: }
174:
175: /**
176: * Set Created
177: *
178: * @param datetime $pValue
179: * @return PHPWord_DocumentProperties
180: */
181: public function setCreated($pValue = null)
182: {
183: if (is_null($pValue)) {
184: $pValue = time();
185: }
186: $this->_created = $pValue;
187: return $this;
188: }
189:
190: /**
191: * Get Modified
192: *
193: * @return datetime
194: */
195: public function getModified()
196: {
197: return $this->_modified;
198: }
199:
200: /**
201: * Set Modified
202: *
203: * @param datetime $pValue
204: * @return PHPWord_DocumentProperties
205: */
206: public function setModified($pValue = null)
207: {
208: if (is_null($pValue)) {
209: $pValue = time();
210: }
211: $this->_modified = $pValue;
212: return $this;
213: }
214:
215: /**
216: * Get Title
217: *
218: * @return string
219: */
220: public function getTitle()
221: {
222: return $this->_title;
223: }
224:
225: /**
226: * Set Title
227: *
228: * @param string $pValue
229: * @return PHPWord_DocumentProperties
230: */
231: public function setTitle($pValue = '')
232: {
233: $this->_title = $pValue;
234: return $this;
235: }
236:
237: /**
238: * Get Description
239: *
240: * @return string
241: */
242: public function getDescription()
243: {
244: return $this->_description;
245: }
246:
247: /**
248: * Set Description
249: *
250: * @param string $pValue
251: * @return PHPWord_DocumentProperties
252: */
253: public function setDescription($pValue = '')
254: {
255: $this->_description = $pValue;
256: return $this;
257: }
258:
259: /**
260: * Get Subject
261: *
262: * @return string
263: */
264: public function getSubject()
265: {
266: return $this->_subject;
267: }
268:
269: /**
270: * Set Subject
271: *
272: * @param string $pValue
273: * @return PHPWord_DocumentProperties
274: */
275: public function setSubject($pValue = '')
276: {
277: $this->_subject = $pValue;
278: return $this;
279: }
280:
281: /**
282: * Get Keywords
283: *
284: * @return string
285: */
286: public function getKeywords()
287: {
288: return $this->_keywords;
289: }
290:
291: /**
292: * Set Keywords
293: *
294: * @param string $pValue
295: * @return PHPWord_DocumentProperties
296: */
297: public function setKeywords($pValue = '')
298: {
299: $this->_keywords = $pValue;
300: return $this;
301: }
302:
303: /**
304: * Get Category
305: *
306: * @return string
307: */
308: public function getCategory()
309: {
310: return $this->_category;
311: }
312:
313: /**
314: * Set Category
315: *
316: * @param string $pValue
317: * @return PHPWord_DocumentProperties
318: */
319: public function setCategory($pValue = '')
320: {
321: $this->_category = $pValue;
322: return $this;
323: }
324:
325: /**
326: * Get Company
327: *
328: * @return string
329: */
330: public function getCompany()
331: {
332: return $this->_company;
333: }
334:
335: /**
336: * Set Company
337: *
338: * @param string $pValue
339: * @return PHPWord_DocumentProperties
340: */
341: public function setCompany($pValue = '')
342: {
343: $this->_company = $pValue;
344: return $this;
345: }
346: }