Class: ShellCardManagementApIs::UpdateBundleResponse
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- ShellCardManagementApIs::UpdateBundleResponse
- Defined in:
- lib/shell_card_management_ap_is/models/update_bundle_response.rb
Overview
UpdateBundleResponse Model.
Instance Attribute Summary collapse
-
#day_time_restriction_status ⇒ ErrorStatus
Request Id of the API call.
-
#error ⇒ ErrorStatus
Request Id of the API call.
-
#location_restriction_status ⇒ ErrorStatus
Request Id of the API call.
-
#product_restriction_status ⇒ ErrorStatus
Request Id of the API call.
-
#request_action_status ⇒ ErrorStatus
Request Id of the API call.
-
#request_id ⇒ String
Request Id of the API call.
-
#usage_restriction_status ⇒ ErrorStatus
Request Id of the API call.
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(request_id = SKIP, request_action_status = SKIP, day_time_restriction_status = SKIP, location_restriction_status = SKIP, product_restriction_status = SKIP, usage_restriction_status = SKIP, error = SKIP) ⇒ UpdateBundleResponse
constructor
A new instance of UpdateBundleResponse.
Methods inherited from BaseModel
Constructor Details
#initialize(request_id = SKIP, request_action_status = SKIP, day_time_restriction_status = SKIP, location_restriction_status = SKIP, product_restriction_status = SKIP, usage_restriction_status = SKIP, error = SKIP) ⇒ UpdateBundleResponse
Returns a new instance of UpdateBundleResponse.
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 73 def initialize(request_id = SKIP, request_action_status = SKIP, day_time_restriction_status = SKIP, location_restriction_status = SKIP, product_restriction_status = SKIP, usage_restriction_status = SKIP, error = SKIP) @request_id = request_id unless request_id == SKIP @request_action_status = request_action_status unless request_action_status == SKIP unless day_time_restriction_status == SKIP @day_time_restriction_status = day_time_restriction_status end unless location_restriction_status == SKIP @location_restriction_status = location_restriction_status end unless product_restriction_status == SKIP @product_restriction_status = product_restriction_status end @usage_restriction_status = usage_restriction_status unless usage_restriction_status == SKIP @error = error unless error == SKIP end |
Instance Attribute Details
#day_time_restriction_status ⇒ ErrorStatus
Request Id of the API call
22 23 24 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 22 def day_time_restriction_status @day_time_restriction_status end |
#error ⇒ ErrorStatus
Request Id of the API call
38 39 40 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 38 def error @error end |
#location_restriction_status ⇒ ErrorStatus
Request Id of the API call
26 27 28 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 26 def location_restriction_status @location_restriction_status end |
#product_restriction_status ⇒ ErrorStatus
Request Id of the API call
30 31 32 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 30 def product_restriction_status @product_restriction_status end |
#request_action_status ⇒ ErrorStatus
Request Id of the API call
18 19 20 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 18 def request_action_status @request_action_status end |
#request_id ⇒ String
Request Id of the API call
14 15 16 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 14 def request_id @request_id end |
#usage_restriction_status ⇒ ErrorStatus
Request Id of the API call
34 35 36 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 34 def usage_restriction_status @usage_restriction_status end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
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 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 97 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. request_id = hash.key?('RequestId') ? hash['RequestId'] : SKIP request_action_status = ErrorStatus.from_hash(hash['RequestActionStatus']) if hash['RequestActionStatus'] day_time_restriction_status = ErrorStatus.from_hash(hash['DayTimeRestrictionStatus']) if hash['DayTimeRestrictionStatus'] location_restriction_status = ErrorStatus.from_hash(hash['LocationRestrictionStatus']) if hash['LocationRestrictionStatus'] product_restriction_status = ErrorStatus.from_hash(hash['ProductRestrictionStatus']) if hash['ProductRestrictionStatus'] usage_restriction_status = ErrorStatus.from_hash(hash['UsageRestrictionStatus']) if hash['UsageRestrictionStatus'] error = ErrorStatus.from_hash(hash['Error']) if hash['Error'] # Create object from extracted values. UpdateBundleResponse.new(request_id, request_action_status, day_time_restriction_status, location_restriction_status, product_restriction_status, usage_restriction_status, error) end |
.names ⇒ Object
A mapping from model property names to API property names.
41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 41 def self.names @_hash = {} if @_hash.nil? @_hash['request_id'] = 'RequestId' @_hash['request_action_status'] = 'RequestActionStatus' @_hash['day_time_restriction_status'] = 'DayTimeRestrictionStatus' @_hash['location_restriction_status'] = 'LocationRestrictionStatus' @_hash['product_restriction_status'] = 'ProductRestrictionStatus' @_hash['usage_restriction_status'] = 'UsageRestrictionStatus' @_hash['error'] = 'Error' @_hash end |
.nullables ⇒ Object
An array for nullable fields
67 68 69 70 71 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 67 def self.nullables %w[ request_id ] end |
.optionals ⇒ Object
An array for optional fields
54 55 56 57 58 59 60 61 62 63 64 |
# File 'lib/shell_card_management_ap_is/models/update_bundle_response.rb', line 54 def self.optionals %w[ request_id request_action_status day_time_restriction_status location_restriction_status product_restriction_status usage_restriction_status error ] end |