card-management-sdk 1.0.0 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +27 -19
- data/lib/shell_card_management_ap_is/client.rb +2 -3
- data/lib/shell_card_management_ap_is/configuration.rb +15 -22
- data/lib/shell_card_management_ap_is/controllers/base_controller.rb +9 -9
- data/lib/shell_card_management_ap_is/controllers/card_controller.rb +434 -434
- data/lib/shell_card_management_ap_is/controllers/customer_controller.rb +261 -262
- data/lib/shell_card_management_ap_is/controllers/o_auth_authorization_controller.rb +11 -11
- data/lib/shell_card_management_ap_is/controllers/restriction_controller.rb +421 -291
- data/lib/shell_card_management_ap_is/exceptions/error_object_exception.rb +15 -15
- data/lib/shell_card_management_ap_is/exceptions/{error_user_access_error1_exception.rb → fleetmanagement_v1_customer_customer403_error_exception.rb} +17 -17
- data/lib/shell_card_management_ap_is/exceptions/{default_error_exception.rb → fleetmanagement_v1_customer_payers400_error_exception.rb} +20 -20
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_customer_payers404_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_user_loggedinuser400_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_user_loggedinuser401_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_user_loggedinuser403_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_user_loggedinuser404_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_user_loggedinuser500_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v2_restriction_searchcard401_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v2_restriction_searchcard500_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/o_auth_provider_exception.rb +15 -15
- data/lib/shell_card_management_ap_is/http/auth/bearer_token.rb +54 -10
- data/lib/shell_card_management_ap_is/models/account_access.rb +3 -8
- data/lib/shell_card_management_ap_is/models/account_request.rb +17 -26
- data/lib/shell_card_management_ap_is/models/account_response.rb +2 -6
- data/lib/shell_card_management_ap_is/models/account_response_accounts_items.rb +29 -53
- data/lib/shell_card_management_ap_is/models/account_restriction_request.rb +28 -10
- data/lib/shell_card_management_ap_is/models/account_restriction_response.rb +60 -11
- data/lib/shell_card_management_ap_is/models/account_velocity_limit.rb +11 -19
- data/lib/shell_card_management_ap_is/models/accounts.rb +1 -2
- data/lib/shell_card_management_ap_is/models/address.rb +4 -11
- data/lib/shell_card_management_ap_is/models/audit_request.rb +37 -33
- data/lib/shell_card_management_ap_is/models/audit_response.rb +2 -6
- data/lib/shell_card_management_ap_is/models/audit_response_audits_items.rb +50 -63
- data/lib/shell_card_management_ap_is/models/auto_renew_card_request.rb +2 -5
- data/lib/shell_card_management_ap_is/models/auto_renew_card_request_auto_renew_cards_items.rb +13 -5
- data/lib/shell_card_management_ap_is/models/auto_renew_card_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/auto_renew_card_response_data_items.rb +13 -3
- data/lib/shell_card_management_ap_is/models/bank_account.rb +5 -13
- data/lib/shell_card_management_ap_is/models/{search_account_limit_request_filters.rb → budle_details_request.rb} +29 -22
- data/lib/shell_card_management_ap_is/models/{create_bundle_response_data_items_cards_items.rb → bundle_card_restriction_status.rb} +4 -3
- data/lib/shell_card_management_ap_is/models/bundle_details_response.rb +181 -0
- data/lib/shell_card_management_ap_is/models/bundle_restriction.rb +86 -103
- data/lib/shell_card_management_ap_is/models/bundle_restriction_update.rb +185 -0
- data/lib/shell_card_management_ap_is/models/bundled_details_product_list.rb +116 -0
- data/lib/shell_card_management_ap_is/models/bundled_restrictions_list.rb +82 -0
- data/lib/shell_card_management_ap_is/models/cancel_card_request.rb +1 -3
- data/lib/shell_card_management_ap_is/models/cancel_card_response.rb +3 -6
- data/lib/shell_card_management_ap_is/models/card.rb +43 -51
- data/lib/shell_card_management_ap_is/models/card_block_schedule.rb +1 -2
- data/lib/shell_card_management_ap_is/models/{summary_of_bundle_response_data_items_card_bundles_items.rb → card_bundle.rb} +11 -18
- data/lib/shell_card_management_ap_is/models/card_contact.rb +222 -0
- data/lib/shell_card_management_ap_is/models/card_day_time_restrictions.rb +3 -9
- data/lib/shell_card_management_ap_is/models/card_delivery_address.rb +218 -0
- data/lib/shell_card_management_ap_is/models/card_delivery_contact.rb +7 -14
- data/lib/shell_card_management_ap_is/models/card_detail.rb +50 -61
- data/lib/shell_card_management_ap_is/models/card_details_request.rb +6 -14
- data/lib/shell_card_management_ap_is/models/card_details_response.rb +52 -89
- data/lib/shell_card_management_ap_is/models/card_details_response_card_block_schedules_items_all_of0.rb +1 -2
- data/lib/shell_card_management_ap_is/models/card_details_response_card_delivery_address.rb +6 -15
- data/lib/shell_card_management_ap_is/models/card_details_response_fuel_sets_items.rb +1 -2
- data/lib/shell_card_management_ap_is/models/card_details_response_non_fuel_sets_items.rb +1 -2
- data/lib/shell_card_management_ap_is/models/card_details_response_pin_delivery_address.rb +6 -15
- data/lib/shell_card_management_ap_is/models/card_group_request.rb +6 -12
- data/lib/shell_card_management_ap_is/models/card_group_response.rb +2 -6
- data/lib/shell_card_management_ap_is/models/card_group_response_card_groups_items.rb +10 -20
- data/lib/shell_card_management_ap_is/models/card_management_v1_cancel_request.rb +104 -0
- data/lib/shell_card_management_ap_is/models/card_management_v1_ordercard_request.rb +59 -0
- data/lib/shell_card_management_ap_is/models/card_management_v1_pinreminder_request.rb +130 -0
- data/lib/shell_card_management_ap_is/models/card_management_v1_updatestatus_request.rb +122 -0
- data/lib/shell_card_management_ap_is/models/card_move_request.rb +4 -9
- data/lib/shell_card_management_ap_is/models/card_move_request_cards_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/card_move_response.rb +2 -4
- data/lib/shell_card_management_ap_is/models/card_move_response_error_cards_items.rb +2 -5
- data/lib/shell_card_management_ap_is/models/card_move_response_successful_requests_items.rb +2 -5
- data/lib/shell_card_management_ap_is/models/{restriction_card_request.rb → card_restriction_req.rb} +42 -50
- data/lib/shell_card_management_ap_is/models/card_restriction_response.rb +96 -0
- data/lib/shell_card_management_ap_is/models/card_search_response.rb +2 -7
- data/lib/shell_card_management_ap_is/models/card_settings.rb +626 -0
- data/lib/shell_card_management_ap_is/models/card_summary_request.rb +3 -5
- data/lib/shell_card_management_ap_is/models/card_summary_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/card_type_request.rb +3 -7
- data/lib/shell_card_management_ap_is/models/card_type_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/card_type_response_customer_card_types_items.rb +15 -31
- data/lib/shell_card_management_ap_is/models/card_type_response_error.rb +1 -2
- data/lib/shell_card_management_ap_is/models/card_usage_restrictions.rb +5 -10
- data/lib/shell_card_management_ap_is/models/col_co_access.rb +2 -4
- data/lib/shell_card_management_ap_is/models/{location_restrictions_country_restrictions.rb → country_restriction.rb} +20 -21
- data/lib/shell_card_management_ap_is/models/create_bundle_request.rb +64 -62
- data/lib/shell_card_management_ap_is/models/create_bundle_response.rb +122 -47
- data/lib/shell_card_management_ap_is/models/create_card_group_request.rb +3 -9
- data/lib/shell_card_management_ap_is/models/create_card_group_request_cards_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/create_card_group_response.rb +2 -5
- data/lib/shell_card_management_ap_is/models/create_card_group_response_error_cards_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/create_card_group_response_successful_requests_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/create_card_response.rb +1 -2
- data/lib/shell_card_management_ap_is/models/customer_contract.rb +1 -2
- data/lib/shell_card_management_ap_is/models/customer_detail_request.rb +2 -5
- data/lib/shell_card_management_ap_is/models/customer_detail_response.rb +31 -45
- data/lib/shell_card_management_ap_is/models/day_time_restriction.rb +133 -0
- data/lib/shell_card_management_ap_is/models/day_time_restrictions.rb +52 -82
- data/lib/shell_card_management_ap_is/models/{summary_of_bundle_request.rb → default_error.rb} +10 -10
- data/lib/shell_card_management_ap_is/models/default_error_fault.rb +4 -5
- data/lib/shell_card_management_ap_is/models/delete_bundle_request.rb +14 -16
- data/lib/shell_card_management_ap_is/models/delete_bundle_response.rb +9 -10
- data/lib/shell_card_management_ap_is/models/delivery_address_update.rb +13 -11
- data/lib/shell_card_management_ap_is/models/delivery_address_update_references.rb +2 -5
- data/lib/shell_card_management_ap_is/models/delivery_address_update_references2.rb +98 -0
- data/lib/shell_card_management_ap_is/models/delivery_address_update_request.rb +3 -7
- data/lib/shell_card_management_ap_is/models/delivery_address_update_response.rb +5 -14
- data/lib/shell_card_management_ap_is/models/delivery_addresses.rb +7 -18
- data/lib/shell_card_management_ap_is/models/detail.rb +50 -0
- data/lib/shell_card_management_ap_is/models/eid_access.rb +1 -2
- data/lib/shell_card_management_ap_is/models/error_details.rb +1 -3
- data/lib/shell_card_management_ap_is/models/error_status.rb +1 -2
- data/lib/shell_card_management_ap_is/models/error_user_access_error.rb +1 -2
- data/lib/shell_card_management_ap_is/models/fault.rb +59 -0
- data/lib/shell_card_management_ap_is/models/filters.rb +702 -0
- data/lib/shell_card_management_ap_is/models/filters1.rb +579 -0
- data/lib/shell_card_management_ap_is/models/filters2.rb +200 -0
- data/lib/shell_card_management_ap_is/models/finance_currency.rb +1 -2
- data/lib/shell_card_management_ap_is/models/finance_currency2.rb +96 -0
- data/lib/shell_card_management_ap_is/models/{restriction_search_card_request.rb → fleetmanagement_v1_customer_payers400_error1.rb} +10 -10
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_customer_payers404_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_user_loggedinuser400_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_user_loggedinuser401_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_user_loggedinuser404_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_user_loggedinuser500_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_user_loggedinuser_request.rb +104 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v2_restriction_searchcard401_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v2_restriction_searchcard500_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/generate_pin_key_response.rb +1 -2
- data/lib/shell_card_management_ap_is/models/invoice_distribution_method.rb +2 -4
- data/lib/shell_card_management_ap_is/models/{location_restrictions.rb → location_restriction.rb} +20 -35
- data/lib/shell_card_management_ap_is/models/logged_in_user_request.rb +2 -4
- data/lib/shell_card_management_ap_is/models/logged_in_user_response.rb +12 -25
- data/lib/shell_card_management_ap_is/models/{location_restrictions_network_restrictions_items.rb → network_restriction.rb} +18 -20
- data/lib/shell_card_management_ap_is/models/o_auth_token.rb +2 -6
- data/lib/shell_card_management_ap_is/models/order_card_enquiry.rb +48 -45
- data/lib/shell_card_management_ap_is/models/order_card_enquiry_req.rb +5 -12
- data/lib/shell_card_management_ap_is/models/order_card_enquiry_request.rb +3 -4
- data/lib/shell_card_management_ap_is/models/order_card_enquiry_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/order_card_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/{location_restrictions_partner_site_restrictions_items.rb → partner_site_restriction.rb} +10 -12
- data/lib/shell_card_management_ap_is/models/payer_access.rb +3 -8
- data/lib/shell_card_management_ap_is/models/payer_details.rb +55 -96
- data/lib/shell_card_management_ap_is/models/payer_request.rb +9 -12
- data/lib/shell_card_management_ap_is/models/payer_response.rb +2 -6
- data/lib/shell_card_management_ap_is/models/payers.rb +2 -5
- data/lib/shell_card_management_ap_is/models/pin_advice_types.rb +5 -6
- data/lib/shell_card_management_ap_is/models/pin_contact.rb +234 -0
- data/lib/shell_card_management_ap_is/models/pin_deliver_to.rb +161 -0
- data/lib/shell_card_management_ap_is/models/pin_delivery_address.rb +222 -0
- data/lib/shell_card_management_ap_is/models/pin_delivery_contact.rb +7 -14
- data/lib/shell_card_management_ap_is/models/pin_delivery_details.rb +4 -11
- data/lib/shell_card_management_ap_is/models/pin_reminder_card_details.rb +19 -17
- data/lib/shell_card_management_ap_is/models/pin_reminder_reference.rb +2 -5
- data/lib/shell_card_management_ap_is/models/pin_reminder_request.rb +2 -6
- data/lib/shell_card_management_ap_is/models/pin_reminder_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/product_all_of0.rb +1 -2
- data/lib/shell_card_management_ap_is/models/product_group.rb +2 -6
- data/lib/shell_card_management_ap_is/models/{product_restrictions.rb → product_restriction_card.rb} +9 -12
- data/lib/shell_card_management_ap_is/models/purchase_categories.rb +1 -4
- data/lib/shell_card_management_ap_is/models/purchase_category1_all_of0.rb +10 -15
- data/lib/shell_card_management_ap_is/models/purchase_category_request.rb +2 -5
- data/lib/shell_card_management_ap_is/models/purchase_category_response.rb +1 -2
- data/lib/shell_card_management_ap_is/models/replace_card_settings.rb +25 -40
- data/lib/shell_card_management_ap_is/models/restriction.rb +82 -0
- data/lib/shell_card_management_ap_is/models/{restriction_search_card_response_data_items.rb → restriction_card_list.rb} +284 -328
- data/lib/shell_card_management_ap_is/models/{restriction_card_request_cards_items.rb → restriction_cards_list.rb} +69 -82
- data/lib/shell_card_management_ap_is/models/restriction_product.rb +62 -0
- data/lib/shell_card_management_ap_is/models/{restriction_card_response_data_items.rb → restrictioncards_res.rb} +100 -114
- data/lib/shell_card_management_ap_is/models/role.rb +3 -6
- data/lib/shell_card_management_ap_is/models/schedule_card_block_cards_items.rb +42 -39
- data/lib/shell_card_management_ap_is/models/schedule_card_block_request.rb +1 -2
- data/lib/shell_card_management_ap_is/models/schedule_card_block_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/schedule_card_block_response_data_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/search_account_limit_request.rb +79 -10
- data/lib/shell_card_management_ap_is/models/search_account_limit_response.rb +74 -20
- data/lib/shell_card_management_ap_is/models/search_card.rb +13 -3
- data/lib/shell_card_management_ap_is/models/search_card_request.rb +4 -6
- data/lib/shell_card_management_ap_is/models/{restriction_search_card_request_filters_cards_items.rb → search_card_restriction.rb} +19 -16
- data/lib/shell_card_management_ap_is/models/{restriction_search_card_request_filters.rb → search_card_restriction_req.rb} +72 -71
- data/lib/shell_card_management_ap_is/models/search_card_restriction_res.rb +89 -0
- data/lib/shell_card_management_ap_is/models/search_product_restriction.rb +3 -4
- data/lib/shell_card_management_ap_is/models/search_request.rb +25 -47
- data/lib/shell_card_management_ap_is/models/{location_restrictions_shell_site_restrictions_items.rb → shell_site_restriction.rb} +10 -17
- data/lib/shell_card_management_ap_is/models/submitted_card.rb +24 -9
- data/lib/shell_card_management_ap_is/models/summary_request.rb +21 -39
- data/lib/shell_card_management_ap_is/models/summary_response.rb +5 -11
- data/lib/shell_card_management_ap_is/models/{summary_of_bundle_response_data_items.rb → summaryofbundle_response.rb} +36 -33
- data/lib/shell_card_management_ap_is/models/{summaryof_bundle.rb → summaryofbundler_request.rb} +43 -36
- data/lib/shell_card_management_ap_is/models/update_bundle_request.rb +65 -70
- data/lib/shell_card_management_ap_is/models/update_bundle_response.rb +75 -21
- data/lib/shell_card_management_ap_is/models/update_card.rb +31 -20
- data/lib/shell_card_management_ap_is/models/update_card_group_request.rb +9 -17
- data/lib/shell_card_management_ap_is/models/update_card_group_response.rb +3 -6
- data/lib/shell_card_management_ap_is/models/update_card_group_response_move_card_references_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/update_card_renewal_address.rb +5 -11
- data/lib/shell_card_management_ap_is/models/update_card_renewal_address2.rb +155 -0
- data/lib/shell_card_management_ap_is/models/update_card_status_request.rb +1 -3
- data/lib/shell_card_management_ap_is/models/update_card_status_response.rb +2 -5
- data/lib/shell_card_management_ap_is/models/update_m_pay_reg_status_request.rb +2 -5
- data/lib/shell_card_management_ap_is/models/update_m_pay_reg_status_request_m_pay_requests_items.rb +3 -5
- data/lib/shell_card_management_ap_is/models/update_m_pay_reg_status_response.rb +1 -2
- data/lib/shell_card_management_ap_is/models/usage_restriction.rb +1127 -0
- data/lib/shell_card_management_ap_is/models/{usage_restrictions.rb → usage_restrictions_card.rb} +74 -131
- data/lib/shell_card_management_ap_is/utilities/file_wrapper.rb +9 -9
- data/lib/shell_card_management_ap_is.rb +139 -95
- metadata +74 -38
- data/lib/shell_card_management_ap_is/models/create_bundle_request_restrictions.rb +0 -147
- data/lib/shell_card_management_ap_is/models/create_bundle_response_data_items.rb +0 -125
- data/lib/shell_card_management_ap_is/models/restriction_card_response.rb +0 -91
- data/lib/shell_card_management_ap_is/models/restriction_search_card_response.rb +0 -79
- data/lib/shell_card_management_ap_is/models/search_account_limit_response_data.rb +0 -106
- data/lib/shell_card_management_ap_is/models/search_card_response_restrictions.rb +0 -99
- data/lib/shell_card_management_ap_is/models/summary_of_bundle_response.rb +0 -79
- data/lib/shell_card_management_ap_is/models/url_enum.rb +0 -23
@@ -1,147 +0,0 @@
|
|
1
|
-
# shell_card_management_ap_is
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v2.0
|
4
|
-
# ( https://apimatic.io ).
|
5
|
-
|
6
|
-
module ShellCardManagementApIs
|
7
|
-
# Restrictions to be applied on the bundle. Mandatory
|
8
|
-
class CreateBundleRequestRestrictions < BaseModel
|
9
|
-
SKIP = Object.new
|
10
|
-
private_constant :SKIP
|
11
|
-
|
12
|
-
# Usage restrictions such as value, volume and transaction count restricted
|
13
|
-
# per day, week, month, annum, lifetime and transaction to be applied on the
|
14
|
-
# bundle.
|
15
|
-
# Mandatory
|
16
|
-
# @return [String]
|
17
|
-
attr_accessor :usage_restriction_action
|
18
|
-
|
19
|
-
# The value indicates what actions to be performed with respect to day time
|
20
|
-
# restriction.
|
21
|
-
# Mandatory
|
22
|
-
# Allowed values –
|
23
|
-
# • Add: Apply the given restriction on the bundle.
|
24
|
-
# • Default: No Day/Time restriction will be applied on the bundle in
|
25
|
-
# Gateway.
|
26
|
-
# @return [String]
|
27
|
-
attr_accessor :day_time_restriction_action
|
28
|
-
|
29
|
-
# The value indicates what actions to be performed with respect to location
|
30
|
-
# restriction.
|
31
|
-
# Mandatory
|
32
|
-
# Allowed values –
|
33
|
-
# • Add: Apply the given restriction on the bundle.
|
34
|
-
# • Default: No location restriction will be applied on the bundle in
|
35
|
-
# Gateway.
|
36
|
-
# @return [String]
|
37
|
-
attr_accessor :location_restriction_action
|
38
|
-
|
39
|
-
# Day/time restrictions such as weekdays and time range to be applied on the
|
40
|
-
# bundle.
|
41
|
-
# Mandatory if respective action is set as “Add”.
|
42
|
-
# The details of DayTimeRestriction entity is given below.
|
43
|
-
# @return [DayTimeRestrictions]
|
44
|
-
attr_accessor :day_time_restrictions
|
45
|
-
|
46
|
-
# Location restrictions to be applied on the bundle which either allows or
|
47
|
-
# restricts using the cards, which are under the bundle, in the specified
|
48
|
-
# locations.
|
49
|
-
# Mandatory if respective action is set as “Add”.
|
50
|
-
# Details of location restrictions are given below.
|
51
|
-
# @return [LocationRestrictions]
|
52
|
-
attr_accessor :location_restrictions
|
53
|
-
|
54
|
-
# Location restrictions to be applied on the bundle which either allows or
|
55
|
-
# restricts using the cards, which are under the bundle, in the specified
|
56
|
-
# locations.
|
57
|
-
# Mandatory if respective action is set as “Add”.
|
58
|
-
# Details of location restrictions are given below.
|
59
|
-
# @return [ProductRestrictions]
|
60
|
-
attr_accessor :product_restrictions
|
61
|
-
|
62
|
-
# Location restrictions to be applied on the bundle which either allows or
|
63
|
-
# restricts using the cards, which are under the bundle, in the specified
|
64
|
-
# locations.
|
65
|
-
# Mandatory if respective action is set as “Add”.
|
66
|
-
# Details of location restrictions are given below.
|
67
|
-
# @return [UsageRestrictions]
|
68
|
-
attr_accessor :usage_restrictions
|
69
|
-
|
70
|
-
# A mapping from model property names to API property names.
|
71
|
-
def self.names
|
72
|
-
@_hash = {} if @_hash.nil?
|
73
|
-
@_hash['usage_restriction_action'] = 'UsageRestrictionAction'
|
74
|
-
@_hash['day_time_restriction_action'] = 'DayTimeRestrictionAction'
|
75
|
-
@_hash['location_restriction_action'] = 'LocationRestrictionAction'
|
76
|
-
@_hash['day_time_restrictions'] = 'DayTimeRestrictions'
|
77
|
-
@_hash['location_restrictions'] = 'LocationRestrictions'
|
78
|
-
@_hash['product_restrictions'] = 'ProductRestrictions'
|
79
|
-
@_hash['usage_restrictions'] = 'UsageRestrictions'
|
80
|
-
@_hash
|
81
|
-
end
|
82
|
-
|
83
|
-
# An array for optional fields
|
84
|
-
def self.optionals
|
85
|
-
%w[
|
86
|
-
day_time_restrictions
|
87
|
-
location_restrictions
|
88
|
-
product_restrictions
|
89
|
-
usage_restrictions
|
90
|
-
]
|
91
|
-
end
|
92
|
-
|
93
|
-
# An array for nullable fields
|
94
|
-
def self.nullables
|
95
|
-
%w[
|
96
|
-
usage_restriction_action
|
97
|
-
day_time_restriction_action
|
98
|
-
]
|
99
|
-
end
|
100
|
-
|
101
|
-
def initialize(usage_restriction_action = nil,
|
102
|
-
day_time_restriction_action = nil,
|
103
|
-
location_restriction_action = nil,
|
104
|
-
day_time_restrictions = SKIP,
|
105
|
-
location_restrictions = SKIP,
|
106
|
-
product_restrictions = SKIP,
|
107
|
-
usage_restrictions = SKIP)
|
108
|
-
@usage_restriction_action = usage_restriction_action
|
109
|
-
@day_time_restriction_action = day_time_restriction_action
|
110
|
-
@location_restriction_action = location_restriction_action
|
111
|
-
@day_time_restrictions = day_time_restrictions unless day_time_restrictions == SKIP
|
112
|
-
@location_restrictions = location_restrictions unless location_restrictions == SKIP
|
113
|
-
@product_restrictions = product_restrictions unless product_restrictions == SKIP
|
114
|
-
@usage_restrictions = usage_restrictions unless usage_restrictions == SKIP
|
115
|
-
end
|
116
|
-
|
117
|
-
# Creates an instance of the object from a hash.
|
118
|
-
def self.from_hash(hash)
|
119
|
-
return nil unless hash
|
120
|
-
|
121
|
-
# Extract variables from the hash.
|
122
|
-
usage_restriction_action =
|
123
|
-
hash.key?('UsageRestrictionAction') ? hash['UsageRestrictionAction'] : nil
|
124
|
-
day_time_restriction_action =
|
125
|
-
hash.key?('DayTimeRestrictionAction') ? hash['DayTimeRestrictionAction'] : nil
|
126
|
-
location_restriction_action =
|
127
|
-
hash.key?('LocationRestrictionAction') ? hash['LocationRestrictionAction'] : nil
|
128
|
-
day_time_restrictions = DayTimeRestrictions.from_hash(hash['DayTimeRestrictions']) if
|
129
|
-
hash['DayTimeRestrictions']
|
130
|
-
location_restrictions = LocationRestrictions.from_hash(hash['LocationRestrictions']) if
|
131
|
-
hash['LocationRestrictions']
|
132
|
-
product_restrictions = ProductRestrictions.from_hash(hash['ProductRestrictions']) if
|
133
|
-
hash['ProductRestrictions']
|
134
|
-
usage_restrictions = UsageRestrictions.from_hash(hash['UsageRestrictions']) if
|
135
|
-
hash['UsageRestrictions']
|
136
|
-
|
137
|
-
# Create object from extracted values.
|
138
|
-
CreateBundleRequestRestrictions.new(usage_restriction_action,
|
139
|
-
day_time_restriction_action,
|
140
|
-
location_restriction_action,
|
141
|
-
day_time_restrictions,
|
142
|
-
location_restrictions,
|
143
|
-
product_restrictions,
|
144
|
-
usage_restrictions)
|
145
|
-
end
|
146
|
-
end
|
147
|
-
end
|
@@ -1,125 +0,0 @@
|
|
1
|
-
# shell_card_management_ap_is
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v2.0
|
4
|
-
# ( https://apimatic.io ).
|
5
|
-
|
6
|
-
module ShellCardManagementApIs
|
7
|
-
# CreateBundleResponseDataItems Model.
|
8
|
-
class CreateBundleResponseDataItems < BaseModel
|
9
|
-
SKIP = Object.new
|
10
|
-
private_constant :SKIP
|
11
|
-
|
12
|
-
# Identifier of the newly created bundle in Gateway.
|
13
|
-
# @return [String]
|
14
|
-
attr_accessor :bundle_id
|
15
|
-
|
16
|
-
# List of product restriction requests validated and submitted successfully
|
17
|
-
# for each card.
|
18
|
-
# @return [Array[CreateBundleResponseDataItemsCardsItems]]
|
19
|
-
attr_accessor :cards
|
20
|
-
|
21
|
-
# Identifier of the day/time restriction profile created for the bundle in
|
22
|
-
# Gateway.
|
23
|
-
# This will be null if respective action is passed as “Default”.
|
24
|
-
# @return [String]
|
25
|
-
attr_accessor :day_time_restriction_profile_id
|
26
|
-
|
27
|
-
# Identifier of the location restriction profile created for the bundle in
|
28
|
-
# Gateway.
|
29
|
-
# This will be null if respective action is passed as “Default”.
|
30
|
-
# @return [String]
|
31
|
-
attr_accessor :location_restriction_profile_id
|
32
|
-
|
33
|
-
# Identifier of the location restriction profile created for the bundle in
|
34
|
-
# Gateway.
|
35
|
-
# This will be null if respective action is passed as “Default”.
|
36
|
-
# @return [String]
|
37
|
-
attr_accessor :product_restriction_profile_id
|
38
|
-
|
39
|
-
# A mapping from model property names to API property names.
|
40
|
-
def self.names
|
41
|
-
@_hash = {} if @_hash.nil?
|
42
|
-
@_hash['bundle_id'] = 'BundleId'
|
43
|
-
@_hash['cards'] = 'Cards'
|
44
|
-
@_hash['day_time_restriction_profile_id'] =
|
45
|
-
'DayTimeRestrictionProfileId'
|
46
|
-
@_hash['location_restriction_profile_id'] =
|
47
|
-
'LocationRestrictionProfileId'
|
48
|
-
@_hash['product_restriction_profile_id'] = 'ProductRestrictionProfileId'
|
49
|
-
@_hash
|
50
|
-
end
|
51
|
-
|
52
|
-
# An array for optional fields
|
53
|
-
def self.optionals
|
54
|
-
%w[
|
55
|
-
bundle_id
|
56
|
-
cards
|
57
|
-
day_time_restriction_profile_id
|
58
|
-
location_restriction_profile_id
|
59
|
-
product_restriction_profile_id
|
60
|
-
]
|
61
|
-
end
|
62
|
-
|
63
|
-
# An array for nullable fields
|
64
|
-
def self.nullables
|
65
|
-
%w[
|
66
|
-
cards
|
67
|
-
day_time_restriction_profile_id
|
68
|
-
location_restriction_profile_id
|
69
|
-
product_restriction_profile_id
|
70
|
-
]
|
71
|
-
end
|
72
|
-
|
73
|
-
def initialize(bundle_id = SKIP,
|
74
|
-
cards = SKIP,
|
75
|
-
day_time_restriction_profile_id = SKIP,
|
76
|
-
location_restriction_profile_id = SKIP,
|
77
|
-
product_restriction_profile_id = SKIP)
|
78
|
-
@bundle_id = bundle_id unless bundle_id == SKIP
|
79
|
-
@cards = cards unless cards == SKIP
|
80
|
-
unless day_time_restriction_profile_id == SKIP
|
81
|
-
@day_time_restriction_profile_id =
|
82
|
-
day_time_restriction_profile_id
|
83
|
-
end
|
84
|
-
unless location_restriction_profile_id == SKIP
|
85
|
-
@location_restriction_profile_id =
|
86
|
-
location_restriction_profile_id
|
87
|
-
end
|
88
|
-
unless product_restriction_profile_id == SKIP
|
89
|
-
@product_restriction_profile_id =
|
90
|
-
product_restriction_profile_id
|
91
|
-
end
|
92
|
-
end
|
93
|
-
|
94
|
-
# Creates an instance of the object from a hash.
|
95
|
-
def self.from_hash(hash)
|
96
|
-
return nil unless hash
|
97
|
-
|
98
|
-
# Extract variables from the hash.
|
99
|
-
bundle_id = hash.key?('BundleId') ? hash['BundleId'] : SKIP
|
100
|
-
# Parameter is an array, so we need to iterate through it
|
101
|
-
cards = nil
|
102
|
-
unless hash['Cards'].nil?
|
103
|
-
cards = []
|
104
|
-
hash['Cards'].each do |structure|
|
105
|
-
cards << (CreateBundleResponseDataItemsCardsItems.from_hash(structure) if structure)
|
106
|
-
end
|
107
|
-
end
|
108
|
-
|
109
|
-
cards = SKIP unless hash.key?('Cards')
|
110
|
-
day_time_restriction_profile_id =
|
111
|
-
hash.key?('DayTimeRestrictionProfileId') ? hash['DayTimeRestrictionProfileId'] : SKIP
|
112
|
-
location_restriction_profile_id =
|
113
|
-
hash.key?('LocationRestrictionProfileId') ? hash['LocationRestrictionProfileId'] : SKIP
|
114
|
-
product_restriction_profile_id =
|
115
|
-
hash.key?('ProductRestrictionProfileId') ? hash['ProductRestrictionProfileId'] : SKIP
|
116
|
-
|
117
|
-
# Create object from extracted values.
|
118
|
-
CreateBundleResponseDataItems.new(bundle_id,
|
119
|
-
cards,
|
120
|
-
day_time_restriction_profile_id,
|
121
|
-
location_restriction_profile_id,
|
122
|
-
product_restriction_profile_id)
|
123
|
-
end
|
124
|
-
end
|
125
|
-
end
|
@@ -1,91 +0,0 @@
|
|
1
|
-
# shell_card_management_ap_is
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v2.0
|
4
|
-
# ( https://apimatic.io ).
|
5
|
-
|
6
|
-
module ShellCardManagementApIs
|
7
|
-
# RestrictionCardResponse Model.
|
8
|
-
class RestrictionCardResponse < BaseModel
|
9
|
-
SKIP = Object.new
|
10
|
-
private_constant :SKIP
|
11
|
-
|
12
|
-
# Main reference number for tracking.
|
13
|
-
# Example: 123455
|
14
|
-
# @return [Integer]
|
15
|
-
attr_accessor :main_reference
|
16
|
-
|
17
|
-
# API Request Id
|
18
|
-
# @return [String]
|
19
|
-
attr_accessor :request_id
|
20
|
-
|
21
|
-
# API Response Status
|
22
|
-
# @return [String]
|
23
|
-
attr_accessor :status
|
24
|
-
|
25
|
-
# List of card restriction requests validated and submitted successfully for
|
26
|
-
# processing.
|
27
|
-
# @return [Array[RestrictionCardResponseDataItems]]
|
28
|
-
attr_accessor :data
|
29
|
-
|
30
|
-
# A mapping from model property names to API property names.
|
31
|
-
def self.names
|
32
|
-
@_hash = {} if @_hash.nil?
|
33
|
-
@_hash['main_reference'] = 'MainReference'
|
34
|
-
@_hash['request_id'] = 'RequestId'
|
35
|
-
@_hash['status'] = 'Status'
|
36
|
-
@_hash['data'] = 'Data'
|
37
|
-
@_hash
|
38
|
-
end
|
39
|
-
|
40
|
-
# An array for optional fields
|
41
|
-
def self.optionals
|
42
|
-
%w[
|
43
|
-
main_reference
|
44
|
-
request_id
|
45
|
-
status
|
46
|
-
data
|
47
|
-
]
|
48
|
-
end
|
49
|
-
|
50
|
-
# An array for nullable fields
|
51
|
-
def self.nullables
|
52
|
-
[]
|
53
|
-
end
|
54
|
-
|
55
|
-
def initialize(main_reference = SKIP,
|
56
|
-
request_id = SKIP,
|
57
|
-
status = SKIP,
|
58
|
-
data = SKIP)
|
59
|
-
@main_reference = main_reference unless main_reference == SKIP
|
60
|
-
@request_id = request_id unless request_id == SKIP
|
61
|
-
@status = status unless status == SKIP
|
62
|
-
@data = data unless data == SKIP
|
63
|
-
end
|
64
|
-
|
65
|
-
# Creates an instance of the object from a hash.
|
66
|
-
def self.from_hash(hash)
|
67
|
-
return nil unless hash
|
68
|
-
|
69
|
-
# Extract variables from the hash.
|
70
|
-
main_reference = hash.key?('MainReference') ? hash['MainReference'] : SKIP
|
71
|
-
request_id = hash.key?('RequestId') ? hash['RequestId'] : SKIP
|
72
|
-
status = hash.key?('Status') ? hash['Status'] : SKIP
|
73
|
-
# Parameter is an array, so we need to iterate through it
|
74
|
-
data = nil
|
75
|
-
unless hash['Data'].nil?
|
76
|
-
data = []
|
77
|
-
hash['Data'].each do |structure|
|
78
|
-
data << (RestrictionCardResponseDataItems.from_hash(structure) if structure)
|
79
|
-
end
|
80
|
-
end
|
81
|
-
|
82
|
-
data = SKIP unless hash.key?('Data')
|
83
|
-
|
84
|
-
# Create object from extracted values.
|
85
|
-
RestrictionCardResponse.new(main_reference,
|
86
|
-
request_id,
|
87
|
-
status,
|
88
|
-
data)
|
89
|
-
end
|
90
|
-
end
|
91
|
-
end
|
@@ -1,79 +0,0 @@
|
|
1
|
-
# shell_card_management_ap_is
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v2.0
|
4
|
-
# ( https://apimatic.io ).
|
5
|
-
|
6
|
-
module ShellCardManagementApIs
|
7
|
-
# RestrictionSearchCardResponse Model.
|
8
|
-
class RestrictionSearchCardResponse < BaseModel
|
9
|
-
SKIP = Object.new
|
10
|
-
private_constant :SKIP
|
11
|
-
|
12
|
-
# API Request ID
|
13
|
-
# @return [String]
|
14
|
-
attr_accessor :request_id
|
15
|
-
|
16
|
-
# API Response Status
|
17
|
-
# @return [String]
|
18
|
-
attr_accessor :status
|
19
|
-
|
20
|
-
# API Response Status
|
21
|
-
# @return [Array[RestrictionSearchCardResponseDataItems]]
|
22
|
-
attr_accessor :data
|
23
|
-
|
24
|
-
# A mapping from model property names to API property names.
|
25
|
-
def self.names
|
26
|
-
@_hash = {} if @_hash.nil?
|
27
|
-
@_hash['request_id'] = 'RequestId'
|
28
|
-
@_hash['status'] = 'Status'
|
29
|
-
@_hash['data'] = 'Data'
|
30
|
-
@_hash
|
31
|
-
end
|
32
|
-
|
33
|
-
# An array for optional fields
|
34
|
-
def self.optionals
|
35
|
-
%w[
|
36
|
-
request_id
|
37
|
-
status
|
38
|
-
data
|
39
|
-
]
|
40
|
-
end
|
41
|
-
|
42
|
-
# An array for nullable fields
|
43
|
-
def self.nullables
|
44
|
-
[]
|
45
|
-
end
|
46
|
-
|
47
|
-
def initialize(request_id = SKIP,
|
48
|
-
status = SKIP,
|
49
|
-
data = SKIP)
|
50
|
-
@request_id = request_id unless request_id == SKIP
|
51
|
-
@status = status unless status == SKIP
|
52
|
-
@data = data unless data == SKIP
|
53
|
-
end
|
54
|
-
|
55
|
-
# Creates an instance of the object from a hash.
|
56
|
-
def self.from_hash(hash)
|
57
|
-
return nil unless hash
|
58
|
-
|
59
|
-
# Extract variables from the hash.
|
60
|
-
request_id = hash.key?('RequestId') ? hash['RequestId'] : SKIP
|
61
|
-
status = hash.key?('Status') ? hash['Status'] : SKIP
|
62
|
-
# Parameter is an array, so we need to iterate through it
|
63
|
-
data = nil
|
64
|
-
unless hash['Data'].nil?
|
65
|
-
data = []
|
66
|
-
hash['Data'].each do |structure|
|
67
|
-
data << (RestrictionSearchCardResponseDataItems.from_hash(structure) if structure)
|
68
|
-
end
|
69
|
-
end
|
70
|
-
|
71
|
-
data = SKIP unless hash.key?('Data')
|
72
|
-
|
73
|
-
# Create object from extracted values.
|
74
|
-
RestrictionSearchCardResponse.new(request_id,
|
75
|
-
status,
|
76
|
-
data)
|
77
|
-
end
|
78
|
-
end
|
79
|
-
end
|
@@ -1,106 +0,0 @@
|
|
1
|
-
# shell_card_management_ap_is
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v2.0
|
4
|
-
# ( https://apimatic.io ).
|
5
|
-
|
6
|
-
module ShellCardManagementApIs
|
7
|
-
# SearchAccountLimitResponseData Model.
|
8
|
-
class SearchAccountLimitResponseData < BaseModel
|
9
|
-
SKIP = Object.new
|
10
|
-
private_constant :SKIP
|
11
|
-
|
12
|
-
# TODO: Write general description for this method
|
13
|
-
# @return [Integer]
|
14
|
-
attr_accessor :account_id
|
15
|
-
|
16
|
-
# Account Number
|
17
|
-
# @return [String]
|
18
|
-
attr_accessor :account_number
|
19
|
-
|
20
|
-
# 3 digit Shell global fuel product code, if already set up.
|
21
|
-
# @return [String]
|
22
|
-
attr_accessor :reference_product
|
23
|
-
|
24
|
-
# The restriction condition code.
|
25
|
-
# @return [String]
|
26
|
-
attr_accessor :restriction_condition
|
27
|
-
|
28
|
-
# The restriction condition code.
|
29
|
-
# @return [Array[AccountVelocityLimit]]
|
30
|
-
attr_accessor :velocity_limits
|
31
|
-
|
32
|
-
# A mapping from model property names to API property names.
|
33
|
-
def self.names
|
34
|
-
@_hash = {} if @_hash.nil?
|
35
|
-
@_hash['account_id'] = 'AccountId'
|
36
|
-
@_hash['account_number'] = 'AccountNumber'
|
37
|
-
@_hash['reference_product'] = 'ReferenceProduct'
|
38
|
-
@_hash['restriction_condition'] = 'RestrictionCondition'
|
39
|
-
@_hash['velocity_limits'] = 'VelocityLimits'
|
40
|
-
@_hash
|
41
|
-
end
|
42
|
-
|
43
|
-
# An array for optional fields
|
44
|
-
def self.optionals
|
45
|
-
%w[
|
46
|
-
account_id
|
47
|
-
account_number
|
48
|
-
reference_product
|
49
|
-
restriction_condition
|
50
|
-
velocity_limits
|
51
|
-
]
|
52
|
-
end
|
53
|
-
|
54
|
-
# An array for nullable fields
|
55
|
-
def self.nullables
|
56
|
-
%w[
|
57
|
-
account_id
|
58
|
-
account_number
|
59
|
-
reference_product
|
60
|
-
restriction_condition
|
61
|
-
]
|
62
|
-
end
|
63
|
-
|
64
|
-
def initialize(account_id = SKIP,
|
65
|
-
account_number = SKIP,
|
66
|
-
reference_product = SKIP,
|
67
|
-
restriction_condition = SKIP,
|
68
|
-
velocity_limits = SKIP)
|
69
|
-
@account_id = account_id unless account_id == SKIP
|
70
|
-
@account_number = account_number unless account_number == SKIP
|
71
|
-
@reference_product = reference_product unless reference_product == SKIP
|
72
|
-
@restriction_condition = restriction_condition unless restriction_condition == SKIP
|
73
|
-
@velocity_limits = velocity_limits unless velocity_limits == SKIP
|
74
|
-
end
|
75
|
-
|
76
|
-
# Creates an instance of the object from a hash.
|
77
|
-
def self.from_hash(hash)
|
78
|
-
return nil unless hash
|
79
|
-
|
80
|
-
# Extract variables from the hash.
|
81
|
-
account_id = hash.key?('AccountId') ? hash['AccountId'] : SKIP
|
82
|
-
account_number = hash.key?('AccountNumber') ? hash['AccountNumber'] : SKIP
|
83
|
-
reference_product =
|
84
|
-
hash.key?('ReferenceProduct') ? hash['ReferenceProduct'] : SKIP
|
85
|
-
restriction_condition =
|
86
|
-
hash.key?('RestrictionCondition') ? hash['RestrictionCondition'] : SKIP
|
87
|
-
# Parameter is an array, so we need to iterate through it
|
88
|
-
velocity_limits = nil
|
89
|
-
unless hash['VelocityLimits'].nil?
|
90
|
-
velocity_limits = []
|
91
|
-
hash['VelocityLimits'].each do |structure|
|
92
|
-
velocity_limits << (AccountVelocityLimit.from_hash(structure) if structure)
|
93
|
-
end
|
94
|
-
end
|
95
|
-
|
96
|
-
velocity_limits = SKIP unless hash.key?('VelocityLimits')
|
97
|
-
|
98
|
-
# Create object from extracted values.
|
99
|
-
SearchAccountLimitResponseData.new(account_id,
|
100
|
-
account_number,
|
101
|
-
reference_product,
|
102
|
-
restriction_condition,
|
103
|
-
velocity_limits)
|
104
|
-
end
|
105
|
-
end
|
106
|
-
end
|
@@ -1,99 +0,0 @@
|
|
1
|
-
# shell_card_management_ap_is
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v2.0
|
4
|
-
# ( https://apimatic.io ).
|
5
|
-
|
6
|
-
module ShellCardManagementApIs
|
7
|
-
# SearchCardResponseRestrictions Model.
|
8
|
-
class SearchCardResponseRestrictions < BaseModel
|
9
|
-
SKIP = Object.new
|
10
|
-
private_constant :SKIP
|
11
|
-
|
12
|
-
# Day/time restrictions such as weekdays and time range to be applied on the
|
13
|
-
# bundle.
|
14
|
-
# Mandatory if respective action is set as “Add”.
|
15
|
-
# The details of DayTimeRestriction entity is given below.
|
16
|
-
# @return [DayTimeRestrictions]
|
17
|
-
attr_accessor :day_time_restrictions
|
18
|
-
|
19
|
-
# Location restrictions to be applied on the bundle which either allows or
|
20
|
-
# restricts using the cards, which are under the bundle, in the specified
|
21
|
-
# locations.
|
22
|
-
# Mandatory if respective action is set as “Add”.
|
23
|
-
# Details of location restrictions are given below.
|
24
|
-
# @return [LocationRestrictions]
|
25
|
-
attr_accessor :location_restrictions
|
26
|
-
|
27
|
-
# Location restrictions to be applied on the bundle which either allows or
|
28
|
-
# restricts using the cards, which are under the bundle, in the specified
|
29
|
-
# locations.
|
30
|
-
# Mandatory if respective action is set as “Add”.
|
31
|
-
# Details of location restrictions are given below.
|
32
|
-
# @return [SearchProductRestriction]
|
33
|
-
attr_accessor :product_restrictions
|
34
|
-
|
35
|
-
# Location restrictions to be applied on the bundle which either allows or
|
36
|
-
# restricts using the cards, which are under the bundle, in the specified
|
37
|
-
# locations.
|
38
|
-
# Mandatory if respective action is set as “Add”.
|
39
|
-
# Details of location restrictions are given below.
|
40
|
-
# @return [UsageRestrictions]
|
41
|
-
attr_accessor :usage_restrictions
|
42
|
-
|
43
|
-
# A mapping from model property names to API property names.
|
44
|
-
def self.names
|
45
|
-
@_hash = {} if @_hash.nil?
|
46
|
-
@_hash['day_time_restrictions'] = 'DayTimeRestrictions'
|
47
|
-
@_hash['location_restrictions'] = 'LocationRestrictions'
|
48
|
-
@_hash['product_restrictions'] = 'ProductRestrictions'
|
49
|
-
@_hash['usage_restrictions'] = 'UsageRestrictions'
|
50
|
-
@_hash
|
51
|
-
end
|
52
|
-
|
53
|
-
# An array for optional fields
|
54
|
-
def self.optionals
|
55
|
-
%w[
|
56
|
-
day_time_restrictions
|
57
|
-
location_restrictions
|
58
|
-
product_restrictions
|
59
|
-
usage_restrictions
|
60
|
-
]
|
61
|
-
end
|
62
|
-
|
63
|
-
# An array for nullable fields
|
64
|
-
def self.nullables
|
65
|
-
[]
|
66
|
-
end
|
67
|
-
|
68
|
-
def initialize(day_time_restrictions = SKIP,
|
69
|
-
location_restrictions = SKIP,
|
70
|
-
product_restrictions = SKIP,
|
71
|
-
usage_restrictions = SKIP)
|
72
|
-
@day_time_restrictions = day_time_restrictions unless day_time_restrictions == SKIP
|
73
|
-
@location_restrictions = location_restrictions unless location_restrictions == SKIP
|
74
|
-
@product_restrictions = product_restrictions unless product_restrictions == SKIP
|
75
|
-
@usage_restrictions = usage_restrictions unless usage_restrictions == SKIP
|
76
|
-
end
|
77
|
-
|
78
|
-
# Creates an instance of the object from a hash.
|
79
|
-
def self.from_hash(hash)
|
80
|
-
return nil unless hash
|
81
|
-
|
82
|
-
# Extract variables from the hash.
|
83
|
-
day_time_restrictions = DayTimeRestrictions.from_hash(hash['DayTimeRestrictions']) if
|
84
|
-
hash['DayTimeRestrictions']
|
85
|
-
location_restrictions = LocationRestrictions.from_hash(hash['LocationRestrictions']) if
|
86
|
-
hash['LocationRestrictions']
|
87
|
-
product_restrictions = SearchProductRestriction.from_hash(hash['ProductRestrictions']) if
|
88
|
-
hash['ProductRestrictions']
|
89
|
-
usage_restrictions = UsageRestrictions.from_hash(hash['UsageRestrictions']) if
|
90
|
-
hash['UsageRestrictions']
|
91
|
-
|
92
|
-
# Create object from extracted values.
|
93
|
-
SearchCardResponseRestrictions.new(day_time_restrictions,
|
94
|
-
location_restrictions,
|
95
|
-
product_restrictions,
|
96
|
-
usage_restrictions)
|
97
|
-
end
|
98
|
-
end
|
99
|
-
end
|