Class: CzechPostB2bClient::RequestBuilders::GetStatsBuilder

Inherits:
BaseBuilder show all
Defined in:
lib/czech_post_b2b_client/request_builders/get_stats_builder.rb

Constant Summary

Constants inherited from BaseBuilder

BaseBuilder::TIME_FORMAT

Instance Attribute Summary collapse

Attributes inherited from BaseBuilder

#request_id

Attributes inherited from SteppedService::Base

#result

Instance Method Summary collapse

Methods inherited from BaseBuilder

#steps

Methods inherited from SteppedService::Base

call, #call, #errors, #failure?, #finished?, #steps, #success?

Constructor Details

#initialize(from_date:, to_date:, request_id: 1) ⇒ GetStatsBuilder

Returns a new instance of GetStatsBuilder



8
9
10
11
12
# File 'lib/czech_post_b2b_client/request_builders/get_stats_builder.rb', line 8

def initialize(from_date:, to_date:, request_id: 1)
  @from_date = from_date.to_time
  @to_date = to_date.to_time
  @request_id = request_id
end

Instance Attribute Details

#from_dateObject (readonly)

Returns the value of attribute from_date



6
7
8
# File 'lib/czech_post_b2b_client/request_builders/get_stats_builder.rb', line 6

def from_date
  @from_date
end

#to_dateObject (readonly)

Returns the value of attribute to_date



6
7
8
# File 'lib/czech_post_b2b_client/request_builders/get_stats_builder.rb', line 6

def to_date
  @to_date
end