I want to create a Golang structure from XSD (Structure XSD).
I read a post that generated Go structures from XSD that recommend using go-xsd, but I downloaded go-xsd and installed xsd-makepkg and I cannot generate my structure.
What am I doing?
xsd-makepkg -basepath = "/ Users / XSD_Access /" -goinst = false
-xsd-makepkg: this is the binary file create from apart go-xsd-pkg
-basepath: Contains a route where I have an XSD structure that I want to convert to struct. -goinst: I did not install go-buildrun and I think this is not necessary, for this reason is ser false
What is the result of the team?
A folder ($ GOPATH / usr / Users / XSD_Access /) that contains other folders with all the followers of the XML wrapper
- docbook.org
- docs.oasis-open.org
- kbcafe.com
- khronos.org
- schemas.opengis.net
- thearchitect.co.uk
- Users
- www.w3.org
XSD structure
<?xml version="1.0" encoding="UTF-8"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified"> <xs:element name="Request" type="Request"/> <xs:complexType name="Request"> <xs:annotation> <xs:documentation xml:lang="sp"><![CDATA[ Comment xxxxx ]]></xs:documentation> </xs:annotation> <xs:sequence> <xs:element name="idOne" type="xs:string" minOccurs="0" maxOccurs="1"> <xs:annotation> <xs:documentation xml:lang="sp"><![CDATA[Comment xxxxx ]]></xs:documentation> </xs:annotation> </xs:element> <xs:element name="idTwo" type="xs:string" minOccurs="0" maxOccurs="1"> <xs:annotation> <xs:documentation xml:lang="sp"><![CDATA[Comment xxxxxx ]]></xs:documentation> </xs:annotation> </xs:element> </xs:sequence> </xs:complexType> </xs:schema>
Can someone tell me what I'm doing wrong or what step I skipped that it prevents me from creating a structure from my XSD structure?
Thanks in advance
xml go xsd
Carlos Andrés García
source share