Skip to content

Instantly share code, notes, and snippets.

@michabbb
Last active August 29, 2015 14:16
Show Gist options
  • Save michabbb/e8db9881bf2e3b106228 to your computer and use it in GitHub Desktop.
Save michabbb/e8db9881bf2e3b106228 to your computer and use it in GitHub Desktop.
try to add testunbound
public function testUnbound()
{
$xml = '
<xs:schema targetNamespace="http://www.example.com" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="packet">
<xs:complexType>
<xs:complexContent>
<xs:extension base="RequestPacketType">
<xs:sequence>
<xs:choice maxOccurs="unbounded">
<xs:element name="reseller" type="ResellerInput"/>
</xs:choice>
</xs:sequence>
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:element>
<xs:complexType name="ResellerInput">
<xs:choice maxOccurs="unbounded">
<xs:element name="add" type="ResellerAddInput"/>
</xs:choice>
</xs:complexType>
<xs:complexType name="ResellerAddInput">
<xs:sequence>
<xs:element name="gen-info" type="ResellerAddGenInfo"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ResellerAddGenInfo">
<xs:annotation>
<xs:documentation>Reseller adding data</xs:documentation>
</xs:annotation>
<xs:sequence>
<xs:element name="cname" type="string" minOccurs="0"/>
<xs:element name="pname" type="string"/>
<xs:element name="login" type="string"/>
<xs:element name="passwd" type="string"/>
</xs:sequence>
</xs:complexType>
<xs:simpleType name="string">
<xs:restriction base="xs:string">
<xs:whiteSpace value="collapse"/>
</xs:restriction>
</xs:simpleType>
<xs:complexType name="RequestPacketType">
<xs:attribute name="version" type="string"/>
</xs:complexType>
</xs:schema>
';
$items = $this->getClasses($xml);
print_r($items);
exit;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment