katapult-ruby 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +121 -57
- data/lib/katapult-ruby/models/{interface_not_found_response.rb → api_authenticator400_schema.rb} +5 -17
- data/lib/katapult-ruby/models/certificate_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/country_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/country_state_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/currency_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/data_center_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/{location_required_response.rb → data_center_not_found_schema.rb} +5 -17
- data/lib/katapult-ruby/models/delete_ip_address409_response.rb +1 -13
- data/lib/katapult-ruby/models/delete_ssh_key404_response.rb +1 -13
- data/lib/katapult-ruby/models/delete_ssh_key409_response.rb +1 -13
- data/lib/katapult-ruby/models/deletion_restricted_enum.rb +39 -0
- data/lib/katapult-ruby/models/disk_backup_policy_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/disk_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/disk_template_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/{ip_already_allocated_response.rb → disk_template_not_found_schema.rb} +5 -17
- data/lib/katapult-ruby/models/disk_template_version_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/dns_record_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/dns_zone_already_verified_enum.rb +39 -0
- data/lib/katapult-ruby/models/dns_zone_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/dns_zone_not_verified_enum.rb +39 -0
- data/lib/katapult-ruby/models/file_storage_volume_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/flexible_resources_unavailable_to_organization_enum.rb +39 -0
- data/lib/katapult-ruby/models/{flexible_resources_unavailable_to_organization_response.rb → flexible_resources_unavailable_to_organization_schema.rb} +4 -16
- data/lib/katapult-ruby/models/get_certificate404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_country404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_country_state404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_currency404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_data_center404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_data_centers400_response.rb +1 -13
- data/lib/katapult-ruby/models/get_data_centers429_response.rb +1 -13
- data/lib/katapult-ruby/models/get_disk404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_disk_backup_policy404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_disk_template404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_disk_template_version404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_dns_records_dns_record404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_dns_zones_dns_zone404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_dns_zones_dns_zone_verification_details422_response.rb +1 -13
- data/lib/katapult-ruby/models/get_file_storage_volume404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_gpu_type404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_ip_address404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_load_balancer404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_load_balancers_rules_load_balancer_rule404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_network404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_operating_system404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_organization404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_security_group404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_security_groups_rules_security_group_rule404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_tag404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_task404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_trash_object404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_users_current404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_virtual_machine_disks404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_virtual_machine_disks406_response.rb +1 -13
- data/lib/katapult-ruby/models/get_virtual_machine_group404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_virtual_machine_package404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_virtual_machines_builds_virtual_machine_build404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_vmnivmni404_response.rb +1 -13
- data/lib/katapult-ruby/models/get_zone404_response.rb +1 -13
- data/lib/katapult-ruby/models/gpu_type_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/identity_not_linked_to_web_session_enum.rb +39 -0
- data/lib/katapult-ruby/models/{network_speed_profile_not_found_response.rb → identity_not_linked_to_web_session_schema.rb} +5 -17
- data/lib/katapult-ruby/models/infrastructure_dns_zone_cannot_be_edited_enum.rb +39 -0
- data/lib/katapult-ruby/models/{infrastructure_dns_zone_cannot_be_edited_response.rb → infrastructure_dns_zone_cannot_be_edited_schema.rb} +4 -16
- data/lib/katapult-ruby/models/interface_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/{network_not_found_response.rb → interface_not_found_schema.rb} +5 -17
- data/lib/katapult-ruby/models/invalid_api_token_enum.rb +39 -0
- data/lib/katapult-ruby/models/{invalid_api_token_response.rb → invalid_api_token_schema.rb} +4 -16
- data/lib/katapult-ruby/models/invalid_ip_enum.rb +39 -0
- data/lib/katapult-ruby/models/{invalid_ip_response.rb → invalid_ip_schema.rb} +4 -16
- data/lib/katapult-ruby/models/invalid_spec_xml_enum.rb +39 -0
- data/lib/katapult-ruby/models/invalid_spec_xml_schema.rb +255 -0
- data/lib/katapult-ruby/models/invalid_timestamp_enum.rb +39 -0
- data/lib/katapult-ruby/models/{invalid_spec_xml_response.rb → invalid_timestamp_schema.rb} +6 -18
- data/lib/katapult-ruby/models/ip_address_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/{ip_address_not_found_response.rb → ip_address_not_found_schema.rb} +4 -16
- data/lib/katapult-ruby/models/ip_already_allocated_enum.rb +39 -0
- data/lib/katapult-ruby/models/ip_already_allocated_schema.rb +255 -0
- data/lib/katapult-ruby/models/load_balancer_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/load_balancer_rule_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/location_required_enum.rb +39 -0
- data/lib/katapult-ruby/models/location_required_schema.rb +255 -0
- data/lib/katapult-ruby/models/missing_api_token_enum.rb +39 -0
- data/lib/katapult-ruby/models/network_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/network_not_found_schema.rb +255 -0
- data/lib/katapult-ruby/models/network_speed_profile_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/network_speed_profile_not_found_schema.rb +255 -0
- data/lib/katapult-ruby/models/no_allocation_enum.rb +39 -0
- data/lib/katapult-ruby/models/no_available_addresses_enum.rb +39 -0
- data/lib/katapult-ruby/models/no_interface_available_enum.rb +39 -0
- data/lib/katapult-ruby/models/{data_center_not_found_response.rb → no_interface_available_schema.rb} +5 -17
- data/lib/katapult-ruby/models/no_user_associated_with_identity_enum.rb +39 -0
- data/lib/katapult-ruby/models/object_in_trash_enum.rb +39 -0
- data/lib/katapult-ruby/models/{object_in_trash_response.rb → object_in_trash_schema.rb} +4 -16
- data/lib/katapult-ruby/models/one_of_api_authenticator403_response.rb +3 -3
- data/lib/katapult-ruby/models/{one_of_data_center_not_found_virtual_machine_package_not_found_zone_not_found404_error.rb → one_of_data_center_not_found_virtual_machine_package_not_found_zone_not_found404_res.rb} +7 -7
- data/lib/katapult-ruby/models/{one_of_flexible_resources_unavailable_to_organization_permission_denied403_error.rb → one_of_flexible_resources_unavailable_to_organization_permission_denied403_res.rb} +6 -6
- data/lib/katapult-ruby/models/one_of_identity_not_linked_to_web_session400_res.rb +105 -0
- data/lib/katapult-ruby/models/one_of_infrastructure_dns_zone_cannot_be_edited403_res.rb +107 -0
- data/lib/katapult-ruby/models/{one_of_interface_not_found_network_not_found_virtual_machine_not_found404_error.rb → one_of_interface_not_found_network_not_found_virtual_machine_not_found404_res.rb} +4 -4
- data/lib/katapult-ruby/models/{one_of_invalid_spec_xml400_error.rb → one_of_invalid_spec_xml400_res.rb} +3 -3
- data/lib/katapult-ruby/models/{one_of_invalid_timestamp400_error.rb → one_of_invalid_timestamp400_res.rb} +3 -3
- data/lib/katapult-ruby/models/{one_of_ip_address_not_found_virtual_machine_network_interface_not_found404_error.rb → one_of_ip_address_not_found_virtual_machine_network_interface_not_found404_res.rb} +3 -3
- data/lib/katapult-ruby/models/one_of_ip_address_not_found_virtual_machine_not_found404_res.rb +105 -0
- data/lib/katapult-ruby/models/{one_of_ip_already_allocated_invalid_ip422_error.rb → one_of_ip_already_allocated_invalid_ip422_res.rb} +3 -3
- data/lib/katapult-ruby/models/one_of_ip_already_allocated_no_interface_available422_res.rb +105 -0
- data/lib/katapult-ruby/models/{one_of_object_in_trash_task_queueing_error406_error.rb → one_of_location_required_validation_error422_res.rb} +3 -3
- data/lib/katapult-ruby/models/{one_of_location_required_validation_error422_error.rb → one_of_network_not_found_organization_not_found404_res.rb} +3 -3
- data/lib/katapult-ruby/models/{one_of_network_speed_profile_not_found_virtual_machine_network_interface_not_found404_error.rb → one_of_network_speed_profile_not_found_virtual_machine_network_interface_not_found404_res.rb} +3 -3
- data/lib/katapult-ruby/models/one_of_object_in_trash_task_queueing_error406_res.rb +105 -0
- data/lib/katapult-ruby/models/one_of_object_in_trash_virtual_machine_must_be_started406_res.rb +105 -0
- data/lib/katapult-ruby/models/{one_of_ip_address_not_found_virtual_machine_not_found404_error.rb → one_of_operating_system_not_found_organization_not_found404_res.rb} +3 -3
- data/lib/katapult-ruby/models/one_of_organization_limit_reached_validation_error422_res.rb +105 -0
- data/lib/katapult-ruby/models/{one_of_infrastructure_dns_zone_cannot_be_edited403_error.rb → one_of_organization_not_activated_organization_suspended403_res.rb} +6 -5
- data/lib/katapult-ruby/models/{one_of_organization_not_activated_organization_suspended_permission_denied403_error.rb → one_of_organization_not_activated_organization_suspended_permission_denied403_res.rb} +7 -7
- data/lib/katapult-ruby/models/{one_of_organization_not_activated_permission_denied_resource_creation_restricted403_error.rb → one_of_organization_not_activated_permission_denied_resource_creation_restricted403_res.rb} +8 -8
- data/lib/katapult-ruby/models/{one_of_identity_not_linked_to_web_session400_error.rb → one_of_permission_denied403_res.rb} +5 -3
- data/lib/katapult-ruby/models/{one_of_virtual_machine_not_found_virtual_machine_package_not_found404_error.rb → one_of_virtual_machine_not_found_virtual_machine_package_not_found404_res.rb} +3 -3
- data/lib/katapult-ruby/models/operating_system_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/{organization_suspended_response.rb → operating_system_not_found_schema.rb} +5 -17
- data/lib/katapult-ruby/models/organization_limit_reached_enum.rb +39 -0
- data/lib/katapult-ruby/models/{virtual_machine_not_found_response.rb → organization_limit_reached_schema.rb} +5 -17
- data/lib/katapult-ruby/models/organization_not_activated_enum.rb +39 -0
- data/lib/katapult-ruby/models/{organization_not_activated_response.rb → organization_not_activated_schema.rb} +4 -16
- data/lib/katapult-ruby/models/organization_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/organization_not_found_schema.rb +255 -0
- data/lib/katapult-ruby/models/organization_suspended_enum.rb +39 -0
- data/lib/katapult-ruby/models/{api_authenticator400_response.rb → organization_suspended_schema.rb} +5 -17
- data/lib/katapult-ruby/models/patch_virtual_machine_network_interface_update_speed_profile406_response.rb +1 -13
- data/lib/katapult-ruby/models/patch_virtual_machine_network_interface_update_speed_profile422_response.rb +1 -13
- data/lib/katapult-ruby/models/permission_denied_enum.rb +39 -0
- data/lib/katapult-ruby/models/{permission_denied_response.rb → permission_denied_schema.rb} +4 -16
- data/lib/katapult-ruby/models/post_dns_zones_dns_zone_verify422_response.rb +1 -13
- data/lib/katapult-ruby/models/post_ip_address_unallocate422_response.rb +1 -13
- data/lib/katapult-ruby/models/post_organization_ip_addresses503_response.rb +1 -13
- data/lib/katapult-ruby/models/post_organization_virtual_machines_build_from_spec422_response.rb +1 -13
- data/lib/katapult-ruby/models/rate_limit_reached_enum.rb +39 -0
- data/lib/katapult-ruby/models/resource_creation_restricted_enum.rb +39 -0
- data/lib/katapult-ruby/models/{organization_limit_reached_response.rb → resource_creation_restricted_schema.rb} +6 -18
- data/lib/katapult-ruby/models/resource_does_not_support_unallocation_enum.rb +39 -0
- data/lib/katapult-ruby/models/scope_not_granted_error_enum.rb +39 -0
- data/lib/katapult-ruby/models/{scope_not_granted_error_response.rb → scope_not_granted_error_schema.rb} +4 -16
- data/lib/katapult-ruby/models/security_group_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/security_group_rule_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/speed_profile_already_assigned_enum.rb +39 -0
- data/lib/katapult-ruby/models/ssh_key_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/tag_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/task_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/task_queueing_error_enum.rb +39 -0
- data/lib/katapult-ruby/models/{task_queueing_error_response.rb → task_queueing_error_schema.rb} +4 -16
- data/lib/katapult-ruby/models/trash_object_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/unauthorized_network_for_api_token_enum.rb +39 -0
- data/lib/katapult-ruby/models/{unauthorized_network_for_api_token_response.rb → unauthorized_network_for_api_token_schema.rb} +4 -16
- data/lib/katapult-ruby/models/validation_error_enum.rb +39 -0
- data/lib/katapult-ruby/models/{validation_error_response.rb → validation_error_schema.rb} +4 -16
- data/lib/katapult-ruby/models/virtual_machine_build_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/virtual_machine_group_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/virtual_machine_must_be_started_enum.rb +39 -0
- data/lib/katapult-ruby/models/{virtual_machine_must_be_started_response.rb → virtual_machine_must_be_started_schema.rb} +4 -16
- data/lib/katapult-ruby/models/virtual_machine_network_interface_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/{virtual_machine_network_interface_not_found_response.rb → virtual_machine_network_interface_not_found_schema.rb} +4 -16
- data/lib/katapult-ruby/models/virtual_machine_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/{organization_not_found_response.rb → virtual_machine_not_found_schema.rb} +5 -17
- data/lib/katapult-ruby/models/virtual_machine_package_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/{virtual_machine_package_not_found_response.rb → virtual_machine_package_not_found_schema.rb} +4 -16
- data/lib/katapult-ruby/models/zone_not_found_enum.rb +39 -0
- data/lib/katapult-ruby/models/{zone_not_found_response.rb → zone_not_found_schema.rb} +4 -16
- data/lib/katapult-ruby/version.rb +1 -1
- data/lib/katapult-ruby.rb +121 -57
- metadata +123 -59
- data/lib/katapult-ruby/models/disk_template_not_found_response.rb +0 -267
- data/lib/katapult-ruby/models/identity_not_linked_to_web_session_response.rb +0 -267
- data/lib/katapult-ruby/models/invalid_timestamp_response.rb +0 -267
- data/lib/katapult-ruby/models/no_interface_available_response.rb +0 -267
- data/lib/katapult-ruby/models/one_of_ip_already_allocated_no_interface_available422_error.rb +0 -105
- data/lib/katapult-ruby/models/one_of_network_not_found_organization_not_found404_error.rb +0 -105
- data/lib/katapult-ruby/models/one_of_object_in_trash_virtual_machine_must_be_started406_error.rb +0 -105
- data/lib/katapult-ruby/models/one_of_operating_system_not_found_organization_not_found404_error.rb +0 -105
- data/lib/katapult-ruby/models/one_of_organization_limit_reached_validation_error422_error.rb +0 -105
- data/lib/katapult-ruby/models/one_of_organization_not_activated_organization_suspended403_error.rb +0 -108
- data/lib/katapult-ruby/models/one_of_permission_denied403_error.rb +0 -107
- data/lib/katapult-ruby/models/operating_system_not_found_response.rb +0 -267
- data/lib/katapult-ruby/models/resource_creation_restricted_response.rb +0 -267
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class ResourceCreationRestrictedEnum
|
18
|
+
RESOURCE_CREATION_RESTRICTED = "resource_creation_restricted".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [RESOURCE_CREATION_RESTRICTED].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if ResourceCreationRestrictedEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #ResourceCreationRestrictedEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -14,8 +14,8 @@ require 'date'
|
|
14
14
|
require 'time'
|
15
15
|
|
16
16
|
module KatapultAPI
|
17
|
-
# The
|
18
|
-
class
|
17
|
+
# The organization chosen is not permitted to create resources
|
18
|
+
class ResourceCreationRestrictedSchema
|
19
19
|
attr_accessor :code
|
20
20
|
|
21
21
|
attr_accessor :description
|
@@ -61,9 +61,9 @@ module KatapultAPI
|
|
61
61
|
# Attribute type mapping.
|
62
62
|
def self.openapi_types
|
63
63
|
{
|
64
|
-
:'code' => :'
|
64
|
+
:'code' => :'ResourceCreationRestrictedEnum',
|
65
65
|
:'description' => :'String',
|
66
|
-
:'detail' => :'
|
66
|
+
:'detail' => :'ResourceCreationRestricted'
|
67
67
|
}
|
68
68
|
end
|
69
69
|
|
@@ -77,13 +77,13 @@ module KatapultAPI
|
|
77
77
|
# @param [Hash] attributes Model attributes in the form of hash
|
78
78
|
def initialize(attributes = {})
|
79
79
|
if (!attributes.is_a?(Hash))
|
80
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `KatapultAPI::
|
80
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `KatapultAPI::ResourceCreationRestrictedSchema` initialize method"
|
81
81
|
end
|
82
82
|
|
83
83
|
# check to see if the attribute exists and convert string to symbol for hash key
|
84
84
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
85
85
|
if (!self.class.attribute_map.key?(k.to_sym))
|
86
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `KatapultAPI::
|
86
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `KatapultAPI::ResourceCreationRestrictedSchema`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
87
87
|
end
|
88
88
|
h[k.to_sym] = v
|
89
89
|
}
|
@@ -113,21 +113,9 @@ module KatapultAPI
|
|
113
113
|
# @return true if the model is valid
|
114
114
|
def valid?
|
115
115
|
warn '[DEPRECATED] the `valid?` method is obsolete'
|
116
|
-
code_validator = EnumAttributeValidator.new('String', ["organization_limit_reached"])
|
117
|
-
return false unless code_validator.valid?(@code)
|
118
116
|
true
|
119
117
|
end
|
120
118
|
|
121
|
-
# Custom attribute writer method checking allowed values (enum).
|
122
|
-
# @param [Object] code Object to be assigned
|
123
|
-
def code=(code)
|
124
|
-
validator = EnumAttributeValidator.new('String', ["organization_limit_reached"])
|
125
|
-
unless validator.valid?(code)
|
126
|
-
fail ArgumentError, "invalid value for \"code\", must be one of #{validator.allowable_values}."
|
127
|
-
end
|
128
|
-
@code = code
|
129
|
-
end
|
130
|
-
|
131
119
|
# Checks equality by comparing each attribute.
|
132
120
|
# @param [Object] Object to be compared
|
133
121
|
def ==(o)
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class ResourceDoesNotSupportUnallocationEnum
|
18
|
+
RESOURCE_DOES_NOT_SUPPORT_UNALLOCATION = "resource_does_not_support_unallocation".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [RESOURCE_DOES_NOT_SUPPORT_UNALLOCATION].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if ResourceDoesNotSupportUnallocationEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #ResourceDoesNotSupportUnallocationEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class ScopeNotGrantedErrorEnum
|
18
|
+
SCOPE_NOT_GRANTED = "scope_not_granted".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [SCOPE_NOT_GRANTED].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if ScopeNotGrantedErrorEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #ScopeNotGrantedErrorEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -15,7 +15,7 @@ require 'time'
|
|
15
15
|
|
16
16
|
module KatapultAPI
|
17
17
|
# The scope required for this endpoint has not been granted to the authenticating identity
|
18
|
-
class
|
18
|
+
class ScopeNotGrantedErrorSchema
|
19
19
|
attr_accessor :code
|
20
20
|
|
21
21
|
attr_accessor :description
|
@@ -61,7 +61,7 @@ module KatapultAPI
|
|
61
61
|
# Attribute type mapping.
|
62
62
|
def self.openapi_types
|
63
63
|
{
|
64
|
-
:'code' => :'
|
64
|
+
:'code' => :'ScopeNotGrantedErrorEnum',
|
65
65
|
:'description' => :'String',
|
66
66
|
:'detail' => :'ScopeNotGrantedError'
|
67
67
|
}
|
@@ -77,13 +77,13 @@ module KatapultAPI
|
|
77
77
|
# @param [Hash] attributes Model attributes in the form of hash
|
78
78
|
def initialize(attributes = {})
|
79
79
|
if (!attributes.is_a?(Hash))
|
80
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `KatapultAPI::
|
80
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `KatapultAPI::ScopeNotGrantedErrorSchema` initialize method"
|
81
81
|
end
|
82
82
|
|
83
83
|
# check to see if the attribute exists and convert string to symbol for hash key
|
84
84
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
85
85
|
if (!self.class.attribute_map.key?(k.to_sym))
|
86
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `KatapultAPI::
|
86
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `KatapultAPI::ScopeNotGrantedErrorSchema`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
87
87
|
end
|
88
88
|
h[k.to_sym] = v
|
89
89
|
}
|
@@ -113,21 +113,9 @@ module KatapultAPI
|
|
113
113
|
# @return true if the model is valid
|
114
114
|
def valid?
|
115
115
|
warn '[DEPRECATED] the `valid?` method is obsolete'
|
116
|
-
code_validator = EnumAttributeValidator.new('String', ["scope_not_granted"])
|
117
|
-
return false unless code_validator.valid?(@code)
|
118
116
|
true
|
119
117
|
end
|
120
118
|
|
121
|
-
# Custom attribute writer method checking allowed values (enum).
|
122
|
-
# @param [Object] code Object to be assigned
|
123
|
-
def code=(code)
|
124
|
-
validator = EnumAttributeValidator.new('String', ["scope_not_granted"])
|
125
|
-
unless validator.valid?(code)
|
126
|
-
fail ArgumentError, "invalid value for \"code\", must be one of #{validator.allowable_values}."
|
127
|
-
end
|
128
|
-
@code = code
|
129
|
-
end
|
130
|
-
|
131
119
|
# Checks equality by comparing each attribute.
|
132
120
|
# @param [Object] Object to be compared
|
133
121
|
def ==(o)
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class SecurityGroupNotFoundEnum
|
18
|
+
SECURITY_GROUP_NOT_FOUND = "security_group_not_found".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [SECURITY_GROUP_NOT_FOUND].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if SecurityGroupNotFoundEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #SecurityGroupNotFoundEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class SecurityGroupRuleNotFoundEnum
|
18
|
+
SECURITY_GROUP_RULE_NOT_FOUND = "security_group_rule_not_found".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [SECURITY_GROUP_RULE_NOT_FOUND].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if SecurityGroupRuleNotFoundEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #SecurityGroupRuleNotFoundEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class SpeedProfileAlreadyAssignedEnum
|
18
|
+
SPEED_PROFILE_ALREADY_ASSIGNED = "speed_profile_already_assigned".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [SPEED_PROFILE_ALREADY_ASSIGNED].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if SpeedProfileAlreadyAssignedEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #SpeedProfileAlreadyAssignedEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class SSHKeyNotFoundEnum
|
18
|
+
SSH_KEY_NOT_FOUND = "ssh_key_not_found".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [SSH_KEY_NOT_FOUND].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if SSHKeyNotFoundEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #SSHKeyNotFoundEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class TagNotFoundEnum
|
18
|
+
TAG_NOT_FOUND = "tag_not_found".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [TAG_NOT_FOUND].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if TagNotFoundEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #TagNotFoundEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class TaskNotFoundEnum
|
18
|
+
TASK_NOT_FOUND = "task_not_found".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [TASK_NOT_FOUND].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if TaskNotFoundEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #TaskNotFoundEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class TaskQueueingErrorEnum
|
18
|
+
TASK_QUEUEING_ERROR = "task_queueing_error".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [TASK_QUEUEING_ERROR].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if TaskQueueingErrorEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #TaskQueueingErrorEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
data/lib/katapult-ruby/models/{task_queueing_error_response.rb → task_queueing_error_schema.rb}
RENAMED
@@ -15,7 +15,7 @@ require 'time'
|
|
15
15
|
|
16
16
|
module KatapultAPI
|
17
17
|
# This error means that a background task that was needed to complete your request could not be queued
|
18
|
-
class
|
18
|
+
class TaskQueueingErrorSchema
|
19
19
|
attr_accessor :code
|
20
20
|
|
21
21
|
attr_accessor :description
|
@@ -61,7 +61,7 @@ module KatapultAPI
|
|
61
61
|
# Attribute type mapping.
|
62
62
|
def self.openapi_types
|
63
63
|
{
|
64
|
-
:'code' => :'
|
64
|
+
:'code' => :'TaskQueueingErrorEnum',
|
65
65
|
:'description' => :'String',
|
66
66
|
:'detail' => :'TaskQueueingError'
|
67
67
|
}
|
@@ -77,13 +77,13 @@ module KatapultAPI
|
|
77
77
|
# @param [Hash] attributes Model attributes in the form of hash
|
78
78
|
def initialize(attributes = {})
|
79
79
|
if (!attributes.is_a?(Hash))
|
80
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `KatapultAPI::
|
80
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `KatapultAPI::TaskQueueingErrorSchema` initialize method"
|
81
81
|
end
|
82
82
|
|
83
83
|
# check to see if the attribute exists and convert string to symbol for hash key
|
84
84
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
85
85
|
if (!self.class.attribute_map.key?(k.to_sym))
|
86
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `KatapultAPI::
|
86
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `KatapultAPI::TaskQueueingErrorSchema`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
87
87
|
end
|
88
88
|
h[k.to_sym] = v
|
89
89
|
}
|
@@ -113,21 +113,9 @@ module KatapultAPI
|
|
113
113
|
# @return true if the model is valid
|
114
114
|
def valid?
|
115
115
|
warn '[DEPRECATED] the `valid?` method is obsolete'
|
116
|
-
code_validator = EnumAttributeValidator.new('String', ["task_queueing_error"])
|
117
|
-
return false unless code_validator.valid?(@code)
|
118
116
|
true
|
119
117
|
end
|
120
118
|
|
121
|
-
# Custom attribute writer method checking allowed values (enum).
|
122
|
-
# @param [Object] code Object to be assigned
|
123
|
-
def code=(code)
|
124
|
-
validator = EnumAttributeValidator.new('String', ["task_queueing_error"])
|
125
|
-
unless validator.valid?(code)
|
126
|
-
fail ArgumentError, "invalid value for \"code\", must be one of #{validator.allowable_values}."
|
127
|
-
end
|
128
|
-
@code = code
|
129
|
-
end
|
130
|
-
|
131
119
|
# Checks equality by comparing each attribute.
|
132
120
|
# @param [Object] Object to be compared
|
133
121
|
def ==(o)
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class TrashObjectNotFoundEnum
|
18
|
+
TRASH_OBJECT_NOT_FOUND = "trash_object_not_found".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [TRASH_OBJECT_NOT_FOUND].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if TrashObjectNotFoundEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #TrashObjectNotFoundEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
=begin
|
2
|
+
#Katapult Core API
|
3
|
+
|
4
|
+
#Welcome to the documentation for the Katapult Core API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 7.1.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module KatapultAPI
|
17
|
+
class UnauthorizedNetworkForAPITokenEnum
|
18
|
+
UNAUTHORIZED_NETWORK_FOR_API_TOKEN = "unauthorized_network_for_api_token".freeze
|
19
|
+
|
20
|
+
def self.all_vars
|
21
|
+
@all_vars ||= [UNAUTHORIZED_NETWORK_FOR_API_TOKEN].freeze
|
22
|
+
end
|
23
|
+
|
24
|
+
# Builds the enum from string
|
25
|
+
# @param [String] The enum value in the form of the string
|
26
|
+
# @return [String] The enum value
|
27
|
+
def self.build_from_hash(value)
|
28
|
+
new.build_from_hash(value)
|
29
|
+
end
|
30
|
+
|
31
|
+
# Builds the enum from string
|
32
|
+
# @param [String] The enum value in the form of the string
|
33
|
+
# @return [String] The enum value
|
34
|
+
def build_from_hash(value)
|
35
|
+
return value if UnauthorizedNetworkForAPITokenEnum.all_vars.include?(value)
|
36
|
+
raise "Invalid ENUM value #{value} for class #UnauthorizedNetworkForAPITokenEnum"
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|