Class: OCI::DatabaseMigration::Models::ADBDedicatedAutoCreateTablespaceDetails
- Inherits:
-
TargetTypeTablespaceDetails
- Object
- TargetTypeTablespaceDetails
- OCI::DatabaseMigration::Models::ADBDedicatedAutoCreateTablespaceDetails
- Defined in:
- lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb
Overview
Auto create tablespace settings that are valid for Dedicated Autonomous Databases.
Constant Summary collapse
- BLOCK_SIZE_IN_KBS_ENUM =
[ BLOCK_SIZE_IN_KBS_SIZE_2_K = 'SIZE_2K'.freeze, BLOCK_SIZE_IN_KBS_SIZE_8_K = 'SIZE_8K'.freeze, BLOCK_SIZE_IN_KBS_SIZE_16_K = 'SIZE_16K'.freeze, BLOCK_SIZE_IN_KBS_SIZE_32_K = 'SIZE_32K'.freeze, BLOCK_SIZE_IN_KBS_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Constants inherited from TargetTypeTablespaceDetails
TargetTypeTablespaceDetails::TARGET_TYPE_ENUM
Instance Attribute Summary collapse
-
#block_size_in_kbs ⇒ String
Size of Oracle database blocks in KB.
-
#extend_size_in_mbs ⇒ Integer
Size to extend the tablespace in MB.
-
#is_auto_create ⇒ BOOLEAN
Set this property to true to auto-create tablespaces in the target Database.
-
#is_big_file ⇒ BOOLEAN
Set this property to true to enable tablespace of the type big file.
Attributes inherited from TargetTypeTablespaceDetails
Class Method Summary collapse
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.swagger_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(other) ⇒ Object
Checks equality by comparing each attribute.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(other) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ ADBDedicatedAutoCreateTablespaceDetails
constructor
Initializes the object.
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
Methods inherited from TargetTypeTablespaceDetails
Constructor Details
#initialize(attributes = {}) ⇒ ADBDedicatedAutoCreateTablespaceDetails
Initializes the object
80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 80 def initialize(attributes = {}) return unless attributes.is_a?(Hash) attributes['targetType'] = 'ADB_D_AUTOCREATE' super(attributes) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } self.is_auto_create = attributes[:'isAutoCreate'] unless attributes[:'isAutoCreate'].nil? self.is_auto_create = true if is_auto_create.nil? && !attributes.key?(:'isAutoCreate') # rubocop:disable Style/StringLiterals raise 'You cannot provide both :isAutoCreate and :is_auto_create' if attributes.key?(:'isAutoCreate') && attributes.key?(:'is_auto_create') self.is_auto_create = attributes[:'is_auto_create'] unless attributes[:'is_auto_create'].nil? self.is_auto_create = true if is_auto_create.nil? && !attributes.key?(:'isAutoCreate') && !attributes.key?(:'is_auto_create') # rubocop:disable Style/StringLiterals self.is_big_file = attributes[:'isBigFile'] unless attributes[:'isBigFile'].nil? self.is_big_file = true if is_big_file.nil? && !attributes.key?(:'isBigFile') # rubocop:disable Style/StringLiterals raise 'You cannot provide both :isBigFile and :is_big_file' if attributes.key?(:'isBigFile') && attributes.key?(:'is_big_file') self.is_big_file = attributes[:'is_big_file'] unless attributes[:'is_big_file'].nil? self.is_big_file = true if is_big_file.nil? && !attributes.key?(:'isBigFile') && !attributes.key?(:'is_big_file') # rubocop:disable Style/StringLiterals self.extend_size_in_mbs = attributes[:'extendSizeInMBs'] if attributes[:'extendSizeInMBs'] raise 'You cannot provide both :extendSizeInMBs and :extend_size_in_mbs' if attributes.key?(:'extendSizeInMBs') && attributes.key?(:'extend_size_in_mbs') self.extend_size_in_mbs = attributes[:'extend_size_in_mbs'] if attributes[:'extend_size_in_mbs'] self.block_size_in_kbs = attributes[:'blockSizeInKBs'] if attributes[:'blockSizeInKBs'] self.block_size_in_kbs = "SIZE_8K" if block_size_in_kbs.nil? && !attributes.key?(:'blockSizeInKBs') # rubocop:disable Style/StringLiterals raise 'You cannot provide both :blockSizeInKBs and :block_size_in_kbs' if attributes.key?(:'blockSizeInKBs') && attributes.key?(:'block_size_in_kbs') self.block_size_in_kbs = attributes[:'block_size_in_kbs'] if attributes[:'block_size_in_kbs'] self.block_size_in_kbs = "SIZE_8K" if block_size_in_kbs.nil? && !attributes.key?(:'blockSizeInKBs') && !attributes.key?(:'block_size_in_kbs') # rubocop:disable Style/StringLiterals end |
Instance Attribute Details
#block_size_in_kbs ⇒ String
Size of Oracle database blocks in KB.
42 43 44 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 42 def block_size_in_kbs @block_size_in_kbs end |
#extend_size_in_mbs ⇒ Integer
Size to extend the tablespace in MB. Note: Only applicable if 'isBigFile' property is set to true.
37 38 39 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 37 def extend_size_in_mbs @extend_size_in_mbs end |
#is_auto_create ⇒ BOOLEAN
Set this property to true to auto-create tablespaces in the target Database. Note: This is not applicable for Autonomous Database Serverless databases.
26 27 28 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 26 def is_auto_create @is_auto_create end |
#is_big_file ⇒ BOOLEAN
Set this property to true to enable tablespace of the type big file.
31 32 33 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 31 def is_big_file @is_big_file end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 45 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'target_type': :'targetType', 'is_auto_create': :'isAutoCreate', 'is_big_file': :'isBigFile', 'extend_size_in_mbs': :'extendSizeInMBs', 'block_size_in_kbs': :'blockSizeInKBs' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
58 59 60 61 62 63 64 65 66 67 68 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 58 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'target_type': :'String', 'is_auto_create': :'BOOLEAN', 'is_big_file': :'BOOLEAN', 'extend_size_in_mbs': :'Integer', 'block_size_in_kbs': :'String' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
141 142 143 144 145 146 147 148 149 150 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 141 def ==(other) return true if equal?(other) self.class == other.class && target_type == other.target_type && is_auto_create == other.is_auto_create && is_big_file == other.is_big_file && extend_size_in_mbs == other.extend_size_in_mbs && block_size_in_kbs == other.block_size_in_kbs end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 175 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) self.class.swagger_types.each_pair do |key, type| if type =~ /^Array<(.*)>/i # check to ensure the input is an array given that the the attribute # is documented as an array but the input is not if attributes[self.class.attribute_map[key]].is_a?(Array) public_method("#{key}=").call( attributes[self.class.attribute_map[key]] .map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) } ) end elsif !attributes[self.class.attribute_map[key]].nil? public_method("#{key}=").call( OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]]) ) end # or else data not found in attributes(hash), not an issue as the data can be optional end self end |
#eql?(other) ⇒ Boolean
155 156 157 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 155 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
164 165 166 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 164 def hash [target_type, is_auto_create, is_big_file, extend_size_in_mbs, block_size_in_kbs].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
208 209 210 211 212 213 214 215 216 217 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 208 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = public_method(attr).call next if value.nil? && !instance_variable_defined?("@#{attr}") hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
202 203 204 |
# File 'lib/oci/database_migration/models/adb_dedicated_auto_create_tablespace_details.rb', line 202 def to_s to_hash.to_s end |