-
Notifications
You must be signed in to change notification settings - Fork 19
Добавил отображение подсказок на латинице в адресах #18
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -14,6 +14,7 @@ | |
| private Map<String, String> fromBound = new HashMap<>(); | ||
| private Map<String, String> toBound = new HashMap<>(); | ||
| private Boolean restrictValue = false; | ||
| private String language; | ||
|
|
||
| public static AddressRequestBuilder create(String query) { | ||
| return new AddressRequestBuilder(query); | ||
|
|
@@ -43,9 +44,15 @@ | |
| return this; | ||
| } | ||
|
|
||
| public AddressRequestBuilder outputLanguage(String language) { | ||
|
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Предлагаю сделать более типизировано: у нас есть конечный список языков, которые поддерживаются – это русский (ru) и английский (en). Можно сделать Enum, например: А при создании |
||
| this.language = language; | ||
| return this; | ||
|
Check warning on line 49 in src/main/java/com/kuliginstepan/dadata/client/domain/address/AddressRequestBuilder.java
|
||
| } | ||
|
|
||
|
|
||
| @Override | ||
| public AddressRequest build() { | ||
| return new AddressRequest(super.query, super.count, super.locationsBoost, locations, fromBound, toBound, | ||
| restrictValue); | ||
| restrictValue, language); | ||
| } | ||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Если название поля совпадает с полем в json, то аннотацию
@JsonPropertyне обязательно ставить