Class: Mail2_RFC822
Source Location: /Mail2-0.1.1/Mail2/RFC822.php
Inherited Variables
|
Inherited Methods
|
Class Details
[line 72]
Class Variables
Method Detail
__construct (Constructor) [line 152]
object Mail_RFC822 __construct(
[string
$address = null], [string
$default_domain = null], [boolean
$nest_groups = null], [boolean
$validate = null], [
$limit = null])
|
|
Sets up the object. The address must either be set here or when calling parseAddressList(). One or the other.
Parameters:
approximateCount [line 898]
int approximateCount(
string
$data)
|
|
Returns an approximate count of how many addresses are in the given string. This is APPROXIMATE as it only splits based on a comma which has no preceding backslash. Could be useful as large amounts of addresses will end up producing *large* structures when used with parseAddressList().
Parameters:
isValidInetAddress [line 916]
mixed isValidInetAddress(
string
$data, [boolean
$strict = false])
|
|
This is a email validating function separate to the rest of the class. It simply validates whether an email is of the common internet form: <user>@<domain>. This can be sufficient for most people. Optional stricter mode can be utilised which restricts mailbox characters allowed to alphanumeric, full stop, hyphen and underscore.
Parameters:
parseAddressList [line 172]
array parseAddressList(
[string
$address = null], [string
$default_domain = null], [boolean
$nest_groups = null], [boolean
$validate = null], [
$limit = null])
|
|
Starts the whole process. The address must either be set here or when creating the object. One or the other.
Parameters:
validateMailbox [line 608]
boolean validateMailbox(
string
&$mailbox)
|
|
Function to validate a mailbox, which is: mailbox = addr-spec ; simple address / phrase route-addr ; name and route-addr
Parameters:
_hasUnclosedBrackets [line 392]
boolean _hasUnclosedBrackets(
string
$string, string
$chars)
|
|
Checks if a string has an unclosed brackets or not. IMPORTANT: This function handles both angle brackets and square brackets;
Parameters:
_hasUnclosedBracketsSub [line 416]
integer _hasUnclosedBracketsSub(
string
$string, integer
&$num, string
$char)
|
|
Sub function that is used only by hasUnclosedBrackets().
Parameters:
_hasUnclosedQuotes [line 356]
boolean _hasUnclosedQuotes(
string
$string)
|
|
Checks if a string has unclosed quotes or not.
Parameters:
_isGroup [line 300]
boolean _isGroup(
string
$address)
|
|
Checks for a group at the start of the string.
Parameters:
_splitAddresses [line 225]
boolean _splitAddresses(
string
$address)
|
|
Splits an address into separate addresses.
Parameters:
_splitCheck [line 324]
mixed _splitCheck(
array
$parts, string
$char)
|
|
A common function that will check an exploded string.
Parameters:
_validateAddress [line 435]
mixed _validateAddress(
string
$address)
|
|
Function to begin checking the address.
Parameters:
_validateAddrSpec [line 826]
mixed _validateAddrSpec(
string
$addr_spec)
|
|
Function to validate an addr-spec. addr-spec = local-part "@" domain
Parameters:
_validateAtom [line 559]
boolean _validateAtom(
string
$atom)
|
|
Function to validate an atom which from rfc822 is: atom = 1*<any CHAR except specials, SPACE and CTLs> If validation ($this->validate) has been turned off, then validateAtom() doesn't actually check anything. This is so that you can split a list of addresses up before encoding personal names (umlauts, etc.), for example.
Parameters:
_validateDliteral [line 813]
boolean _validateDliteral(
string
$dliteral)
|
|
Function to validate a domain literal: domain-literal = "[" *(dtext / quoted-pair) "]"
Parameters:
_validateDomain [line 767]
mixed _validateDomain(
string
$domain)
|
|
Function to validate a domain, though this is not quite what you expect of a strict internet domain. domain = sub-domain *("." sub-domain)
Parameters:
_validateLocalPart [line 856]
mixed _validateLocalPart(
string
$local_part)
|
|
Function to validate the local part of an address: local-part = word *("." word)
Parameters:
_validatePhrase [line 519]
boolean _validatePhrase(
string
$phrase)
|
|
Function to validate a phrase.
Parameters:
_validateQuotedString [line 591]
boolean _validateQuotedString(
string
$qstring)
|
|
Function to validate quoted string, which is: quoted-string = <"> *(qtext/quoted-pair) <">
Parameters:
_validateRoute [line 745]
mixed _validateRoute(
string
$route)
|
|
Function to validate a route, which is: route = 1#("@" domain) ":"
Parameters:
_validateRouteAddr [line 696]
mixed _validateRouteAddr(
string
$route_addr)
|
|
This function validates a route-addr which is: route-addr = "<" [route] addr-spec ">" Angle brackets have already been removed at the point of getting to this function.
Parameters:
_validateSubdomain [line 794]
boolean _validateSubdomain(
string
$subdomain)
|
|
Function to validate a subdomain: subdomain = domain-ref / domain-literal
Parameters:
Documentation generated on Mon, 11 Mar 2019 16:04:25 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.
|
|