Class: Spider::QueryFuncs::Substr

Inherits:
UnaryFunction show all
Defined in:
lib/spiderfw/model/query_funcs.rb

Instance Attribute Summary (collapse)

Attributes inherited from Function

#mapper_fields

Instance Method Summary (collapse)

Methods inherited from UnaryFunction

#elements

Methods inherited from Function

#aggregate?, #elements, #func_name, func_name, #has_aggregates?, inherited, #inner_elements, #inspect

Constructor Details

- (Substr) initialize(el, start, length = nil)



165
166
167
168
169
# File 'lib/spiderfw/model/query_funcs.rb', line 165

def initialize(el, start, length=nil)
    @el = el
    @start = start
    @length = length
end

Instance Attribute Details

- (Object) length (readonly)

Returns the value of attribute length



163
164
165
# File 'lib/spiderfw/model/query_funcs.rb', line 163

def length
  @length
end

- (Object) start (readonly)

Returns the value of attribute start



163
164
165
# File 'lib/spiderfw/model/query_funcs.rb', line 163

def start
  @start
end