class Rubillow::Models::DeepSearchResult

Get a property's information with deeper data.

Attributes

fips_county[RW]

@return [String] FIPS county code. See {www.itl.nist.gov/fipspubs/fip6-4.htm}.

last_sold_date[RW]

@return [Date] last date property was sold

last_sold_price[RW]

@return [String] price property was last sold for

tax_assessment[RW]

@return [String] value of the last tax assessment

tax_assessment_year[RW]

@return [String] year of the last tax assessment

year_built[RW]

@return [String] year home was built

Protected Instance Methods

parse() click to toggle source

@private

Calls superclass method
# File lib/rubillow/models/deep_search_result.rb, line 29
def parse
  super
  
  return if !success?
  
  extract_property_basics(@parser)
  @fips_county = xpath_if_present('//FIPScounty', :text, @parser, "")
  @tax_assessment_year = xpath_if_present('//taxAssessmentYear', :text, @parser)
  @tax_assessment = xpath_if_present('//taxAssessment', :text, @parser)
  @year_built = xpath_if_present('//yearBuilt', :text, @parser)
  if tmp = xpath_if_present('//lastSoldDate', :text, @parser) and tmp.strip.length > 0
    @last_sold_date = Date.strptime(tmp, "%m/%d/%Y")
  end
  @last_sold_price = xpath_if_present('//lastSoldPrice', :text, @parser)
end