TYPO3
7.6
|
Public Member Functions | |
__construct (Swift_Mime_Grammar $grammar) | |
setCharset ($charset) | |
getCharset () | |
setLanguage ($lang) | |
getLanguage () | |
setEncoder (Swift_Mime_HeaderEncoder $encoder) | |
getEncoder () | |
setGrammar (Swift_Mime_Grammar $grammar) | |
getGrammar () | |
getFieldName () | |
setMaxLineLength ($lineLength) | |
getMaxLineLength () | |
toString () | |
__toString () | |
Public Member Functions inherited from Swift_Mime_Header | |
getFieldType () | |
setFieldBodyModel ($model) | |
getFieldBodyModel () | |
getFieldBody () | |
Protected Member Functions | |
setFieldName ($name) | |
createPhrase (Swift_Mime_Header $header, $string, $charset, Swift_Mime_HeaderEncoder $encoder=null, $shorten=false) | |
encodeWords (Swift_Mime_Header $header, $input, $usedLength=-1) | |
tokenNeedsEncoding ($token) | |
getEncodableWordTokens ($string) | |
getTokenAsEncodedWord ($token, $firstLineOffset=0) | |
generateTokenLines ($token) | |
setCachedValue ($value) | |
getCachedValue () | |
clearCachedValueIf ($condition) | |
toTokens ($string=null) | |
Private Member Functions | |
_tokensToString (array $tokens) | |
Private Attributes | |
$_name | |
$_grammar | |
$_encoder | |
$_lineLength = 78 | |
$_lang | |
$_charset = 'utf-8' | |
$_cachedValue = null | |
Additional Inherited Members | |
Public Attributes inherited from Swift_Mime_Header | |
const | TYPE_TEXT = 2 |
const | TYPE_PARAMETERIZED = 6 |
const | TYPE_MAILBOX = 8 |
const | TYPE_DATE = 16 |
const | TYPE_ID = 32 |
const | TYPE_PATH = 64 |
An abstract base MIME Header.
Definition at line 16 of file AbstractHeader.php.
__construct | ( | Swift_Mime_Grammar | $grammar | ) |
Creates a new Header.
Swift_Mime_Grammar | $grammar |
Definition at line 72 of file AbstractHeader.php.
References setGrammar().
__toString | ( | ) |
Returns a string representation of this object.
Definition at line 217 of file AbstractHeader.php.
References toString().
|
private |
Takes an array of tokens which appear in the header and turns them into an RFC 2822 compliant string, adding FWSP where needed.
string[] | $tokens |
Definition at line 477 of file AbstractHeader.php.
Referenced by toString().
|
protected |
Clear the cached value if $condition is met.
bool | $condition |
Definition at line 436 of file AbstractHeader.php.
References setCachedValue().
Referenced by setCharset(), Swift_Mime_Headers_IdentificationHeader\setIds(), setLanguage(), setMaxLineLength(), Swift_Mime_Headers_ParameterizedHeader\setParameters(), Swift_Mime_Headers_DateHeader\setTimestamp(), and Swift_Mime_Headers_UnstructuredHeader\setValue().
|
protected |
Produces a compliant, formatted RFC 2822 'phrase' based on the string given.
Swift_Mime_Header | $header | |
string | $string | as displayed |
string | $charset | of the text |
Swift_Mime_HeaderEncoder | $encoder | |
bool | $shorten | the first line to make remove for header name |
Definition at line 245 of file AbstractHeader.php.
References encodeWords(), Swift_Mime_Header\getFieldName(), and getGrammar().
Referenced by Swift_Mime_Headers_MailboxHeader\createDisplayNameString().
|
protected |
Encode needed word tokens within a string of input.
Swift_Mime_Header | $header | |
string | $input | |
string | $usedLength | optional |
Definition at line 282 of file AbstractHeader.php.
References getEncodableWordTokens(), Swift_Mime_Header\getFieldName(), getTokenAsEncodedWord(), and tokenNeedsEncoding().
Referenced by createPhrase(), and Swift_Mime_Headers_UnstructuredHeader\getFieldBody().
|
protected |
Generates tokens from the given string which include CRLF as individual tokens.
string | $token |
Definition at line 406 of file AbstractHeader.php.
Referenced by Swift_Mime_Headers_ParameterizedHeader\toTokens(), and toTokens().
|
protected |
Get the value in the cache.
Definition at line 426 of file AbstractHeader.php.
References $_cachedValue.
Referenced by Swift_Mime_Headers_UnstructuredHeader\getFieldBody(), Swift_Mime_Headers_DateHeader\getFieldBody(), Swift_Mime_Headers_PathHeader\getFieldBody(), Swift_Mime_Headers_IdentificationHeader\getFieldBody(), and Swift_Mime_Headers_MailboxHeader\getFieldBody().
getCharset | ( | ) |
Get the character set used in this Header.
Definition at line 96 of file AbstractHeader.php.
References $_charset.
Referenced by Swift_Mime_Headers_ParameterizedHeader\_createParameter(), and Swift_Mime_Headers_MailboxHeader\createDisplayNameString().
|
protected |
Splits a string into tokens in blocks of words which can be encoded quickly.
string | $string |
Definition at line 333 of file AbstractHeader.php.
References tokenNeedsEncoding().
Referenced by encodeWords().
getEncoder | ( | ) |
Get the encoder used for encoding this Header.
Definition at line 141 of file AbstractHeader.php.
References $_encoder.
Referenced by Swift_Mime_Headers_MailboxHeader\createDisplayNameString().
getFieldName | ( | ) |
Get the name of this header (e.g. charset).
Implements Swift_Mime_Header.
Definition at line 172 of file AbstractHeader.php.
References $_name.
getGrammar | ( | ) |
Get the grammar used for this Header.
Definition at line 162 of file AbstractHeader.php.
References $_grammar.
Referenced by Swift_Mime_Headers_PathHeader\_assertValidAddress(), Swift_Mime_Headers_MailboxHeader\_assertValidAddress(), Swift_Mime_Headers_IdentificationHeader\_assertValidId(), Swift_Mime_Headers_ParameterizedHeader\_createParameter(), and createPhrase().
getLanguage | ( | ) |
Get the language used in this Header.
Definition at line 120 of file AbstractHeader.php.
References $_lang.
Referenced by Swift_Mime_Headers_ParameterizedHeader\_createParameter(), and Swift_Mime_Headers_ParameterizedHeader\_getEndOfParameterValue().
getMaxLineLength | ( | ) |
Get the maximum permitted length of lines in this Header.
Definition at line 193 of file AbstractHeader.php.
References $_lineLength.
Referenced by Swift_Mime_Headers_ParameterizedHeader\_createParameter().
|
protected |
Get a token as an encoded word for safe insertion into headers.
string | $token | token to encode |
int | $firstLineOffset | optional |
Definition at line 365 of file AbstractHeader.php.
References $_charset.
Referenced by Swift_Mime_Headers_ParameterizedHeader\_createParameter(), and encodeWords().
|
protected |
Set a value into the cache.
string | $value |
Definition at line 416 of file AbstractHeader.php.
Referenced by clearCachedValueIf(), Swift_Mime_Headers_UnstructuredHeader\getFieldBody(), Swift_Mime_Headers_DateHeader\getFieldBody(), Swift_Mime_Headers_PathHeader\getFieldBody(), Swift_Mime_Headers_IdentificationHeader\getFieldBody(), Swift_Mime_Headers_MailboxHeader\getFieldBody(), Swift_Mime_Headers_MailboxHeader\removeAddresses(), Swift_Mime_Headers_PathHeader\setAddress(), setEncoder(), setGrammar(), and Swift_Mime_Headers_MailboxHeader\setNameAddresses().
setCharset | ( | $charset | ) |
Set the character set used in this Header.
string | $charset |
Implements Swift_Mime_Header.
Definition at line 82 of file AbstractHeader.php.
References clearCachedValueIf().
setEncoder | ( | Swift_Mime_HeaderEncoder | $encoder | ) |
Set the encoder used for encoding the header.
Swift_Mime_HeaderEncoder | $encoder |
Definition at line 130 of file AbstractHeader.php.
References setCachedValue().
Referenced by Swift_Mime_Headers_MailboxHeader\__construct(), and Swift_Mime_Headers_UnstructuredHeader\__construct().
|
protected |
Set the name of this Header field.
string | $name |
Definition at line 229 of file AbstractHeader.php.
Referenced by Swift_Mime_Headers_PathHeader\__construct(), Swift_Mime_Headers_UnstructuredHeader\__construct(), Swift_Mime_Headers_MailboxHeader\__construct(), Swift_Mime_Headers_IdentificationHeader\__construct(), and Swift_Mime_Headers_DateHeader\__construct().
setGrammar | ( | Swift_Mime_Grammar | $grammar | ) |
Set the grammar used for the header.
Swift_Mime_Grammar | $grammar |
Definition at line 151 of file AbstractHeader.php.
References setCachedValue().
Referenced by __construct().
setLanguage | ( | $lang | ) |
Set the language used in this Header.
For example, for US English, 'en-us'. This can be unspecified.
string | $lang |
Definition at line 109 of file AbstractHeader.php.
References $lang, and clearCachedValueIf().
setMaxLineLength | ( | $lineLength | ) |
Set the maximum length of lines in the header (excluding EOL).
int | $lineLength |
Definition at line 182 of file AbstractHeader.php.
References clearCachedValueIf().
|
protected |
Test if a token needs to be encoded or not.
string | $token |
Definition at line 321 of file AbstractHeader.php.
Referenced by encodeWords(), and getEncodableWordTokens().
toString | ( | ) |
Get this Header rendered as a RFC 2822 compliant string.
Swift_RfcComplianceException |
Implements Swift_Mime_Header.
Definition at line 205 of file AbstractHeader.php.
References _tokensToString(), and toTokens().
Referenced by __toString().
|
protected |
Generate a list of all tokens in the final header.
string | $string | The string to tokenize |
Definition at line 450 of file AbstractHeader.php.
References generateTokenLines(), and Swift_Mime_Header\getFieldBody().
Referenced by toString().
|
private |
Definition at line 65 of file AbstractHeader.php.
Referenced by getCachedValue().
|
private |
Definition at line 58 of file AbstractHeader.php.
Referenced by getCharset(), and getTokenAsEncodedWord().
|
private |
Definition at line 37 of file AbstractHeader.php.
Referenced by getEncoder().
|
private |
Definition at line 30 of file AbstractHeader.php.
Referenced by getGrammar().
|
private |
Definition at line 51 of file AbstractHeader.php.
Referenced by getLanguage().
|
private |
Definition at line 44 of file AbstractHeader.php.
Referenced by getMaxLineLength().
|
private |
Definition at line 23 of file AbstractHeader.php.
Referenced by getFieldName().