khellang/Nancy.Swagger — pull request #39 by jchannon (2014-08-11 12:10:36+00:00)
Title: Include class based properties and set ref/type properly

Please see the demo example. It returns a `User` from a `GET`

`User` has a property of `Address` which wasnt included in the JSON.

'User' was being set as `$ref`previously which is incorrect if its a top level model for a operation it should be `type`

This PR now inspects properties of models to see if they are classes eg/ `Address` and includes those as a `$ref` whilst also including them in the JSON output. Here is the sample:

```

```

The one thing not working with this PR is the `ISwaggerModelDataProvider`, you'll see I've added an `AddressModelDataProvider` but this isnt being picked up. A tweak to `SwaggerMetadataConverter` is needed