David Carter
2013-08-30 de8687f9f11d49d36b322af72f644f7c5a232b9f
commit | author | age
0c2596 1 <?php
A 2
3 /*
4  +-----------------------------------------------------------------------+
5  | This file is part of the Roundcube Webmail client                     |
6  | Copyright (C) 2005-2012, The Roundcube Dev Team                       |
7  | Copyright (C) 2011-2012, Kolab Systems AG                             |
8  |                                                                       |
9  | Licensed under the GNU General Public License version 3 or            |
10  | any later version with exceptions for skins & plugins.                |
11  | See the README file for a full license statement.                     |
12  |                                                                       |
13  | PURPOSE:                                                              |
14  |   Class representing a message part                                   |
15  +-----------------------------------------------------------------------+
16  | Author: Thomas Bruederli <roundcube@gmail.com>                        |
17  | Author: Aleksander Machniak <alec@alec.pl>                            |
18  +-----------------------------------------------------------------------+
19 */
20
21 /**
22  * Class representing a message part
23  *
9ab346 24  * @package    Framework
AM 25  * @subpackage Storage
0c2596 26  * @author     Thomas Bruederli <roundcube@gmail.com>
A 27  * @author     Aleksander Machniak <alec@alec.pl>
28  */
29 class rcube_message_part
30 {
31     /**
32      * Part MIME identifier
33      *
34      * @var string
35      */
36     public $mime_id = '';
37
38     /**
39      * Content main type
40      *
41      * @var string
42      */
43     public $ctype_primary = 'text';
44
45     /**
46      * Content subtype
47      *
48      * @var string
49      */
50     public $ctype_secondary = 'plain';
51
52     /**
53      * Complete content type
54      *
55      * @var string
56      */
57     public $mimetype = 'text/plain';
58
59     public $disposition = '';
60     public $filename = '';
61     public $encoding = '8bit';
62     public $charset = '';
63
64     /**
65      * Part size in bytes
66      *
67      * @var int
68      */
69     public $size = 0;
70
71     /**
72      * Part headers
73      *
74      * @var array
75      */
76     public $headers = array();
77
78     public $d_parameters = array();
79     public $ctype_parameters = array();
80
81
82     /**
83      * Clone handler.
84      */
85     function __clone()
86     {
87         if (isset($this->parts)) {
88             foreach ($this->parts as $idx => $part) {
89                 if (is_object($part)) {
90                     $this->parts[$idx] = clone $part;
91                 }
92             }
93         }
94     }
95
96 }