Class: Redis::Commands::Search::TagField
- Defined in:
- lib/redis/commands/modules/search/field.rb
Overview
A TAG field, indexing one or more delimited tag tokens.
Instance Attribute Summary
Attributes inherited from Field
#alias_name, #name, #options, #query, #type
Instance Method Summary collapse
-
#eq(value) ⇒ Query
Add a tag-equality predicate (+@field:value+) to the bound query.
-
#initialize(name, query = nil, **options) ⇒ TagField
constructor
Build a
TAGfield.
Methods inherited from Field
Constructor Details
#initialize(name, query = nil, **options) ⇒ TagField
Build a TAG field.
72 73 74 |
# File 'lib/redis/commands/modules/search/field.rb', line 72 def initialize(name, query = nil, **) super(name, :tag, query, **) end |
Instance Method Details
#eq(value) ⇒ Query
Add a tag-equality predicate (+@field:value+) to the bound query.
80 81 82 |
# File 'lib/redis/commands/modules/search/field.rb', line 80 def eq(value) query.add_predicate(TagEqualityPredicate.new(@alias_name || name, value)) end |