Skip to content

Better handling of multi-line comments for all generators#3278

Merged
wing328 merged 2 commits intoswagger-api:masterfrom
wing328:escape_unsafe_2
Jul 2, 2016
Merged

Better handling of multi-line comments for all generators#3278
wing328 merged 2 commits intoswagger-api:masterfrom
wing328:escape_unsafe_2

Conversation

@wing328
Copy link
Contributor

@wing328 wing328 commented Jul 2, 2016

  • to cover all remaining generators
  • to handle block comment starter (e.g. /*, =begin)
  • to add underscore instead of removing the block comment starter and terminator

@wing328 wing328 merged commit 82ee6bb into swagger-api:master Jul 2, 2016
@wing328 wing328 deleted the escape_unsafe_2 branch July 2, 2016 16:49
@wing328
Copy link
Contributor Author

wing328 commented Jul 3, 2016

For #3201

@edstover
Copy link

edstover commented Oct 12, 2016

Hi,

I think this change has the side-effect of changing media type declarations from "*/*" to "*_/_*". I've noticed this in generated API specifications when the following yaml is used:

consumes:
- application/json
- text/plain
- "*/*"
produces:
- application/json

The resulting Java API when generated using "spring" for the language looks like this:

produces = { "application/json" },
consumes = { "application/json", "text/plain", "*_/_*" },
method = RequestMethod.GET)

Can the substitution with underscores be suppressed for media types?

@wing328
Copy link
Contributor Author

wing328 commented Nov 8, 2016

@edstover "/" is better handled via #4155

Please pull the latest master to give it a try.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants