Class: DaytonaApiClient::Organization
- Inherits:
-
Object
- Object
- DaytonaApiClient::Organization
- Defined in:
- lib/daytona_api_client/models/organization.rb
Instance Attribute Summary collapse
-
#authenticated_rate_limit ⇒ Object
Authenticated rate limit per minute.
-
#authenticated_rate_limit_ttl_seconds ⇒ Object
Authenticated rate limit TTL in seconds.
-
#created_at ⇒ Object
Creation timestamp.
-
#created_by ⇒ Object
User ID of the organization creator.
-
#default_region_id ⇒ Object
Default region ID.
-
#experimental_config ⇒ Object
Experimental configuration.
-
#id ⇒ Object
Organization ID.
-
#max_cpu_per_sandbox ⇒ Object
Max CPU per sandbox.
-
#max_disk_per_sandbox ⇒ Object
Max disk per sandbox.
-
#max_memory_per_sandbox ⇒ Object
Max memory per sandbox.
-
#name ⇒ Object
Organization name.
-
#personal ⇒ Object
Personal organization flag.
-
#sandbox_create_rate_limit ⇒ Object
Sandbox create rate limit per minute.
-
#sandbox_create_rate_limit_ttl_seconds ⇒ Object
Sandbox create rate limit TTL in seconds.
-
#sandbox_lifecycle_rate_limit ⇒ Object
Sandbox lifecycle rate limit per minute.
-
#sandbox_lifecycle_rate_limit_ttl_seconds ⇒ Object
Sandbox lifecycle rate limit TTL in seconds.
-
#sandbox_limited_network_egress ⇒ Object
Sandbox default network block all.
-
#snapshot_deactivation_timeout_minutes ⇒ Object
Time in minutes before an unused snapshot is deactivated.
-
#suspended ⇒ Object
Suspended flag.
-
#suspended_at ⇒ Object
Suspended at.
-
#suspended_until ⇒ Object
Suspended until.
-
#suspension_cleanup_grace_period_hours ⇒ Object
Suspension cleanup grace period hours.
-
#suspension_reason ⇒ Object
Suspended reason.
-
#updated_at ⇒ Object
Last update timestamp.
Class Method Summary collapse
-
._deserialize(type, value) ⇒ Object
Deserializes the data based on type.
-
.acceptable_attribute_map ⇒ Object
Returns attribute mapping this model knows about.
-
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about.
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.build_from_hash(attributes) ⇒ Object
Builds the object from hash.
-
.openapi_nullable ⇒ Object
List of attributes with nullable: true.
-
.openapi_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(o) ⇒ Object
Checks equality by comparing each attribute.
-
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash.
- #eql?(o) ⇒ Boolean
-
#hash ⇒ Integer
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ Organization
constructor
Initializes the object.
-
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons.
-
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility).
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
-
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid.
Constructor Details
#initialize(attributes = {}) ⇒ Organization
Initializes the object
174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 |
# File 'lib/daytona_api_client/models/organization.rb', line 174 def initialize(attributes = {}) if (!attributes.is_a?(Hash)) fail ArgumentError, "The input argument (attributes) must be a hash in `DaytonaApiClient::Organization` initialize method" end # check to see if the attribute exists and convert string to symbol for hash key acceptable_attribute_map = self.class.acceptable_attribute_map attributes = attributes.each_with_object({}) { |(k, v), h| if (!acceptable_attribute_map.key?(k.to_sym)) fail ArgumentError, "`#{k}` is not a valid attribute in `DaytonaApiClient::Organization`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect end h[k.to_sym] = v } if attributes.key?(:'id') self.id = attributes[:'id'] else self.id = nil end if attributes.key?(:'name') self.name = attributes[:'name'] else self.name = nil end if attributes.key?(:'created_by') self.created_by = attributes[:'created_by'] else self.created_by = nil end if attributes.key?(:'personal') self.personal = attributes[:'personal'] else self.personal = nil end if attributes.key?(:'created_at') self.created_at = attributes[:'created_at'] else self.created_at = nil end if attributes.key?(:'updated_at') self.updated_at = attributes[:'updated_at'] else self.updated_at = nil end if attributes.key?(:'suspended') self.suspended = attributes[:'suspended'] else self.suspended = nil end if attributes.key?(:'suspended_at') self.suspended_at = attributes[:'suspended_at'] else self.suspended_at = nil end if attributes.key?(:'suspension_reason') self.suspension_reason = attributes[:'suspension_reason'] else self.suspension_reason = nil end if attributes.key?(:'suspended_until') self.suspended_until = attributes[:'suspended_until'] else self.suspended_until = nil end if attributes.key?(:'suspension_cleanup_grace_period_hours') self.suspension_cleanup_grace_period_hours = attributes[:'suspension_cleanup_grace_period_hours'] else self.suspension_cleanup_grace_period_hours = nil end if attributes.key?(:'max_cpu_per_sandbox') self.max_cpu_per_sandbox = attributes[:'max_cpu_per_sandbox'] else self.max_cpu_per_sandbox = nil end if attributes.key?(:'max_memory_per_sandbox') self.max_memory_per_sandbox = attributes[:'max_memory_per_sandbox'] else self.max_memory_per_sandbox = nil end if attributes.key?(:'max_disk_per_sandbox') self.max_disk_per_sandbox = attributes[:'max_disk_per_sandbox'] else self.max_disk_per_sandbox = nil end if attributes.key?(:'snapshot_deactivation_timeout_minutes') self.snapshot_deactivation_timeout_minutes = attributes[:'snapshot_deactivation_timeout_minutes'] else self.snapshot_deactivation_timeout_minutes = 20160 end if attributes.key?(:'sandbox_limited_network_egress') self.sandbox_limited_network_egress = attributes[:'sandbox_limited_network_egress'] else self.sandbox_limited_network_egress = nil end if attributes.key?(:'default_region_id') self.default_region_id = attributes[:'default_region_id'] end if attributes.key?(:'authenticated_rate_limit') self.authenticated_rate_limit = attributes[:'authenticated_rate_limit'] else self.authenticated_rate_limit = nil end if attributes.key?(:'sandbox_create_rate_limit') self.sandbox_create_rate_limit = attributes[:'sandbox_create_rate_limit'] else self.sandbox_create_rate_limit = nil end if attributes.key?(:'sandbox_lifecycle_rate_limit') self.sandbox_lifecycle_rate_limit = attributes[:'sandbox_lifecycle_rate_limit'] else self.sandbox_lifecycle_rate_limit = nil end if attributes.key?(:'experimental_config') self.experimental_config = attributes[:'experimental_config'] else self.experimental_config = nil end if attributes.key?(:'authenticated_rate_limit_ttl_seconds') self.authenticated_rate_limit_ttl_seconds = attributes[:'authenticated_rate_limit_ttl_seconds'] else self.authenticated_rate_limit_ttl_seconds = nil end if attributes.key?(:'sandbox_create_rate_limit_ttl_seconds') self.sandbox_create_rate_limit_ttl_seconds = attributes[:'sandbox_create_rate_limit_ttl_seconds'] else self.sandbox_create_rate_limit_ttl_seconds = nil end if attributes.key?(:'sandbox_lifecycle_rate_limit_ttl_seconds') self.sandbox_lifecycle_rate_limit_ttl_seconds = attributes[:'sandbox_lifecycle_rate_limit_ttl_seconds'] else self.sandbox_lifecycle_rate_limit_ttl_seconds = nil end end |
Instance Attribute Details
#authenticated_rate_limit ⇒ Object
Authenticated rate limit per minute
70 71 72 |
# File 'lib/daytona_api_client/models/organization.rb', line 70 def authenticated_rate_limit @authenticated_rate_limit end |
#authenticated_rate_limit_ttl_seconds ⇒ Object
Authenticated rate limit TTL in seconds
82 83 84 |
# File 'lib/daytona_api_client/models/organization.rb', line 82 def authenticated_rate_limit_ttl_seconds @authenticated_rate_limit_ttl_seconds end |
#created_at ⇒ Object
Creation timestamp
31 32 33 |
# File 'lib/daytona_api_client/models/organization.rb', line 31 def created_at @created_at end |
#created_by ⇒ Object
User ID of the organization creator
25 26 27 |
# File 'lib/daytona_api_client/models/organization.rb', line 25 def created_by @created_by end |
#default_region_id ⇒ Object
Default region ID
67 68 69 |
# File 'lib/daytona_api_client/models/organization.rb', line 67 def default_region_id @default_region_id end |
#experimental_config ⇒ Object
Experimental configuration
79 80 81 |
# File 'lib/daytona_api_client/models/organization.rb', line 79 def experimental_config @experimental_config end |
#id ⇒ Object
Organization ID
19 20 21 |
# File 'lib/daytona_api_client/models/organization.rb', line 19 def id @id end |
#max_cpu_per_sandbox ⇒ Object
Max CPU per sandbox
52 53 54 |
# File 'lib/daytona_api_client/models/organization.rb', line 52 def max_cpu_per_sandbox @max_cpu_per_sandbox end |
#max_disk_per_sandbox ⇒ Object
Max disk per sandbox
58 59 60 |
# File 'lib/daytona_api_client/models/organization.rb', line 58 def max_disk_per_sandbox @max_disk_per_sandbox end |
#max_memory_per_sandbox ⇒ Object
Max memory per sandbox
55 56 57 |
# File 'lib/daytona_api_client/models/organization.rb', line 55 def max_memory_per_sandbox @max_memory_per_sandbox end |
#name ⇒ Object
Organization name
22 23 24 |
# File 'lib/daytona_api_client/models/organization.rb', line 22 def name @name end |
#personal ⇒ Object
Personal organization flag
28 29 30 |
# File 'lib/daytona_api_client/models/organization.rb', line 28 def personal @personal end |
#sandbox_create_rate_limit ⇒ Object
Sandbox create rate limit per minute
73 74 75 |
# File 'lib/daytona_api_client/models/organization.rb', line 73 def sandbox_create_rate_limit @sandbox_create_rate_limit end |
#sandbox_create_rate_limit_ttl_seconds ⇒ Object
Sandbox create rate limit TTL in seconds
85 86 87 |
# File 'lib/daytona_api_client/models/organization.rb', line 85 def sandbox_create_rate_limit_ttl_seconds @sandbox_create_rate_limit_ttl_seconds end |
#sandbox_lifecycle_rate_limit ⇒ Object
Sandbox lifecycle rate limit per minute
76 77 78 |
# File 'lib/daytona_api_client/models/organization.rb', line 76 def sandbox_lifecycle_rate_limit @sandbox_lifecycle_rate_limit end |
#sandbox_lifecycle_rate_limit_ttl_seconds ⇒ Object
Sandbox lifecycle rate limit TTL in seconds
88 89 90 |
# File 'lib/daytona_api_client/models/organization.rb', line 88 def sandbox_lifecycle_rate_limit_ttl_seconds @sandbox_lifecycle_rate_limit_ttl_seconds end |
#sandbox_limited_network_egress ⇒ Object
Sandbox default network block all
64 65 66 |
# File 'lib/daytona_api_client/models/organization.rb', line 64 def sandbox_limited_network_egress @sandbox_limited_network_egress end |
#snapshot_deactivation_timeout_minutes ⇒ Object
Time in minutes before an unused snapshot is deactivated
61 62 63 |
# File 'lib/daytona_api_client/models/organization.rb', line 61 def snapshot_deactivation_timeout_minutes @snapshot_deactivation_timeout_minutes end |
#suspended ⇒ Object
Suspended flag
37 38 39 |
# File 'lib/daytona_api_client/models/organization.rb', line 37 def suspended @suspended end |
#suspended_at ⇒ Object
Suspended at
40 41 42 |
# File 'lib/daytona_api_client/models/organization.rb', line 40 def suspended_at @suspended_at end |
#suspended_until ⇒ Object
Suspended until
46 47 48 |
# File 'lib/daytona_api_client/models/organization.rb', line 46 def suspended_until @suspended_until end |
#suspension_cleanup_grace_period_hours ⇒ Object
Suspension cleanup grace period hours
49 50 51 |
# File 'lib/daytona_api_client/models/organization.rb', line 49 def suspension_cleanup_grace_period_hours @suspension_cleanup_grace_period_hours end |
#suspension_reason ⇒ Object
Suspended reason
43 44 45 |
# File 'lib/daytona_api_client/models/organization.rb', line 43 def suspension_reason @suspension_reason end |
#updated_at ⇒ Object
Last update timestamp
34 35 36 |
# File 'lib/daytona_api_client/models/organization.rb', line 34 def updated_at @updated_at end |
Class Method Details
._deserialize(type, value) ⇒ Object
Deserializes the data based on type
671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 |
# File 'lib/daytona_api_client/models/organization.rb', line 671 def self._deserialize(type, value) case type.to_sym when :Time Time.parse(value) when :Date Date.parse(value) when :String value.to_s when :Integer value.to_i when :Float value.to_f when :Boolean if value.to_s =~ /\A(true|t|yes|y|1)\z/i true else false end when :Object # generic object (usually a Hash), return directly value when /\AArray<(?<inner_type>.+)>\z/ inner_type = Regexp.last_match[:inner_type] value.map { |v| _deserialize(inner_type, v) } when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/ k_type = Regexp.last_match[:k_type] v_type = Regexp.last_match[:v_type] {}.tap do |hash| value.each do |k, v| hash[_deserialize(k_type, k)] = _deserialize(v_type, v) end end else # model # models (e.g. Pet) or oneOf klass = DaytonaApiClient.const_get(type) klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end |
.acceptable_attribute_map ⇒ Object
Returns attribute mapping this model knows about
121 122 123 |
# File 'lib/daytona_api_client/models/organization.rb', line 121 def self.acceptable_attribute_map attribute_map end |
.acceptable_attributes ⇒ Object
Returns all the JSON keys this model knows about
126 127 128 |
# File 'lib/daytona_api_client/models/organization.rb', line 126 def self.acceptable_attributes acceptable_attribute_map.values end |
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
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 |
# File 'lib/daytona_api_client/models/organization.rb', line 91 def self.attribute_map { :'id' => :'id', :'name' => :'name', :'created_by' => :'createdBy', :'personal' => :'personal', :'created_at' => :'createdAt', :'updated_at' => :'updatedAt', :'suspended' => :'suspended', :'suspended_at' => :'suspendedAt', :'suspension_reason' => :'suspensionReason', :'suspended_until' => :'suspendedUntil', :'suspension_cleanup_grace_period_hours' => :'suspensionCleanupGracePeriodHours', :'max_cpu_per_sandbox' => :'maxCpuPerSandbox', :'max_memory_per_sandbox' => :'maxMemoryPerSandbox', :'max_disk_per_sandbox' => :'maxDiskPerSandbox', :'snapshot_deactivation_timeout_minutes' => :'snapshotDeactivationTimeoutMinutes', :'sandbox_limited_network_egress' => :'sandboxLimitedNetworkEgress', :'default_region_id' => :'defaultRegionId', :'authenticated_rate_limit' => :'authenticatedRateLimit', :'sandbox_create_rate_limit' => :'sandboxCreateRateLimit', :'sandbox_lifecycle_rate_limit' => :'sandboxLifecycleRateLimit', :'experimental_config' => :'experimentalConfig', :'authenticated_rate_limit_ttl_seconds' => :'authenticatedRateLimitTtlSeconds', :'sandbox_create_rate_limit_ttl_seconds' => :'sandboxCreateRateLimitTtlSeconds', :'sandbox_lifecycle_rate_limit_ttl_seconds' => :'sandboxLifecycleRateLimitTtlSeconds' } end |
.build_from_hash(attributes) ⇒ Object
Builds the object from hash
647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 |
# File 'lib/daytona_api_client/models/organization.rb', line 647 def self.build_from_hash(attributes) return nil unless attributes.is_a?(Hash) attributes = attributes.transform_keys(&:to_sym) transformed_hash = {} openapi_types.each_pair do |key, type| if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil? transformed_hash["#{key}"] = nil elsif type =~ /\AArray<(.*)>/i # check to ensure the input is an array given that the attribute # is documented as an array but the input is not if attributes[attribute_map[key]].is_a?(Array) transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) } end elsif !attributes[attribute_map[key]].nil? transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]]) end end new(transformed_hash) end |
.openapi_nullable ⇒ Object
List of attributes with nullable: true
161 162 163 164 165 166 167 168 169 170 |
# File 'lib/daytona_api_client/models/organization.rb', line 161 def self.openapi_nullable Set.new([ :'authenticated_rate_limit', :'sandbox_create_rate_limit', :'sandbox_lifecycle_rate_limit', :'authenticated_rate_limit_ttl_seconds', :'sandbox_create_rate_limit_ttl_seconds', :'sandbox_lifecycle_rate_limit_ttl_seconds' ]) end |
.openapi_types ⇒ Object
Attribute type mapping.
131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 |
# File 'lib/daytona_api_client/models/organization.rb', line 131 def self.openapi_types { :'id' => :'String', :'name' => :'String', :'created_by' => :'String', :'personal' => :'Boolean', :'created_at' => :'Time', :'updated_at' => :'Time', :'suspended' => :'Boolean', :'suspended_at' => :'Time', :'suspension_reason' => :'String', :'suspended_until' => :'Time', :'suspension_cleanup_grace_period_hours' => :'Float', :'max_cpu_per_sandbox' => :'Float', :'max_memory_per_sandbox' => :'Float', :'max_disk_per_sandbox' => :'Float', :'snapshot_deactivation_timeout_minutes' => :'Float', :'sandbox_limited_network_egress' => :'Boolean', :'default_region_id' => :'String', :'authenticated_rate_limit' => :'Float', :'sandbox_create_rate_limit' => :'Float', :'sandbox_lifecycle_rate_limit' => :'Float', :'experimental_config' => :'Object', :'authenticated_rate_limit_ttl_seconds' => :'Float', :'sandbox_create_rate_limit_ttl_seconds' => :'Float', :'sandbox_lifecycle_rate_limit_ttl_seconds' => :'Float' } end |
Instance Method Details
#==(o) ⇒ Object
Checks equality by comparing each attribute.
603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 |
# File 'lib/daytona_api_client/models/organization.rb', line 603 def ==(o) return true if self.equal?(o) self.class == o.class && id == o.id && name == o.name && created_by == o.created_by && personal == o.personal && created_at == o.created_at && updated_at == o.updated_at && suspended == o.suspended && suspended_at == o.suspended_at && suspension_reason == o.suspension_reason && suspended_until == o.suspended_until && suspension_cleanup_grace_period_hours == o.suspension_cleanup_grace_period_hours && max_cpu_per_sandbox == o.max_cpu_per_sandbox && max_memory_per_sandbox == o.max_memory_per_sandbox && max_disk_per_sandbox == o.max_disk_per_sandbox && snapshot_deactivation_timeout_minutes == o.snapshot_deactivation_timeout_minutes && sandbox_limited_network_egress == o.sandbox_limited_network_egress && default_region_id == o.default_region_id && authenticated_rate_limit == o.authenticated_rate_limit && sandbox_create_rate_limit == o.sandbox_create_rate_limit && sandbox_lifecycle_rate_limit == o.sandbox_lifecycle_rate_limit && experimental_config == o.experimental_config && authenticated_rate_limit_ttl_seconds == o.authenticated_rate_limit_ttl_seconds && sandbox_create_rate_limit_ttl_seconds == o.sandbox_create_rate_limit_ttl_seconds && sandbox_lifecycle_rate_limit_ttl_seconds == o.sandbox_lifecycle_rate_limit_ttl_seconds end |
#_to_hash(value) ⇒ Hash
Outputs non-array value in the form of hash For object, use to_hash. Otherwise, just return the value
742 743 744 745 746 747 748 749 750 751 752 753 754 |
# File 'lib/daytona_api_client/models/organization.rb', line 742 def _to_hash(value) if value.is_a?(Array) value.compact.map { |v| _to_hash(v) } elsif value.is_a?(Hash) {}.tap do |hash| value.each { |k, v| hash[k] = _to_hash(v) } end elsif value.respond_to? :to_hash value.to_hash else value end end |
#eql?(o) ⇒ Boolean
634 635 636 |
# File 'lib/daytona_api_client/models/organization.rb', line 634 def eql?(o) self == o end |
#hash ⇒ Integer
Calculates hash code according to all attributes.
640 641 642 |
# File 'lib/daytona_api_client/models/organization.rb', line 640 def hash [id, name, created_by, personal, created_at, updated_at, suspended, suspended_at, suspension_reason, suspended_until, suspension_cleanup_grace_period_hours, max_cpu_per_sandbox, max_memory_per_sandbox, max_disk_per_sandbox, snapshot_deactivation_timeout_minutes, sandbox_limited_network_egress, default_region_id, authenticated_rate_limit, sandbox_create_rate_limit, sandbox_lifecycle_rate_limit, experimental_config, authenticated_rate_limit_ttl_seconds, sandbox_create_rate_limit_ttl_seconds, sandbox_lifecycle_rate_limit_ttl_seconds].hash end |
#list_invalid_properties ⇒ Object
Show invalid properties with the reasons. Usually used together with valid?
333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 |
# File 'lib/daytona_api_client/models/organization.rb', line 333 def list_invalid_properties warn '[DEPRECATED] the `list_invalid_properties` method is obsolete' invalid_properties = Array.new if @id.nil? invalid_properties.push('invalid value for "id", id cannot be nil.') end if @name.nil? invalid_properties.push('invalid value for "name", name cannot be nil.') end if @created_by.nil? invalid_properties.push('invalid value for "created_by", created_by cannot be nil.') end if @personal.nil? invalid_properties.push('invalid value for "personal", personal cannot be nil.') end if @created_at.nil? invalid_properties.push('invalid value for "created_at", created_at cannot be nil.') end if @updated_at.nil? invalid_properties.push('invalid value for "updated_at", updated_at cannot be nil.') end if @suspended.nil? invalid_properties.push('invalid value for "suspended", suspended cannot be nil.') end if @suspended_at.nil? invalid_properties.push('invalid value for "suspended_at", suspended_at cannot be nil.') end if @suspension_reason.nil? invalid_properties.push('invalid value for "suspension_reason", suspension_reason cannot be nil.') end if @suspended_until.nil? invalid_properties.push('invalid value for "suspended_until", suspended_until cannot be nil.') end if @suspension_cleanup_grace_period_hours.nil? invalid_properties.push('invalid value for "suspension_cleanup_grace_period_hours", suspension_cleanup_grace_period_hours cannot be nil.') end if @max_cpu_per_sandbox.nil? invalid_properties.push('invalid value for "max_cpu_per_sandbox", max_cpu_per_sandbox cannot be nil.') end if @max_memory_per_sandbox.nil? invalid_properties.push('invalid value for "max_memory_per_sandbox", max_memory_per_sandbox cannot be nil.') end if @max_disk_per_sandbox.nil? invalid_properties.push('invalid value for "max_disk_per_sandbox", max_disk_per_sandbox cannot be nil.') end if @snapshot_deactivation_timeout_minutes.nil? invalid_properties.push('invalid value for "snapshot_deactivation_timeout_minutes", snapshot_deactivation_timeout_minutes cannot be nil.') end if @sandbox_limited_network_egress.nil? invalid_properties.push('invalid value for "sandbox_limited_network_egress", sandbox_limited_network_egress cannot be nil.') end if @experimental_config.nil? invalid_properties.push('invalid value for "experimental_config", experimental_config cannot be nil.') end invalid_properties end |
#to_body ⇒ Hash
to_body is an alias to to_hash (backward compatibility)
718 719 720 |
# File 'lib/daytona_api_client/models/organization.rb', line 718 def to_body to_hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
724 725 726 727 728 729 730 731 732 733 734 735 736 |
# File 'lib/daytona_api_client/models/organization.rb', line 724 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = self.send(attr) if value.nil? is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
712 713 714 |
# File 'lib/daytona_api_client/models/organization.rb', line 712 def to_s to_hash.to_s end |
#valid? ⇒ Boolean
Check to see if the all the properties in the model are valid
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 |
# File 'lib/daytona_api_client/models/organization.rb', line 409 def valid? warn '[DEPRECATED] the `valid?` method is obsolete' return false if @id.nil? return false if @name.nil? return false if @created_by.nil? return false if @personal.nil? return false if @created_at.nil? return false if @updated_at.nil? return false if @suspended.nil? return false if @suspended_at.nil? return false if @suspension_reason.nil? return false if @suspended_until.nil? return false if @suspension_cleanup_grace_period_hours.nil? return false if @max_cpu_per_sandbox.nil? return false if @max_memory_per_sandbox.nil? return false if @max_disk_per_sandbox.nil? return false if @snapshot_deactivation_timeout_minutes.nil? return false if @sandbox_limited_network_egress.nil? return false if @experimental_config.nil? true end |