Class: Rets::Metadata::LookupType
- Inherits:
-
Object
- Object
- Rets::Metadata::LookupType
- Defined in:
- lib/rets/metadata/lookup_type.rb
Instance Attribute Summary collapse
-
#long_value ⇒ Object
Returns the value of attribute long_value.
-
#short_value ⇒ Object
Returns the value of attribute short_value.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(lookup_type_fragment) ⇒ LookupType
constructor
A new instance of LookupType.
-
#print_tree(out = $stdout) ⇒ Object
Print the tree to a file.
Constructor Details
#initialize(lookup_type_fragment) ⇒ LookupType
Returns a new instance of LookupType.
6 7 8 9 10 |
# File 'lib/rets/metadata/lookup_type.rb', line 6 def initialize(lookup_type_fragment) self.value = lookup_type_fragment["Value"] self.short_value = lookup_type_fragment["ShortValue"] self.long_value = lookup_type_fragment["LongValue"] end |
Instance Attribute Details
#long_value ⇒ Object
Returns the value of attribute long_value.
4 5 6 |
# File 'lib/rets/metadata/lookup_type.rb', line 4 def long_value @long_value end |
#short_value ⇒ Object
Returns the value of attribute short_value.
4 5 6 |
# File 'lib/rets/metadata/lookup_type.rb', line 4 def short_value @short_value end |
#value ⇒ Object
Returns the value of attribute value.
4 5 6 |
# File 'lib/rets/metadata/lookup_type.rb', line 4 def value @value end |
Instance Method Details
#print_tree(out = $stdout) ⇒ Object
Print the tree to a file
- out
-
The file to print to. Defaults to $stdout.
15 16 17 |
# File 'lib/rets/metadata/lookup_type.rb', line 15 def print_tree(out = $stdout) out.puts " #{long_value} -> #{value}" end |