I am trying to use Swagger to create an API in C#, using the nancyfx
language option.
The Models are all generated with private setters, for example:
public sealed class ApiResponse: IEquatable<ApiResponse>
{
public int? Code { get; private set; }
public string Type { get; private set; }
public string Message { get; private set; }
...
}
I want to serialize this object to XML. Normally I would use the C#
XmlSerializer class to do that, but it fails because it requires public
getters and setters on all serialized members.
How can I resolve this?
* Is there a recommended XML serializer that works with swagger-codegen
output?
* Is there a way to tell swagger-codegen to create objects with public
setters?
--
You received this message because you are subscribed to the Google Groups
"Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.