Class: GandiV5::Domain::Contact

Inherits:
Object
  • Object
show all
Includes:
GandiV5::Data
Defined in:
lib/gandi_v5/domain/contact.rb

Overview

Information for a single contact for a domain.

Constant Summary collapse

TYPES =
{
  person: 'Person',
  company: 'Company',
  association: 'Association',
  'public body': 'Public Body',
  reseller: 'Reseller'
}.freeze
REACHABILITIES =
%i[pending done failed deleted none].freeze
VALIDATIONS =
%i[pending done failed deleted none].freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from GandiV5::Data

#from_gandi, included, #initialize, #to_gandi, #to_h, #values_at

Instance Attribute Details

#addressString (readonly)

Returns .

Returns:

  • (String)

    .



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#brand_numbernil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#citynil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#countryString (readonly)

Returns .

Returns:

  • (String)

    .



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#data_obfuscatednil, Boolean (readonly)

Returns:

  • (nil, Boolean)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#emailString (readonly)

Returns .

Returns:

  • (String)

    .



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#extra_parametersnil, Hash (readonly)

Returns:

  • (nil, Hash)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#familyString (readonly)

Returns .

Returns:

  • (String)

    .



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#faxnil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#givenString (readonly)

Returns .

Returns:

  • (String)

    .



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#jo_announce_numbernil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#jo_announce_pagenil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#jo_declaration_pagenil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#jo_publication_datenil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#mail_obfuscatednil, Boolean (readonly)

Returns:

  • (nil, Boolean)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#mobilenil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#organisation_namenil, String (readonly)

Returns the legal name of the company, association, or public body if the contact type is not :person.

Returns:

  • (nil, String)

    the legal name of the company, association, or public body if the contact type is not :person.



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#phonenil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#reachabilitynil, ... (readonly)

Returns:

  • (nil, :pending, :done, :failed, :deleted, :none)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#sharing_uuidnil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#sirennil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#statenil, String (readonly)



58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#type:person, ... (readonly)

Returns:

  • (:person, :company, :association, :'public body', :reseller)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#validationnil, ... (readonly)

Returns:

  • (nil, :pending, :done, :failed, :deleted, :none)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

#zipnil, String (readonly)

Returns:

  • (nil, String)


58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/gandi_v5/domain/contact.rb', line 58

class Contact
  include GandiV5::Data

  TYPES = {
    person: 'Person',
    company: 'Company',
    association: 'Association',
    'public body': 'Public Body',
    reseller: 'Reseller'
  }.freeze
  REACHABILITIES = %i[pending done failed deleted none].freeze
  VALIDATIONS = %i[pending done failed deleted none].freeze

  members :country, :email, :family, :given, :brand_number, :city, :data_obfuscated,
          :extra_parameters, :fax, :jo_announce_number, :jo_announce_page,
          :jo_declaration_page, :jo_publication_date, :mail_obfuscated,
          :mobile, :phone, :siren, :state, :zip

  member :organisation_name, gandi_key: 'orgname'
  member :address, gandi_key: 'streetaddr'
  member :sharing_uuid, gandi_key: 'sharing_id'

  member(
    :type,
    converter: GandiV5::Data::Converter.new(
      from_gandi: ->(type) { TYPES.keys[type] },
      to_gandi: ->(type) { TYPES.keys.index(type) }
    )
  )
  member :reachability, converter: GandiV5::Data::Converter::Symbol
  member :validation, converter: GandiV5::Data::Converter::Symbol

  # Get the name for this contact.
  # @return [String] e.g. "John Smith" or "Some Company LTD."
  def name
    type.eql?(:person) ? "#{given} #{family}" : organisation_name
  end

  # @return [String] Containing type and name.
  def to_s
    "#{TYPES[type]}\t#{name}"
  end
end

Instance Method Details

#nameString

Get the name for this contact.

Returns:

  • (String)

    e.g. “John Smith” or “Some Company LTD.”



92
93
94
# File 'lib/gandi_v5/domain/contact.rb', line 92

def name
  type.eql?(:person) ? "#{given} #{family}" : organisation_name
end

#to_sString

Returns Containing type and name.

Returns:

  • (String)

    Containing type and name.



97
98
99
# File 'lib/gandi_v5/domain/contact.rb', line 97

def to_s
  "#{TYPES[type]}\t#{name}"
end