RicoSuter/NSwag

C# Code Generation doesn't validate patterns

Open

#3,145 建立於 2020年11月6日

在 GitHub 查看
 (7 留言) (0 反應) (0 負責人)C# (1,189 fork)batch import
help wantedtype: enhancement

倉庫指標

Star
 (6,291 star)
PR 合併指標
 (30 天內沒有已合併 PR)

描述

Hi everyone,

I noticed that the C# code generation doesn't validate patterns (on the client side). If I annotate a parameter of type string with a pattern (e.g. "^v[1-9]$"), I expect the Api method to throw an ApiException when the supplied string doesn't match the pattern.

I'd be happy to open a PR. Is that something this project could use?

貢獻者指南