Liste de tous les membres
Fonctions membres publiques
- DOMIT_Lite_Document ()
- resolveErrors ($truthVal)
- setConnection ($host, $path= '/', $port=80, $timeout=0, $user=null, $password=null)
- preserveWhitespace ($truthVal)
- setAuthorization ($user, $password)
- setProxyConnection ($host, $path= '/', $port=80, $timeout=0, $user=null, $password=null)
- setProxyAuthorization ($user, $password)
- useHTTPClient ($truthVal)
- getErrorCode ()
- getErrorString ()
- expandEmptyElementTags ($truthVal, $expandEmptyElementExceptions=false)
- & setDocumentElement (&$node)
- & appendChild (&$node)
- & replaceChild (&$newChild, &$oldChild)
- & insertBefore (&$newChild, &$refChild)
- & removeChild (&$oldChild)
- & createElement ($tagName)
- & createTextNode ($data)
- & createCDATASection ($data)
- & getElementsByTagName ($tagName)
- & getElementsByPath ($pattern, $nodeIndex=0)
- parseXML_utf8 ($xmlText, $useSAXY=true, $preserveCDATA=true, $fireLoadEvent=false)
- parseXML ($xmlText, $useSAXY=true, $preserveCDATA=true, $fireLoadEvent=false)
- loadXML_utf8 ($filename, $useSAXY=true, $preserveCDATA=true, $fireLoadEvent=false)
- loadXML ($filename, $useSAXY=true, $preserveCDATA=true, $fireLoadEvent=false)
- establishConnection ($url)
- getTextFromFile ($filename)
- saveXML_utf8 ($filename, $normalized=false)
- saveXML ($filename, $normalized=false)
- saveTextToFile ($filename, $text)
- parsedBy ()
- getText ()
- getDocType ()
- getXMLDeclaration ()
- setXMLDeclaration ($decl)
- & getDOMImplementation ()
- load (&$contextNode)
- getVersion ()
- appendEntityTranslationTable ($table)
- toArray ()
- & cloneNode ($deep=false)
- toString ($htmlSafe=false, $subEntities=false)
Attributs publics
Documentation des fonctions membres
& DOMIT_Lite_Document::appendChild |
( |
&$ |
node | ) |
|
DOMIT_Lite_Document::appendEntityTranslationTable |
( |
$ |
table | ) |
|
Appends an array of entity mappings to the existing translation table
Intended mainly to facilitate the conversion of non-ASCII entities into equivalent characters
- Paramètres:
-
array | A list of entity mappings in the format: array('&' => '&'); |
& DOMIT_Lite_Document::cloneNode |
( |
$ |
deep = false | ) |
|
Copies a node and/or its children
- Paramètres:
-
boolean | True if all child nodes are also to be cloned |
- Renvoie:
- Object A copy of the node and/or its children
Réimplémentée à partir de DOMIT_Lite_Node.
Références $i, et $total.
& DOMIT_Lite_Document::createCDATASection |
( |
$ |
data | ) |
|
Creates a new DOMIT_Lite_CDATASection node
- Paramètres:
-
string | The text of the CDATASection |
- Renvoie:
- Object The new CDATASection node
Références $data.
& DOMIT_Lite_Document::createElement |
( |
$ |
tagName | ) |
|
Creates a new DOMIT_Lite_Element node
- Paramètres:
-
string | The tag name of the element |
- Renvoie:
- Object The new element
& DOMIT_Lite_Document::createTextNode |
( |
$ |
data | ) |
|
Creates a new DOMIT_Text node
- Paramètres:
-
string | The text of the node |
- Renvoie:
- Object The new text node
Références $data.
DOMIT_Lite_Document::DOMIT_Lite_Document |
( |
| ) |
|
DOMIT_Lite_Document::establishConnection |
( |
$ |
url | ) |
|
DOMIT_Lite_Document::expandEmptyElementTags |
( |
$ |
truthVal, |
|
|
$ |
expandEmptyElementExceptions = false |
|
) |
| |
Specifies whether elements tags will be rendered to string as <element></element> rather than <element>
- Paramètres:
-
boolean | True if the expanded form is to be used |
mixed | An array of tag names that should be excepted from expandEmptyElements rule (optional) |
Références $expandEmptyElementExceptions.
DOMIT_Lite_Document::getDocType |
( |
| ) |
|
Returns the doctype text
- Renvoie:
- string The doctype text, or an emty string
& DOMIT_Lite_Document::getDOMImplementation |
( |
| ) |
|
& DOMIT_Lite_Document::getElementsByPath |
( |
$ |
pattern, |
|
|
$ |
nodeIndex = 0 |
|
) |
| |
Retrieves an element or DOMIT_NodeList of elements corresponding to an Xpath-like expression.
- Paramètres:
-
string | The query pattern |
int | If a single node is to be returned (rather than the entire NodeList) the index of that node |
- Renvoie:
- mixed A NodeList or single node that matches the pattern
Réimplémentée à partir de DOMIT_Lite_Node.
& DOMIT_Lite_Document::getElementsByTagName |
( |
$ |
tagName | ) |
|
Retrieves a NodeList of child elements with the specified tag name
- Paramètres:
-
string | The matching element tag name |
- Renvoie:
- Object A NodeList of found elements
DOMIT_Lite_Document::getErrorCode |
( |
| ) |
|
Returns the error code from the underlying SAX parser
- Renvoie:
- int The error code
DOMIT_Lite_Document::getErrorString |
( |
| ) |
|
Returns the error string from the underlying SAX parser
- Renvoie:
- string The error string
DOMIT_Lite_Document::getText |
( |
| ) |
|
Returns the concatented text of the current node and its children
- Renvoie:
- string The concatented text of the current node and its children
Réimplémentée à partir de DOMIT_Lite_Node.
DOMIT_Lite_Document::getTextFromFile |
( |
$ |
filename | ) |
|
DOMIT_Lite_Document::getVersion |
( |
| ) |
|
Returns the current version of DOMIT! Lite
- Renvoie:
- Object The current version of DOMIT! Lite
DOMIT_Lite_Document::getXMLDeclaration |
( |
| ) |
|
Returns the xml declaration text
- Renvoie:
- mixed The xml declaration text, or an empty string
& DOMIT_Lite_Document::insertBefore |
( |
&$ |
newChild, |
|
|
&$ |
refChild |
|
) |
| |
DOMIT_Lite_Document::load |
( |
&$ |
contextNode | ) |
|
Manages the firing of the onLoad() event
- Paramètres:
-
Object | The parent node of the current recursion |
Références $i, et $total.
Référencé par parseXML().
DOMIT_Lite_Document::loadXML |
( |
$ |
filename, |
|
|
$ |
useSAXY = true , |
|
|
$ |
preserveCDATA = true , |
|
|
$ |
fireLoadEvent = false |
|
) |
| |
Parses an xml file
- Paramètres:
-
string | The xml file to be parsed |
boolean | True if SAXY is to be used instead of Expat |
boolean | False if CDATA Section are to be generated as Text nodes |
boolean | True if onLoad is to be called on each node after parsing |
- Renvoie:
- boolean True if parsing is successful
Références $filename, getTextFromFile(), et parseXML().
DOMIT_Lite_Document::loadXML_utf8 |
( |
$ |
filename, |
|
|
$ |
useSAXY = true , |
|
|
$ |
preserveCDATA = true , |
|
|
$ |
fireLoadEvent = false |
|
) |
| |
Parses an xml file; first encodes text as UTF-8
- Paramètres:
-
string | The xml file to be parsed |
boolean | True if SAXY is to be used instead of Expat |
boolean | False if CDATA Section are to be generated as Text nodes |
boolean | True if onLoad is to be called on each node after parsing |
- Renvoie:
- boolean True if parsing is successful
Références $filename, getTextFromFile(), et parseXML_utf8().
DOMIT_Lite_Document::parsedBy |
( |
| ) |
|
Indicates the SAX parser used to parse the current document
- Renvoie:
- string Either "SAXY_LITE" or "EXPAT"
DOMIT_Lite_Document::parseXML |
( |
$ |
xmlText, |
|
|
$ |
useSAXY = true , |
|
|
$ |
preserveCDATA = true , |
|
|
$ |
fireLoadEvent = false |
|
) |
| |
Parses an xml string
- Paramètres:
-
string | The xml text to be parsed |
boolean | True if SAXY is to be used instead of Expat |
boolean | False if CDATA Section are to be generated as Text nodes |
boolean | True if onLoad is to be called on each node after parsing |
- Renvoie:
- boolean True if parsing is successful
Références load(), et DOMIT_Utilities::validateXML().
Référencé par loadXML(), et parseXML_utf8().
DOMIT_Lite_Document::parseXML_utf8 |
( |
$ |
xmlText, |
|
|
$ |
useSAXY = true , |
|
|
$ |
preserveCDATA = true , |
|
|
$ |
fireLoadEvent = false |
|
) |
| |
Parses an xml string; first encodes string as UTF-8
- Paramètres:
-
string | The xml text to be parsed |
boolean | True if SAXY is to be used instead of Expat |
boolean | False if CDATA Section are to be generated as Text nodes |
boolean | True if onLoad is to be called on each node after parsing |
- Renvoie:
- boolean True if parsing is successful
Références parseXML().
Référencé par loadXML_utf8().
DOMIT_Lite_Document::preserveWhitespace |
( |
$ |
truthVal | ) |
|
Specifies whether DOMIT! preserves whitespace when parsing
- Paramètres:
-
boolean | True if whitespace is to be preserved |
& DOMIT_Lite_Document::removeChild |
( |
&$ |
oldChild | ) |
|
Removes a node from the childNodes list of the current node
- Paramètres:
-
Object | The node to be removed |
- Renvoie:
- Object The removed node
Réimplémentée à partir de DOMIT_Lite_ChildNodes_Interface.
& DOMIT_Lite_Document::replaceChild |
( |
&$ |
newChild, |
|
|
&$ |
oldChild |
|
) |
| |
DOMIT_Lite_Document::resolveErrors |
( |
$ |
truthVal | ) |
|
Specifies whether DOMIT! Lite will try to fix invalid XML before parsing begins
- Paramètres:
-
boolean | True if errors are to be resolved |
DOMIT_Lite_Document::saveTextToFile |
( |
$ |
filename, |
|
|
$ |
text |
|
) |
| |
DOMIT_Lite_Document::saveXML |
( |
$ |
filename, |
|
|
$ |
normalized = false |
|
) |
| |
DOMIT_Lite_Document::saveXML_utf8 |
( |
$ |
filename, |
|
|
$ |
normalized = false |
|
) |
| |
DOMIT_Lite_Document::setAuthorization |
( |
$ |
user, |
|
|
$ |
password |
|
) |
| |
Specifies basic authentication for an http connection
- Paramètres:
-
string | The user name |
string | The password |
Références $user.
DOMIT_Lite_Document::setConnection |
( |
$ |
host, |
|
|
$ |
path = '/' , |
|
|
$ |
port = 80 , |
|
|
$ |
timeout = 0 , |
|
|
$ |
user = null , |
|
|
$ |
password = null |
|
) |
| |
Specifies the parameters of the http conection used to obtain the xml data
- Paramètres:
-
string | The ip address or domain name of the connection |
string | The path of the connection |
int | The port that the connection is listening on |
int | The timeout value for the connection |
string | The user name, if authentication is required |
string | The password, if authentication is required |
Références $host, $path, et $user.
Référencé par establishConnection().
& DOMIT_Lite_Document::setDocumentElement |
( |
&$ |
node | ) |
|
DOMIT_Lite_Document::setProxyAuthorization |
( |
$ |
user, |
|
|
$ |
password |
|
) |
| |
Specifies basic authentication for the proxy
- Paramètres:
-
string | The user name |
string | The password |
Références $user.
DOMIT_Lite_Document::setProxyConnection |
( |
$ |
host, |
|
|
$ |
path = '/' , |
|
|
$ |
port = 80 , |
|
|
$ |
timeout = 0 , |
|
|
$ |
user = null , |
|
|
$ |
password = null |
|
) |
| |
Specifies that a proxy is to be used to obtain the xml data
- Paramètres:
-
string | The ip address or domain name of the proxy |
string | The path to the proxy |
int | The port that the proxy is listening on |
int | The timeout value for the connection |
string | The user name, if authentication is required |
string | The password, if authentication is required |
Références $host, $path, et $user.
DOMIT_Lite_Document::setXMLDeclaration |
( |
$ |
decl | ) |
|
Returns the xml declaration text
- Renvoie:
- mixed The xml declaration text, or an empty string
DOMIT_Lite_Document::toArray |
( |
| ) |
|
Generates an array representation of the node and its children
- Renvoie:
- Array A representation of the node and its children
Réimplémentée à partir de DOMIT_Lite_Node.
Références $i, et $total.
DOMIT_Lite_Document::toString |
( |
$ |
htmlSafe = false , |
|
|
$ |
subEntities = false |
|
) |
| |
Generates a string representation of the node and its children
- Paramètres:
-
boolean | True if HTML readable output is desired |
boolean | True if illegal xml characters in text nodes and attributes should be converted to entities |
- Renvoie:
- string The string representation
Références $i, $total, et DOMIT_Lite_Node::forHTML().
Référencé par saveXML(), et saveXML_utf8().
DOMIT_Lite_Document::useHTTPClient |
( |
$ |
truthVal | ) |
|
Specifies whether an HTTP client should be used to establish a connection
- Paramètres:
-
boolean | True if an HTTP client is to be used to establish the connection |
Documentation des données membres
DOMIT_Lite_Document::$definedEntities = array() |
DOMIT_Lite_Document::$doctype |
DOMIT_Lite_Document::$documentElement |
DOMIT_Lite_Document::$doExpandEmptyElementTags = false |
DOMIT_Lite_Document::$doResolveErrors = false |
DOMIT_Lite_Document::$doUseHTTPClient = false |
DOMIT_Lite_Document::$errorCode = 0 |
DOMIT_Lite_Document::$errorString = '' |
DOMIT_Lite_Document::$expandEmptyElementExceptions = array() |
DOMIT_Lite_Document::$httpConnection = null |
DOMIT_Lite_Document::$implementation |
DOMIT_Lite_Document::$parser |
DOMIT_Lite_Document::$preserveWhitespace = false |
DOMIT_Lite_Document::$xmlDeclaration |
La documentation de cette classe a été générée à partir du fichier suivant :