Class: GandiV5::Domain::LiveDNS

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

Overview

LiveDNS information for a domain.

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

#current:classic, ... (readonly)

Returns type of nameservers currently set. classic corresponds to Gandi’s classic nameservers, livedns is for the new, default, Gandi nameservers and other is for custom nameservers.

Returns:

  • (:classic, :livedns, :other)

    type of nameservers currently set. classic corresponds to Gandi’s classic nameservers, livedns is for the new, default, Gandi nameservers and other is for custom nameservers.



16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# File 'lib/gandi_v5/domain/live_dns.rb', line 16

class LiveDNS
  include GandiV5::Data

  members :dnssec_available, :livednssec_available
  member :name_servers, gandi_key: 'nameservers'
  member :current, converter: GandiV5::Data::Converter::Symbol

  # Check if classic DNS is being used.
  # @return [Boolean]
  def classic?
    current == :classic
  end

  # Check if custom DNS is being used.
  # @return [Boolean]
  def custom?
    current == :custom
  end

  # Check if LiveDNS is being used.
  # @return [Boolean]
  def livedns?
    current == :livedns
  end
end

#dnssec_availablenil, Boolean (readonly)

Returns whether DNSSEC may be applied to the domain.

Returns:

  • (nil, Boolean)

    whether DNSSEC may be applied to the domain.



16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# File 'lib/gandi_v5/domain/live_dns.rb', line 16

class LiveDNS
  include GandiV5::Data

  members :dnssec_available, :livednssec_available
  member :name_servers, gandi_key: 'nameservers'
  member :current, converter: GandiV5::Data::Converter::Symbol

  # Check if classic DNS is being used.
  # @return [Boolean]
  def classic?
    current == :classic
  end

  # Check if custom DNS is being used.
  # @return [Boolean]
  def custom?
    current == :custom
  end

  # Check if LiveDNS is being used.
  # @return [Boolean]
  def livedns?
    current == :livedns
  end
end

#livednssec_availablenil, Boolean (readonly)

Returns whether DNSSEC with liveDNS may be applied to this domain.

Returns:

  • (nil, Boolean)

    whether DNSSEC with liveDNS may be applied to this domain.



16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# File 'lib/gandi_v5/domain/live_dns.rb', line 16

class LiveDNS
  include GandiV5::Data

  members :dnssec_available, :livednssec_available
  member :name_servers, gandi_key: 'nameservers'
  member :current, converter: GandiV5::Data::Converter::Symbol

  # Check if classic DNS is being used.
  # @return [Boolean]
  def classic?
    current == :classic
  end

  # Check if custom DNS is being used.
  # @return [Boolean]
  def custom?
    current == :custom
  end

  # Check if LiveDNS is being used.
  # @return [Boolean]
  def livedns?
    current == :livedns
  end
end

#name_serversArray<String> (readonly)

Returns list of current nameservers.

Returns:

  • (Array<String>)

    list of current nameservers.



16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# File 'lib/gandi_v5/domain/live_dns.rb', line 16

class LiveDNS
  include GandiV5::Data

  members :dnssec_available, :livednssec_available
  member :name_servers, gandi_key: 'nameservers'
  member :current, converter: GandiV5::Data::Converter::Symbol

  # Check if classic DNS is being used.
  # @return [Boolean]
  def classic?
    current == :classic
  end

  # Check if custom DNS is being used.
  # @return [Boolean]
  def custom?
    current == :custom
  end

  # Check if LiveDNS is being used.
  # @return [Boolean]
  def livedns?
    current == :livedns
  end
end

Instance Method Details

#classic?Boolean

Check if classic DNS is being used.

Returns:

  • (Boolean)


25
26
27
# File 'lib/gandi_v5/domain/live_dns.rb', line 25

def classic?
  current == :classic
end

#custom?Boolean

Check if custom DNS is being used.

Returns:

  • (Boolean)


31
32
33
# File 'lib/gandi_v5/domain/live_dns.rb', line 31

def custom?
  current == :custom
end

#livedns?Boolean

Check if LiveDNS is being used.

Returns:

  • (Boolean)


37
38
39
# File 'lib/gandi_v5/domain/live_dns.rb', line 37

def livedns?
  current == :livedns
end