Looking to hire Laravel developers? Try LaraJobs

xsd-reader-laravel-cached maintained by stormcode

Description
Read any XML Schema (XSD) programmatically with PHP
Last update
2023/01/22 00:40 (dev-master)
License
Links
Downloads
58
Tags

Comments
comments powered by Disqus

PHP XSD Reader

Read any XML Schema (XSD) programmatically with PHP.

Installation

The recommended way to install the xsd-reader via Composer:

composer require 'stormcode/xsd-reader-laravel-cached'

Getting started

use CollectHouse\XML\XSDReader\SchemaReader;

$reader = new SchemaReader();
$schema = $reader->readFile("http://www.example.com/exaple.xsd");

// $schema is instance of CollectHouse\XML\XSDReader\Schema\Schema;

// Now you can navigate the entire schema structure

foreach ($schema->getSchemas() as $innerSchema){

}
foreach ($schema->getTypes() as $type){

}
foreach ($schema->getElements() as $element){

}
foreach ($schema->getGroups() as $group){

}
foreach ($schema->getAttributes() as $attr){

}
foreach ($schema->getAttributeGroups() as $attrGroup){

}

Note

The code in this project is provided under the MIT license. For professional support contact goetas@gmail.com or visit https://www.goetas.com