metaleap/go-xsd

How to use this tool to generate go structs from xsd files

Opened this issue · 1 comments

Hello,

I am new to golang and i am not clear on how to setup this command line tool. Can you point me in right direction, i am using windows OS. I need help with following:

  1. Setup this project
  2. Use this to convert xsd files to go classes

Thanks,
Rahul

i decided not to use the tool but the package directly

package main

import (
	"log"

	xsd "github.com/metaleap/go-xsd"
)

func main() {
	var (
		sd  *xsd.Schema
		err error
	)
	xsd.PkgGen.BaseCodePath = "/Users/myuser/go/src/myorganisation.com/myprogram"
	if sd, err = xsd.LoadSchema("my.xsd", true); err != nil {
		log.Fatal(err)
	}
	sd.MakeGoPkgSrcFile()
}