Method: IntersightClient::StorageVirtualDriveConfiguration#list_invalid_properties

Defined in:
lib/intersight_client/models/storage_virtual_drive_configuration.rb

#list_invalid_propertiesObject

Show invalid properties with the reasons. Usually used together with valid?

Returns:

  • Array for valid properties with the reasons



170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
# File 'lib/intersight_client/models/storage_virtual_drive_configuration.rb', line 170

def list_invalid_properties
  invalid_properties = super
  if @class_id.nil?
    invalid_properties.push('invalid value for "class_id", class_id cannot be nil.')
  end

  if @object_type.nil?
    invalid_properties.push('invalid value for "object_type", object_type cannot be nil.')
  end

  if !@name.nil? && @name.to_s.length > 15
    invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 15.')
  end

  pattern = Regexp.new(/^[a-zA-Z0-9\-\._:]*$/)
  if !@name.nil? && @name !~ pattern
    invalid_properties.push("invalid value for \"name\", must conform to the pattern #{pattern}.")
  end

  if !@size.nil? && @size < 0
    invalid_properties.push('invalid value for "size", must be greater than or equal to 0.')
  end

  invalid_properties
end