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
readonly
Returns the value of attribute long_value.
-
#value ⇒ Object
readonly
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 |
# File 'lib/rets/metadata/lookup_type.rb', line 6 def initialize(lookup_type_fragment) @value = lookup_type_fragment["Value"].strip @long_value = lookup_type_fragment["LongValue"].strip end |
Instance Attribute Details
#long_value ⇒ Object (readonly)
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 |
#value ⇒ Object (readonly)
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.
14 15 16 |
# File 'lib/rets/metadata/lookup_type.rb', line 14 def print_tree(out = $stdout) out.puts " #{long_value} -> #{value}" end |