Class: RETS4R::Client::Transaction

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeTransaction

Returns a new instance of Transaction.



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

def initialize
  self.maxrows = false
  self.header = []
  self.delimiter = ?\t
end

Instance Attribute Details

#delimiterObject

Returns the value of attribute delimiter.



4
5
6
# File 'lib/rets4r/client/transaction.rb', line 4

def delimiter
  @delimiter
end

#headerObject

Returns the value of attribute header.



4
5
6
# File 'lib/rets4r/client/transaction.rb', line 4

def header
  @header
end

#maxrowsObject

Returns the value of attribute maxrows.



4
5
6
# File 'lib/rets4r/client/transaction.rb', line 4

def maxrows
  @maxrows
end

#metadataObject

Returns the value of attribute metadata.



4
5
6
# File 'lib/rets4r/client/transaction.rb', line 4

def 
  @metadata
end

#reply_codeObject

Returns the value of attribute reply_code.



4
5
6
# File 'lib/rets4r/client/transaction.rb', line 4

def reply_code
  @reply_code
end

#reply_textObject

Returns the value of attribute reply_text.



4
5
6
# File 'lib/rets4r/client/transaction.rb', line 4

def reply_text
  @reply_text
end

#responseObject Also known as: data

Returns the value of attribute response.



4
5
6
# File 'lib/rets4r/client/transaction.rb', line 4

def response
  @response
end

#secondary_responseObject

Returns the value of attribute secondary_response.



4
5
6
# File 'lib/rets4r/client/transaction.rb', line 4

def secondary_response
  @secondary_response
end

Instance Method Details

#ascii_delimiterObject



23
24
25
# File 'lib/rets4r/client/transaction.rb', line 23

def ascii_delimiter
  self.delimiter.chr
end

#maxrows?Boolean

Returns:

  • (Boolean)


18
19
20
21
# File 'lib/rets4r/client/transaction.rb', line 18

def maxrows?
  return true if self.maxrows
  return false
end

#success?Boolean

Returns:

  • (Boolean)


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

def success?
  return true if self.reply_code == '0'
  return false
end