Class: MDEXClient::MData::RangeFilter

Inherits:
Node
  • Object
show all
Defined in:
lib/mdex_client/mdata/range_filter.rb

Defined Under Namespace

Modules: GeocodeReference, LowerBound, UpperBound Classes: UnknownFilterType

Instance Attribute Summary collapse

Attributes inherited from Node

#element

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Node

#css, #dimension_value_state_list, #initialize, #property_list, #record_list, #xpath

Constructor Details

This class inherits a constructor from MDEXClient::MData::Node

Instance Attribute Details

#attribute_nameObject

Returns the value of attribute attribute_name.



16
17
18
# File 'lib/mdex_client/mdata/range_filter.rb', line 16

def attribute_name
  @attribute_name
end

Class Method Details

.from_element(element) ⇒ Object



26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# File 'lib/mdex_client/mdata/range_filter.rb', line 26

def self.from_element(element)
case element.name
when "LessThanFilter"
	LessThanFilter.new(element)
  			when "LessThanOrEqualFilter"
	LessThanOrEqualFilter.new(element)
when "GreaterThanFilter"
	GreaterThanFilter.new(element)
  			when "GreaterThanOrEqualFilter"
	GreaterThanOrEqualFilter.new(element)
when "BetweenFilter"
	BetweenFilter.new(element)
else
	raise UnknownFilterType.new(element.name)
end
end

Instance Method Details

#attribute_attrObject



22
23
24
# File 'lib/mdex_client/mdata/range_filter.rb', line 22

def attribute_attr
	{ "AttributeName" => @attribute_name }
end

#initialize_from_element!Object



18
19
20
# File 'lib/mdex_client/mdata/range_filter.rb', line 18

def initialize_from_element!
	@attribute_name = element["AttributeName"]
end