Class: ThePlaidApi::SandboxTransferTestClockListRequest
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- ThePlaidApi::SandboxTransferTestClockListRequest
- Defined in:
- lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb
Overview
Defines the request schema for ‘/sandbox/transfer/test_clock/list`
Instance Attribute Summary collapse
-
#client_id ⇒ String
Your Plaid API ‘client_id`.
-
#count ⇒ Integer
The maximum number of test clocks to return.
-
#end_virtual_time ⇒ DateTime
The end virtual timestamp of test clocks to return.
-
#offset ⇒ Integer
The number of test clocks to skip before returning results.
-
#secret ⇒ String
Your Plaid API ‘secret`.
-
#start_virtual_time ⇒ DateTime
The start virtual timestamp of test clocks to return.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(client_id: SKIP, secret: SKIP, start_virtual_time: SKIP, end_virtual_time: SKIP, count: 25, offset: 0, additional_properties: nil) ⇒ SandboxTransferTestClockListRequest
constructor
A new instance of SandboxTransferTestClockListRequest.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
- #to_custom_end_virtual_time ⇒ Object
- #to_custom_start_virtual_time ⇒ Object
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(client_id: SKIP, secret: SKIP, start_virtual_time: SKIP, end_virtual_time: SKIP, count: 25, offset: 0, additional_properties: nil) ⇒ SandboxTransferTestClockListRequest
Returns a new instance of SandboxTransferTestClockListRequest.
75 76 77 78 79 80 81 82 83 84 85 86 87 88 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 75 def initialize(client_id: SKIP, secret: SKIP, start_virtual_time: SKIP, end_virtual_time: SKIP, count: 25, offset: 0, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @client_id = client_id unless client_id == SKIP @secret = secret unless secret == SKIP @start_virtual_time = start_virtual_time unless start_virtual_time == SKIP @end_virtual_time = end_virtual_time unless end_virtual_time == SKIP @count = count unless count == SKIP @offset = offset unless offset == SKIP @additional_properties = additional_properties end |
Instance Attribute Details
#client_id ⇒ String
Your Plaid API ‘client_id`. The `client_id` is required and may be provided either in the `PLAID-CLIENT-ID` header or as part of a request body.
17 18 19 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 17 def client_id @client_id end |
#count ⇒ Integer
The maximum number of test clocks to return.
36 37 38 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 36 def count @count end |
#end_virtual_time ⇒ DateTime
The end virtual timestamp of test clocks to return. This should be in RFC 3339 format (i.e. ‘2019-12-06T22:35:49Z`)
32 33 34 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 32 def end_virtual_time @end_virtual_time end |
#offset ⇒ Integer
The number of test clocks to skip before returning results.
40 41 42 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 40 def offset @offset end |
#secret ⇒ String
Your Plaid API ‘secret`. The `secret` is required and may be provided either in the `PLAID-SECRET` header or as part of a request body.
22 23 24 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 22 def secret @secret end |
#start_virtual_time ⇒ DateTime
The start virtual timestamp of test clocks to return. This should be in RFC 3339 format (i.e. ‘2019-12-06T22:35:49Z`)
27 28 29 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 27 def start_virtual_time @start_virtual_time end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 91 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. client_id = hash.key?('client_id') ? hash['client_id'] : SKIP secret = hash.key?('secret') ? hash['secret'] : SKIP start_virtual_time = if hash.key?('start_virtual_time') (DateTimeHelper.from_rfc3339(hash['start_virtual_time']) if hash['start_virtual_time']) else SKIP end end_virtual_time = if hash.key?('end_virtual_time') (DateTimeHelper.from_rfc3339(hash['end_virtual_time']) if hash['end_virtual_time']) else SKIP end count = hash['count'] ||= 25 offset = hash['offset'] ||= 0 # Create a new hash for additional properties, removing known properties. new_hash = hash.reject { |k, _| names.value?(k) } additional_properties = APIHelper.get_additional_properties( new_hash, proc { |value| value } ) # Create object from extracted values. SandboxTransferTestClockListRequest.new(client_id: client_id, secret: secret, start_virtual_time: start_virtual_time, end_virtual_time: end_virtual_time, count: count, offset: offset, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
43 44 45 46 47 48 49 50 51 52 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 43 def self.names @_hash = {} if @_hash.nil? @_hash['client_id'] = 'client_id' @_hash['secret'] = 'secret' @_hash['start_virtual_time'] = 'start_virtual_time' @_hash['end_virtual_time'] = 'end_virtual_time' @_hash['count'] = 'count' @_hash['offset'] = 'offset' @_hash end |
.nullables ⇒ Object
An array for nullable fields
67 68 69 70 71 72 73 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 67 def self.nullables %w[ start_virtual_time end_virtual_time count ] end |
.optionals ⇒ Object
An array for optional fields
55 56 57 58 59 60 61 62 63 64 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 55 def self.optionals %w[ client_id secret start_virtual_time end_virtual_time count offset ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
144 145 146 147 148 149 150 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 144 def inspect class_name = self.class.name.split('::').last "<#{class_name} client_id: #{@client_id.inspect}, secret: #{@secret.inspect},"\ " start_virtual_time: #{@start_virtual_time.inspect}, end_virtual_time:"\ " #{@end_virtual_time.inspect}, count: #{@count.inspect}, offset: #{@offset.inspect},"\ " additional_properties: #{@additional_properties}>" end |
#to_custom_end_virtual_time ⇒ Object
131 132 133 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 131 def to_custom_end_virtual_time DateTimeHelper.to_rfc3339(end_virtual_time) end |
#to_custom_start_virtual_time ⇒ Object
127 128 129 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 127 def to_custom_start_virtual_time DateTimeHelper.to_rfc3339(start_virtual_time) end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
136 137 138 139 140 141 |
# File 'lib/the_plaid_api/models/sandbox_transfer_test_clock_list_request.rb', line 136 def to_s class_name = self.class.name.split('::').last "<#{class_name} client_id: #{@client_id}, secret: #{@secret}, start_virtual_time:"\ " #{@start_virtual_time}, end_virtual_time: #{@end_virtual_time}, count: #{@count}, offset:"\ " #{@offset}, additional_properties: #{@additional_properties}>" end |