Class: Qa::LinkedData::AuthorityUrlService
- Inherits:
-
Object
- Object
- Qa::LinkedData::AuthorityUrlService
- Defined in:
- app/services/qa/linked_data/authority_url_service.rb
Class Method Summary collapse
-
.build_url(action_config:, action:, action_request:, request_header: {}, substitutions: {}, subauthority: nil, language: nil) ⇒ Object
Build a url for an authority/subauthority for the specified action.
Class Method Details
.build_url(action_config:, action:, action_request:, request_header: {}, substitutions: {}, subauthority: nil, language: nil) ⇒ Object
Note:
All parameters after request_header are deprecated and will be removed in the next major release.
Build a url for an authority/subauthority for the specified action.
16 17 18 19 20 21 22 |
# File 'app/services/qa/linked_data/authority_url_service.rb', line 16 def build_url(action_config:, action:, action_request:, request_header: {}, substitutions: {}, subauthority: nil, language: nil) # rubocop:disable Metrics/ParameterLists request_header = build_request_header(substitutions, , language) if request_header.empty? action_validation(action) url_config = action_config.url_config selected_substitutions = url_config.extract_substitutions(combined_substitutions(action_config, action, action_request, request_header)) Qa::IriTemplateService.build_url(url_config: url_config, substitutions: selected_substitutions) end |