Method: Harbor2Client::RegistryProviderInfo#initialize

Defined in:
lib/harbor2_client/models/registry_provider_info.rb

#initialize(attributes = {}) ⇒ RegistryProviderInfo

Initializes the object

Parameters:

  • attributes (Hash) (defaults to: {})

    Model attributes in the form of hash



42
43
44
45
46
47
48
49
50
51
52
53
54
55
# File 'lib/harbor2_client/models/registry_provider_info.rb', line 42

def initialize(attributes = {})
  return unless attributes.is_a?(Hash)

  # convert string to symbol for hash key
  attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }

  if attributes.has_key?(:'endpoint_pattern')
    self.endpoint_pattern = attributes[:'endpoint_pattern']
  end

  if attributes.has_key?(:'credential_pattern')
    self.credential_pattern = attributes[:'credential_pattern']
  end
end