ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
Sabre\Xml Namespace Reference

Namespaces

 Deserializer
 
 Element
 
 Serializer
 

Data Structures

class  ContextStackTest
 Test for the ContextStackTrait. More...
 
interface  Element
 This is the XML element interface. More...
 
class  InfiteLoopTest
 
class  LibXMLException
 This exception is thrown when the Readers runs into a parsing error. More...
 
class  Order
 asset for testMapValueObject() More...
 
class  OrderStatus
 asset for testMapValueObject() More...
 
class  ParseException
 This is a base exception for any exception related to parsing xml files. More...
 
class  Reader
 The Reader class expands upon PHP's built-in XMLReader. More...
 
class  ReaderTest
 
class  Service
 XML parsing and writing service. More...
 
class  ServiceTest
 
class  Version
 This class contains the version number for this package. More...
 
class  Writer
 The XML Writer class. More...
 
class  WriterTest
 
interface  XmlDeserializable
 Implementing the XmlDeserializable interface allows you to use a class as a deserializer for a specific element. More...
 
interface  XmlSerializable
 Objects implementing XmlSerializable can control how they are represented in Xml. More...
 

Functions

 pushContext ()
 Create a new "context". More...
 
 popContext ()
 Restore the previous "context". More...
 

Variables

trait ContextStackTrait
 Context Stack. More...
 
 $contextUri
 
 $namespaceMap = []
 
 $classMap = []
 
 $contextStack = []
 

Function Documentation

◆ popContext()

Sabre\Xml\popContext ( )

Restore the previous "context".

Returns
null

Definition at line 112 of file ContextStackTrait.php.

Referenced by Sabre\Xml\Reader\parseInnerTree().

112  {
113 
114  list(
115  $this->elementMap,
116  $this->contextUri,
117  $this->namespaceMap,
118  $this->classMap
119  ) = array_pop($this->contextStack);
120 
121  }
+ Here is the caller graph for this function:

◆ pushContext()

Sabre\Xml\pushContext ( )

Create a new "context".

This allows you to safely modify the elementMap, contextUri or namespaceMap. After you're done, you can restore the old data again with popContext.

Returns
null

Definition at line 96 of file ContextStackTrait.php.

References Sabre\Xml\$classMap, Sabre\Xml\$contextUri, and Sabre\Xml\$namespaceMap.

Referenced by Sabre\Xml\Reader\parseInnerTree().

96  {
97 
98  $this->contextStack[] = [
99  $this->elementMap,
103  ];
104 
105  }
+ Here is the caller graph for this function:

Variable Documentation

◆ $classMap

◆ $contextStack

Sabre::Xml\$contextStack = []
protected

Definition at line 85 of file ContextStackTrait.php.

◆ $contextUri

◆ $namespaceMap

Sabre::Xml\$namespaceMap = []

Definition at line 58 of file ContextStackTrait.php.

Referenced by Sabre\Xml\pushContext().

◆ ContextStackTrait

trait Sabre::Xml\ContextStackTrait
Initial value:
{
public $elementMap = []

Context Stack.

The Context maintains information about a document during either reading or writing.

During this process, it may be neccesary to override this context information.

This trait allows easy access to the context, and allows the end-user to override its settings for document fragments, and easily restore it again later.

Author
Evert Pot (http://evertpot.com/) http://sabre.io/license/ Modified BSD License

Definition at line 22 of file ContextStackTrait.php.