generate PHP classes from XSD?

后端 未结 8 2134
春和景丽
春和景丽 2020-12-05 07:41

Is there in the world analogues of JavaBeans or JAXB for PHP? Is it possible to generate PHP classes from XML schema?

It\'s common practice to publish API\'s as XSD

8条回答
  •  旧巷少年郎
    2020-12-05 08:00

    XSD schemas are usually written in WSDL files on SOAP Web Services.

    wsdl2php is a tool for parsing WSDL(XSD) schemas to php classes. It uses php's native SoapClient as it's client:

    https://github.com/jbarciauskas/wsdl2php

提交回复
热议问题