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 HttpHeaders getter and setter for Accept-Language [SPR-15024] #19591

Closed
spring-projects-issues opened this issue Dec 15, 2016 · 4 comments
Closed
Assignees
Labels
in: web type: enhancement
Milestone

Comments

@spring-projects-issues
Copy link
Collaborator

spring-projects-issues commented Dec 15, 2016

Sébastien Deleuze opened SPR-15024 and commented


Issue Links:

Referenced from: commits 712a632, 9376748, fa56361, bd8af55, 9764d57

@spring-projects-issues
Copy link
Collaborator Author

spring-projects-issues commented Dec 15, 2016

Sébastien Deleuze commented

Fixed by this commit. Notice that we take advantage of the Locale.LanguageRange introduced in Java 8.

@spring-projects-issues
Copy link
Collaborator Author

spring-projects-issues commented Dec 16, 2016

Rossen Stoyanchev commented

I've added one more method to expose Accept-Language as List<Locale>. See commit fa5636.

@spring-projects-issues
Copy link
Collaborator Author

spring-projects-issues commented Dec 16, 2016

Rossen Stoyanchev commented

On second thought I've switched to returning the most preferred Locale only. The idea is that if you actually need to examine the full prioritized list then it's best to use Locale#filter. Here is what it looks like actually applied.

@spring-projects-issues
Copy link
Collaborator Author

spring-projects-issues commented Dec 20, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: web type: enhancement
Projects
None yet
Development

No branches or pull requests

2 participants