<div dir="ltr">The source is up on sourceforge now. It does need some spring cleaning and documenting which I hope to get to next week.<div><br></div><div>The documentation is in the following directory </div><div><a href="https://sourceforge.net/p/jsonschema/code/ci/master/tree/Web/">https://sourceforge.net/p/jsonschema/code/ci/master/tree/Web/</a></div>
<div><br></div><div>The origins of this work is that about 70% of the effort in working groups goes into debating 'bikeshed' type issues (as in what color to paint it) that really don't matter. Things like choice of encoding (just use JSON) or binding (Any reason to not use HTTP + SSL) and so on.</div>
<div><br></div><div>And 70% of the effort of the editor would go into making changes to the spec which would need to be reflected accurately in six different parts of the document and the reference code and then conformant examples generated and inserted at the right place and then other folk would have to check it was all done right.</div>
<div><br></div><div><br></div><div>So JSONSchema converts an abstract schema definition (in a programming language syntax, not JSON encoding!) and produces a stub client API and a stub server with the appropriate holes to plug in your semantics. You can then write documentation and insert examples from running code (provided you like documentation in either HTML or Internet Draft format at the moment).</div>
<div><br></div><div>It is all written in C# and has been run on OSX and Linux under Mono (binary distributions to follow). The synth currently only generates code in C# but I plan to add C and probably Objective C down the line. The meta-synthesiser is also on sourceforge and open source:</div>
<div><br></div><div><a href="https://sourceforge.net/projects/goedel/">https://sourceforge.net/projects/goedel/</a><br></div><div><div><br clear="all"><div><br></div><div>The compiler only supports RPC like interactions at the moment, i.e. query/response. But I am planning to expand the generator to support an additional interaction pattern in which the client opens a transaction and receives a series of async callbacks. That would be suited to supporting chat like protocols.</div>
<div><br></div><div>One of the things I realized as I was doing all this is that all Web Services really consist of are glorified RPC calls in a different syntax.</div><div><br></div><div><br></div><div>The code generated right now is targeted at being reference code but there is no reason why the synth should not generate production code. </div>
<div><br></div>-- <br>Website: <a href="http://hallambaker.com/">http://hallambaker.com/</a><br>
</div></div></div>