Class: RETS4R::Client::Transaction

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Defined in:
lib/rets4r/client/transaction.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(doc = nil) ⇒ Transaction

Returns a new instance of Transaction.


11
12
13
14
15
# File 'lib/rets4r/client/transaction.rb', line 11

def initialize(doc = nil)
  self.doc = doc || ResponseDocument::Base.new
  self.header = []
  self.delimiter = ?\t
end

Instance Attribute Details

#delimiterObject

Returns the value of attribute delimiter


8
9
10
# File 'lib/rets4r/client/transaction.rb', line 8

def delimiter
  @delimiter
end

#docObject

Returns the value of attribute doc


8
9
10
# File 'lib/rets4r/client/transaction.rb', line 8

def doc
  @doc
end

#headerObject

Returns the value of attribute header


8
9
10
# File 'lib/rets4r/client/transaction.rb', line 8

def header
  @header
end

#metadataObject

Returns the value of attribute metadata


8
9
10
# File 'lib/rets4r/client/transaction.rb', line 8

def 
  @metadata
end

#responseObject

Returns the value of attribute response


8
9
10
# File 'lib/rets4r/client/transaction.rb', line 8

def response
  @response
end

#secondary_responseObject

Returns the value of attribute secondary_response


8
9
10
# File 'lib/rets4r/client/transaction.rb', line 8

def secondary_response
  @secondary_response
end

Instance Method Details

#ascii_delimiterObject


26
27
28
# File 'lib/rets4r/client/transaction.rb', line 26

def ascii_delimiter
  self.delimiter.chr
end

#reply_codeObject


19
20
21
22
23
24
# File 'lib/rets4r/client/transaction.rb', line 19

def reply_code
  if $VERBOSE
    warn("#{caller.first}: warning: as of rets4r 2.0 #{self.class}#reply_code will be a numeric")
  end
  doc.reply_code.to_s
end