Class: Zonesync::Zonefile::CAA

Inherits:
Record
  • Object
show all
Defined in:
lib/zonesync/zonefile.rb

Instance Attribute Summary collapse

Attributes inherited from Record

#comment, #klass, #ttl

Instance Method Summary collapse

Methods inherited from Record

writer_for_ttl

Constructor Details

#initialize(vars, zonefile_record) ⇒ CAA

Returns a new instance of CAA.



154
155
156
157
158
159
160
161
162
163
164
165
166
# File 'lib/zonesync/zonefile.rb', line 154

def initialize(vars, zonefile_record)
  @vars = vars
  if zonefile_record
    self.host = qualify_host(zonefile_record.host.to_s)
    @vars[:last_host] = host
    self.ttl = zonefile_record.ttl.to_i
    self.klass = zonefile_record.klass.to_s
    self.flags = zonefile_record.flags.to_i
    self.tag = zonefile_record.tag.to_s
    self.value = zonefile_record.value.to_s
    self.comment = zonefile_record.comment&.to_s
  end
end

Instance Attribute Details

#flagsObject

Returns the value of attribute flags.



152
153
154
# File 'lib/zonesync/zonefile.rb', line 152

def flags
  @flags
end

#hostObject

Returns the value of attribute host.



152
153
154
# File 'lib/zonesync/zonefile.rb', line 152

def host
  @host
end

#tagObject

Returns the value of attribute tag.



152
153
154
# File 'lib/zonesync/zonefile.rb', line 152

def tag
  @tag
end

#valueObject

Returns the value of attribute value.



152
153
154
# File 'lib/zonesync/zonefile.rb', line 152

def value
  @value
end