MailWrapper.php
2.27 KB
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
<?php
/**
* Joomla! Content Management System
*
* @copyright Copyright (C) 2005 - 2019 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace Joomla\CMS\Mail;
defined('JPATH_PLATFORM') or die;
/**
* Wrapper class for MailHelper
*
* @since 3.4
* @deprecated 4.0 Will be removed without replacement
*/
class MailWrapper
{
/**
* Helper wrapper method for cleanLine
*
* @param string $value String to be cleaned.
*
* @return string Cleaned string.
*
* @see MailHelper::cleanLine()
* @since 3.4
*/
public function cleanLine($value)
{
return MailHelper::cleanLine($value);
}
/**
* Helper wrapper method for cleanText
*
* @param string $value Multi-line string to be cleaned.
*
* @return string Cleaned multi-line string.
*
* @see MailHelper::cleanText()
* @since 3.4
*/
public function cleanText($value)
{
return MailHelper::cleanText($value);
}
/**
* Helper wrapper method for cleanBody
*
* @param string $body email body string.
*
* @return string Cleaned email body string.
*
* @see MailHelper::cleanBody()
* @since 3.4
*/
public function cleanBody($body)
{
return MailHelper::cleanBody($body);
}
/**
* Helper wrapper method for cleanSubject
*
* @param string $subject email subject string.
*
* @return string Cleaned email subject string.
*
* @see MailHelper::cleanSubject()
* @since 3.4
*/
public function cleanSubject($subject)
{
return MailHelper::cleanSubject($subject);
}
/**
* Helper wrapper method for cleanAddress
*
* @param string $address email address.
*
* @return mixed email address string or boolean false if injected headers are present
*
* @see MailHelper::cleanAddress()
* @since 3.4
*/
public function cleanAddress($address)
{
return MailHelper::cleanAddress($address);
}
/**
* Helper wrapper method for isEmailAddress
*
* @param string $email String to be verified.
*
* @return boolean True if string has the correct format; false otherwise.
*
* @see MailHelper::isEmailAddress()
* @since 3.4
*/
public function isEmailAddress($email)
{
return MailHelper::isEmailAddress($email);
}
}