Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing @PathVariable declarations in examples in webmvc.adoc #25006

Closed
wants to merge 2 commits into from

Conversation

swapy
Copy link
Contributor

@swapy swapy commented May 3, 2020

We say
For example, given URL "/spring-web-3.0.5 .jar", the following method extracts the name, version, and file extension:

So added PathVariable name to complete the code.

swapy added 2 commits May 3, 2020 11:31

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
We say
" For example, given URL "/spring-web-3.0.5 .jar", the following method extracts the name, version, and file extension:"

So added PathVariable name to complete the code.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
minor fix for kotlin
@pivotal-issuemaster
Copy link

@swapy Please sign the Contributor License Agreement!

Click here to manually synchronize the status of this Pull Request.

See the FAQ for frequently asked questions.

@pivotal-issuemaster
Copy link

@swapy Thank you for signing the Contributor License Agreement!

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged or decided on label May 3, 2020
@sbrannen sbrannen self-assigned this May 3, 2020
@sbrannen sbrannen added type: documentation A documentation task and removed status: waiting-for-triage An issue we've not yet triaged or decided on labels May 3, 2020
@sbrannen sbrannen changed the title Added pathvariable name as described. Add missing @PathVariable in example in webmvc.adoc May 3, 2020
@sbrannen sbrannen added this to the 5.3 M1 milestone May 3, 2020
@sbrannen sbrannen changed the title Add missing @PathVariable in example in webmvc.adoc Add missing @PathVariable declarations in examples in webmvc.adoc May 3, 2020
@sbrannen
Copy link
Member

sbrannen commented May 3, 2020

Thanks for the PR. We'll get this merged soon.

@sbrannen sbrannen modified the milestones: 5.3 M1, 5.2.7 May 4, 2020
@@ -1634,15 +1634,15 @@ extracts the name, version, and file extension:
.Java
----
@GetMapping("/{name:[a-z-]+}-{version:\\d\\.\\d\\.\\d}{ext:\\.[a-z]+}")
public void handle(@PathVariable String version, @PathVariable String ext) {
public void handle(@PathVariable name, @PathVariable String version, @PathVariable String ext) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI: you accidentally deleted the String type declaration for the name parameter.

But don't worry about it: I've fixed it locally prior to merging.

Suggested change
public void handle(@PathVariable name, @PathVariable String version, @PathVariable String ext) {
public void handle(@PathVariable String name, @PathVariable String version, @PathVariable String ext) {

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for that and thanks a lot. I will be careful next time.

@jhoeller jhoeller added the in: web Issues in web modules (web, webmvc, webflux, websocket) label May 18, 2020
FelixFly pushed a commit to FelixFly/spring-framework that referenced this pull request Aug 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: web Issues in web modules (web, webmvc, webflux, websocket) type: documentation A documentation task
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants