Class: Foxtrot::Response::PendingResponse

Inherits:
Response
  • Object
show all
Defined in:
lib/foxtrot/response.rb

Instance Method Summary collapse

Methods inherited from Response

#poll_and_block!, response_for

Constructor Details

#initialize(endpoint, resp, api_instance) ⇒ PendingResponse

Returns a new instance of PendingResponse.



64
65
66
67
# File 'lib/foxtrot/response.rb', line 64

def initialize(endpoint, resp, api_instance)
  super
  @txid = resp['txid']
end

Instance Method Details

#complete?Boolean

Returns:

  • (Boolean)


69
70
71
# File 'lib/foxtrot/response.rb', line 69

def complete?
  false
end

#get_resultObject



77
78
79
# File 'lib/foxtrot/response.rb', line 77

def get_result
  nil
end

#poll!Object



73
74
75
# File 'lib/foxtrot/response.rb', line 73

def poll!
  @api_instance.poll! @endpoint, @txid
end

#to_sObject



81
82
83
# File 'lib/foxtrot/response.rb', line 81

def to_s
  "PendingResponse (#{@txid})"
end