XsdElementDefinition
in package
implements
JsonSerializable
XsdElementDefinition
Represents the definition of an XML element.
Table of Contents
Interfaces
- JsonSerializable
Properties
- $annotation : string
- $attributes : array<string|int, XsdAttributeDefinition>
- $autocomplete : array<string|int, mixed>
- $elements : array<string|int, XsdElementDefinition>
- $generate : string
- $lookup : string
- $name : string
- $occurs : stdClass
- $type : XmlNode
- $_node : XmlNode
- The XML node.
- $_schema : XsdSchemaDefinition
- The schema definition.
Methods
- __construct() : mixed
- Constructor.
- __get() : mixed
- Getter.
- CreateObject() : XmlSerialized
- Creates an XmlSerialized object based on the element definition.
- jsonSerialize() : object
- Returns the data as a plain object for JSON serialization.
- ToObject() : object
- Returns the data as a plain object.
Properties
$annotation read-only
public
string
$annotation
The annotation of the element.
$attributes read-only
public
array<string|int, XsdAttributeDefinition>
$attributes
The list of attributes associated with the element.
$autocomplete read-only
public
array<string|int, mixed>
$autocomplete
The list of values for auto-completion.
$elements read-only
public
array<string|int, XsdElementDefinition>
$elements
The list of child elements.
$generate read-only
public
string
$generate
The command for generating the element.
$lookup read-only
public
string
$lookup
The command for generating inter-object relationships.
$name read-only
public
string
$name
The name of the element.
$occurs read-only
public
stdClass
$occurs
An object defining the minimum and maximum occurrences of the element.
$type read-only
public
XmlNode
$type
The type of the element.
$_node
The XML node.
private
XmlNode
$_node
$_schema
The schema definition.
private
XsdSchemaDefinition
$_schema
Methods
__construct()
Constructor.
public
__construct(XmlNode $elementNode, mixed $schema) : mixed
Parameters
- $elementNode : XmlNode
-
The XML node representing the element.
- $schema : mixed
-
The schema definition.
__get()
Getter.
public
__get(string $property) : mixed
Parameters
- $property : string
-
The name of the property.
CreateObject()
Creates an XmlSerialized object based on the element definition.
public
CreateObject() : XmlSerialized
Return values
XmlSerializedjsonSerialize()
Returns the data as a plain object for JSON serialization.
public
jsonSerialize() : object
Return values
objectToObject()
Returns the data as a plain object.
public
ToObject() : object