Core  3.2
PHP API documentation
 All Data Structures Namespaces Files Functions Variables Pages
Class.Body.php
Go to the documentation of this file.
1 <?php
2 /*
3  * @author Anakeen
4  * @package FDL
5 */
6 
7 namespace Dcp\Mail;
8 
9 class Body implements DataSource
10 {
11  public $data = '';
12  public $type = '';
13  public function __construct($data, $type)
14  {
15  $this->data = $data;
16  $this->type = $type;
17  }
18  public function getMimeType()
19  {
20  return $this->type;
21  }
22  public function getData()
23  {
24  return $this->data;
25  }
26  public function getName()
27  {
28  if ($this->type == 'text/plain') {
29  return "body.txt";
30  } elseif ($this->type == 'text/html') {
31  return "body.html";
32  }
33  return "body.bin";
34  }
35 }
$s type
Definition: dav.php:73
__construct($data, $type)
Definition: Class.Body.php:13
← centre documentaire © anakeen