Class: Legion::Extensions::Absorbers::Matchers::Url
- Defined in:
- lib/legion/extensions/absorbers/matchers/url.rb
Constant Summary
Constants included from Definitions
Constants included from Helpers::Base
Helpers::Base::NAMESPACE_BOUNDARIES
Instance Attribute Summary
Attributes inherited from Base
Class Method Summary collapse
Methods inherited from Base
#absorb, #absorb_raw, #absorb_to_knowledge, description, pattern, patterns, #report_progress, #translate, #with_token
Methods included from Definitions
#definition, #definition_for, #definitions
Methods included from Helpers::Lex
#default_settings, included, #runner_desc
Methods included from Helpers::Base
#actor_class, #actor_const, #actor_name, #amqp_prefix, #calling_class, #calling_class_array, #from_json, #full_path, #lex_class, #lex_const, #lex_name, #lex_slug, #log_tag, #normalize, #runner_class, #runner_const, #runner_name, #segments, #settings_path, #table_prefix, #to_dotted_hash
Methods included from Helpers::Task
#generate_task_id, #generate_task_log, #task_update
Methods included from Helpers::Logger
Methods included from Helpers::Secret
reset_identity!, resolve_identity!, #secret
Methods included from Helpers::Core
Class Method Details
.match?(pattern, input) ⇒ Boolean
12 13 14 15 16 17 18 19 20 |
# File 'lib/legion/extensions/absorbers/matchers/url.rb', line 12 def self.match?(pattern, input) uri = parse_uri(input) return false unless uri host_pattern, path_pattern = split_pattern(pattern) return false unless host_matches?(host_pattern, uri.host) path_matches?(path_pattern || '**', uri.path) end |
.type ⇒ Object
10 |
# File 'lib/legion/extensions/absorbers/matchers/url.rb', line 10 def self.type = :url |